Language:
switch to room list switch to menu My folders
Go to page: 1 2 3 4 5 [6] 7 8 9 10 ... Last
[#] Mon Sep 01 2014 23:43:35 EDT from ax25 @ Uncensored

[Reply] [ReplyQuoted] [Headers] [Print]

What I find fun is poking around with C libraries with Python and not have to write much code to use a library in C:

https://docs.python.org/2/library/ctypes.html

If you use Windows, Pywin32 is handy:

http://sourceforge.net/projects/pywin32/

You can do quite a bit on Windows with that.  If you need some quick starter examples (or better wrapper code), give Tim Goldens site a look:

http://timgolden.me.uk/python/

Especially this bit:

http://timgolden.me.uk/python/win32_how_do_i.html

If you work in Linux / OSX or Android, things don't need as much explanation :-)

Have fun with it.  Post what you find that is fun.  I have not tried the notebook stuff, but I guess I should.



[#] Tue Sep 09 2014 11:21:54 EDT from fleeb @ Uncensored

[Reply] [ReplyQuoted] [Headers] [Print]


Milestone... first time I ever ready anything helpful on Expert Sexchange.

[#] Tue Sep 09 2014 11:40:15 EDT from fleeb @ Uncensored

[Reply] [ReplyQuoted] [Headers] [Print]


Oh, yeah, for something useful if you're just getting into network programming, and you're wondering why you're getting such peculiar results:

http://blog.netherlabs.nl/articles/2009/01/18/the-ultimate-so_linger-page-or-w hy-is-my-tcp-not-reliable

[#] Tue Sep 09 2014 14:32:50 EDT from IGnatius T Foobar @ Uncensored

[Reply] [ReplyQuoted] [Headers] [Print]

Python definitely pulled way ahead of Perl in the space of scripting languages, at least in terms of those used on open systems.

A number of years ago, there was a community-wide debate about what language should be the preferred "managed code" environment for Linux.  Java was king at the time (and in most of the places where it matters, still is), but a group led by a Microsoft employee named Miguel de Icaza kept clamoring about how Java was "too proprietary" (even though it's GPL) and said that .NET should be used instead.  Meanwhile, there were people in the background pointing out that Python is already there and is already doing the job.  These people quietly won the debate.

 



[#] Tue Sep 09 2014 14:57:04 EDT from fleeb @ Uncensored

[Reply] [ReplyQuoted] [Headers] [Print]


I find Python in use within Windows quite heavily as well.

[#] Wed Sep 10 2014 01:20:49 EDT from ax25 @ Uncensored

[Reply] [ReplyQuoted] [Headers] [Print]

Python is making in-roads in to automation / deployment of Windows VM's or configs as well these days:

http://docs.ansible.com/intro_windows.html

Although, they still have some evil Powershell bits to deal with, I would guess they could replace them if needed with some wrapper code in Python.



[#] Wed Sep 10 2014 01:36:27 EDT from ax25 @ Uncensored

[Reply] [ReplyQuoted] [Headers] [Print]

 

Tue Sep 09 2014 11:40:15 AM EDT from fleeb @ Uncensored

Oh, yeah, for something useful if you're just getting into network programming, and you're wondering why you're getting such peculiar results:

http://blog.netherlabs.nl/articles/2009/01/18/the-ultimate-so_linger-page-or-w hy-is-my-tcp-not-reliable

Heh, loved the reply:

"wow, you just discovered why TCP is not on top of the IP network stack... gratz! :)"

Hope that does not deter that dude and his blog as it is the way we learn (by failure and not understanding everything in one quick glance).  Failing and keeping track of failures is science.  Keeping track of failures that lead us to an alternative discovery is the needle in the hey stack that we hope for.



[#] Wed Sep 10 2014 07:32:45 EDT from dothebart @ Uncensored

[Reply] [ReplyQuoted] [Headers] [Print]

 

Wed Sep 10 2014 01:20:49 EDT from ax25 @ Uncensored

Python is making in-roads in to automation / deployment of Windows VM's or configs as well these days:

http://docs.ansible.com/intro_windows.html

Although, they still have some evil Powershell bits to deal with, I would guess they could replace them if needed with some wrapper code in Python.



I guess if you run the python in the see-carpet interpreter, you can simply call that stuff; its called ironpython, right?



[#] Wed Sep 10 2014 08:22:36 EDT from fleeb @ Uncensored

[Reply] [ReplyQuoted] [Headers] [Print]


ax25:

Well, honestly, that's kind of a dick-ish comment that fellow made.

Esp. in posix oses, one would approach working with a network socket like one would approach working with a file handle. And operations that flush output to a file handle would naturally be expected to flush output out a network socket.

But, it doesn't work like that, because of that one little detail, heh.

Still, I saw that same mistake several times in the last couple of weeks, not only from students learning how to program with sockets, but with employees we have that ought to know better.

[#] Wed Sep 10 2014 22:24:14 EDT from ax25 @ Uncensored

[Reply] [ReplyQuoted] [Headers] [Print]

Wed Sep 10 2014 07:32:45 AM EDT from dothebart @ Uncensored
I guess if you run the python in the see-carpet interpreter, you can simply call that stuff; its called ironpython, right?

I should give ironpython a shot.  Never did delve in to it.  I mostly stuck to making one off .exe's with bundled interpreter using the pywin32 libraries to do the heavy lifting for me.



[#] Wed Sep 10 2014 22:37:31 EDT from ax25 @ Uncensored

[Reply] [ReplyQuoted] [Headers] [Print]

Fleeb, I hit that same issue on my first outing as well.  It was also complicated by being AX.25 socket programming with its need to have CR / CRLF confusion and baggage.



[#] Thu Sep 11 2014 08:20:45 EDT from fleeb @ Uncensored

[Reply] [ReplyQuoted] [Headers] [Print]


I think it's a rite of passage. I ran into it when I first got into socket programming, too.

People learn through failure. This is one of those examples of failure where you learn, heh.

[#] Fri Sep 12 2014 09:17:16 EDT from Sig @ Uncensored

[Reply] [ReplyQuoted] [Headers] [Print]

There's a vague work-related connection for Python; it turns out that some of our newer tools (which most of us don't have and haven't used yet) are using Python for the queries, so at least a base level of understanding is pretty helpful. We don't have any programmers; sadly, I think my almost-done-with-codecademy-stream is the closest qualification.

[#] Mon Sep 15 2014 00:41:17 EDT from ax25 @ Uncensored

[Reply] [ReplyQuoted] [Headers] [Print]

Sig, if you have programmed in most any other language before, Python should be a breeze.  Much of what you learned should carry over.



[#] Mon Sep 15 2014 09:54:51 EDT from fleeb @ Uncensored

[Reply] [ReplyQuoted] [Headers] [Print]


Yeah, that ease-of-learning makes Python a strong language. I think other scripting languages fail compared to Python, feature-for-feature, although some folks feel its whitespace requirements add pedantry to the language.

[#] Mon Sep 15 2014 12:30:05 EDT from LoanShark @ Uncensored

[Reply] [ReplyQuoted] [Headers] [Print]


The whitespace thing makes Python a little less maintainable, a little harder to refactor and move code around.


That code block was probably properly indented when it was first written, but after your move, with no other syntactic cues to catch that you didn't format it properly... meh.

[#] Mon Sep 15 2014 12:32:14 EDT from fleeb @ Uncensored

[Reply] [ReplyQuoted] [Headers] [Print]


Braces and parenthesis FTW!

[#] Mon Sep 15 2014 12:34:26 EDT from LoanShark @ Uncensored

[Reply] [ReplyQuoted] [Headers] [Print]


(especially(parenthesis))

[#] Tue Sep 16 2014 19:38:44 EDT from LoanShark @ Uncensored

[Reply] [ReplyQuoted] [Headers] [Print]


Why, oh why must IntelliJ's rebase/merge window be MODAL?!?

Batshit insane.

Go to page: 1 2 3 4 5 [6] 7 8 9 10 ... Last