Re: Pyarmor, guard your python scripts

2015-10-05 Thread Ian Kelly
On Oct 5, 2015 4:27 PM, "Ben Finney" wrote: > > Josef Pktd writes: > > > related > > Care to give us a summary of what that is, and describe what you think > is the relevant point? Following the link reveals it to be the video of a talk on Python exe compilation from PyCon 2014. If you're worri

Re: reg multiple login python

2015-10-05 Thread harirammanohar159
On Thursday, 1 October 2015 12:35:01 UTC+5:30, hariramm...@gmail.com wrote: > Hi All, > > Is there anyway i can login to remote servers at once and do the activity, i > can do one by one using for loop.. > > Thanks in advance. Hi, issue in implementing multiprocessing with pxssh, its working

Re: packaging code with compiled libraries

2015-10-05 Thread Rustom Mody
On Tuesday, October 6, 2015 at 1:14:05 AM UTC+5:30, Tim wrote: > And that seems to work, but after reading more from the Python Packaging > Authority, I wonder if that is the right way. Should I be using wheels > instead? > I think my brain fried a little bit while going through the doc. You

Re: Pyarmor, guard your python scripts

2015-10-05 Thread Ben Finney
Josef Pktd writes: > related Care to give us a summary of what that is, and describe what you think is the relevant point? -- \ “The best way to get information on Usenet is not to ask a | `\ question, but to post the wrong information.” —Aahz | _o__)

threading bug in strptime

2015-10-05 Thread Larry Martell
We have been trying to figure out an intermittent problem where a thread would fail with this: AttributeError: 'module' object has no attribute '_strptime' Even though we were importing datetime. After much banging our heads against the wall, we found this: http://code-trick.com/python-bug-attri

Re: Finding Blank Columns in CSV

2015-10-05 Thread Denis McMahon
On Mon, 05 Oct 2015 13:29:03 +, Jaydip Chakrabarty wrote: > Hello, > > I have a csv file like this. > > Name,Surname,Age,Sex abc,def,,M ,ghi,,F jkl,mno,, > pqr,,,F > > I want to find out the blank columns, that is, fields where all the > values are blank. Here is my python code. > > fn = "

Re: Finding Blank Columns in CSV

2015-10-05 Thread Friedrich Rentsch
On 10/05/2015 03:29 PM, Jaydip Chakrabarty wrote: Hello, I have a csv file like this. Name,Surname,Age,Sex abc,def,,M ,ghi,,F jkl,mno,, pqr,,,F I want to find out the blank columns, that is, fields where all the values are blank. Here is my python code. fn = "tmp1.csv" fin = open(fn, 'rb')

Re: Pyarmor, guard your python scripts

2015-10-05 Thread sohcahtoa82
On Thursday, September 17, 2015 at 10:55:19 PM UTC-7, Jondy Zhao wrote: > On Friday, September 18, 2015 at 11:06:25 AM UTC+8, Ben Finney wrote: > > Jondy Zhao writes: > > > > > For example, I develop a game by python. What I want to do is that the > > > player or the agent could not simply copy t

packaging code with compiled libraries

2015-10-05 Thread Tim
I have a package I want to share but have a question about packaging. Mostly the package is pure python code, but it also requires some binary libraries (*.so, *.dll, *.dylib). I want to bundle these libs so users don't have to compile. The package will run on *nix/windows/mac platforms. Curre

Re: Pyserial and Ubuntu Linux kernel 3.13.0-65-generic

2015-10-05 Thread Rob Gaddi
On Sat, 03 Oct 2015 11:12:28 +0200, Laura Creighton wrote: > In a message of Sat, 03 Oct 2015 11:07:04 +0200, Laura Creighton writes: >>In a message of Fri, 02 Oct 2015 22:36:23 -, Rob Gaddi writes: >>>So, this is odd. I'm running Ubuntu 14.04, and my system did a kernel >>>upgrade from the r

Re: PySide window does not resize to fit screen

2015-10-05 Thread Michael Torrie
On 10/05/2015 05:20 AM, Hedieh Ebrahimi wrote: > is this free to use for commercial use? Yes of course. There's also the newer Qt Creator program if you want to use Qt 5. The license of the Designer and Creator programs does not apply to the output of these programs (the .ui XML files). You'll

Re: Pyarmor, guard your python scripts

2015-10-05 Thread Josef Pktd
related https://youtu.be/wsczq6j3_bA?t=20m9s Josef -- https://mail.python.org/mailman/listinfo/python-list

Re: Parsing HTML with xml.etree in Python 2.7?

2015-10-05 Thread Skip Montanaro
On Mon, Oct 5, 2015 at 9:14 AM, Skip Montanaro wrote: > I wouldn't be surprised if there were some small API changes other than the > name change caused by the move into the xml package. Before I dive into a > rabbit hole and start to modify elementtidy, is there some other stdlib-only > way to pa

Re: Finding Blank Columns in CSV

2015-10-05 Thread Chris Angelico
On Tue, Oct 6, 2015 at 1:06 AM, Tim Chase wrote: > That way, if you determine by line 3 that your million-row CSV file > has no blank columns, you can get away with not processing all > million rows. Sure, although that effectively means the entire job is moot. I kinda assume that the OP knows th

Re: Finding Blank Columns in CSV

2015-10-05 Thread Tim Chase
On 2015-10-06 00:51, Chris Angelico wrote: > fn = "tmp1.csv" > fin = open(fn, 'rb') > rdr = csv.DictReader(fin, delimiter=',') > # all the same down to here > blanks = set(rdr.fieldnames) > for row in rdr: > blanks = {col for col in blanks if not row[col]} > mt = [col for col in rdr.fieldnames

Parsing HTML with xml.etree in Python 2.7?

2015-10-05 Thread Skip Montanaro
Back before Fredrik Lundh's elementtree module was sucked into the Python stdlib as xml.etree, I used to use his elementtidy extension module to clean up HTML source so it could be parsed into an ElementTree object. Elementtidy hasn't be updated in about ten years, and still assumes there is a modu

Re: Finding Blank Columns in CSV

2015-10-05 Thread Random832
On Mon, Oct 5, 2015, at 09:29, Jaydip Chakrabarty wrote: > Hello, > > I have a csv file like this. > > Name,Surname,Age,Sex > abc,def,,M > ,ghi,,F > jkl,mno,, > pqr,,,F > > I want to find out the blank columns, that is, fields where all the > values are blank. Here is my python code. > > fn =

Re: Finding Blank Columns in CSV

2015-10-05 Thread Chris Angelico
On Tue, Oct 6, 2015 at 12:48 AM, Chris Angelico wrote: > fn = "tmp1.csv" > fin = open(fn, 'rb') > rdr = csv.DictReader(fin, delimiter=',') > # all the same down to here > blanks = set(rdr.fieldnames) > for row in data: > blanks = {col for col in blanks if not row[col]} > mt = [col for col in r

Re: Finding Blank Columns in CSV

2015-10-05 Thread Chris Angelico
On Tue, Oct 6, 2015 at 12:29 AM, Jaydip Chakrabarty wrote: > I want to find out the blank columns, that is, fields where all the > values are blank. Here is my python code. > > fn = "tmp1.csv" > fin = open(fn, 'rb') > rdr = csv.DictReader(fin, delimiter=',') > data = list(rdr) > flds = rdr.fieldna

Finding Blank Columns in CSV

2015-10-05 Thread Jaydip Chakrabarty
Hello, I have a csv file like this. Name,Surname,Age,Sex abc,def,,M ,ghi,,F jkl,mno,, pqr,,,F I want to find out the blank columns, that is, fields where all the values are blank. Here is my python code. fn = "tmp1.csv" fin = open(fn, 'rb') rdr = csv.DictReader(fin, delimiter=',') data = list(

Re: PySide window does not resize to fit screen

2015-10-05 Thread Chris Warrick
On 5 October 2015 at 13:20, Hedieh Ebrahimi wrote: > is this free to use for commercial use? > -- > https://mail.python.org/mailman/listinfo/python-list Yeah, you can use Qt Designer to create a nice layout and the pyside-uic tool to generate code (that you will need to clean up later). -- Chri

Re: Check if a given value is out of certain range

2015-10-05 Thread Marko Rauhamaa
Chris Angelico : > On Mon, Oct 5, 2015 at 10:42 PM, Marko Rauhamaa wrote: >> Why not use a fricking class framework: >> >> Then, we could simply have: >> >> if Range(IncludedEndpoint(0), IncludedEndpoint(10)).outside(x): >> print("x has wrong value") >> else: >> print("x h

Re: Check if a given value is out of certain range

2015-10-05 Thread Chris Angelico
On Mon, Oct 5, 2015 at 10:42 PM, Marko Rauhamaa wrote: > Why not use a fricking class framework: > > Then, we could simply have: > > if Range(IncludedEndpoint(0), IncludedEndpoint(10)).outside(x): > print("x has wrong value") > else: > print("x has good value") > > Just for

Re: Check if a given value is out of certain range

2015-10-05 Thread Marko Rauhamaa
Jussi Piitulainen : > Michiel Overtoom writes: > >> Why not use a function? >> >> >> if outside(x, 0, 10): >> print("x has wrong value") >> else: >> print("x has good value") >> >> >> where 'outside' is defined as: >> >> def outside(value, lowerbound, upperbound): >>

Re: PySide window does not resize to fit screen

2015-10-05 Thread Hedieh Ebrahimi
is this free to use for commercial use? -- https://mail.python.org/mailman/listinfo/python-list

Re: PySide window does not resize to fit screen

2015-10-05 Thread Laura Creighton
In a message of Mon, 05 Oct 2015 01:18:33 -0700, Hedieh Ebrahimi writes: >Could you recommend any free designer software that I can create my user >interface with? > >Thank you Qt Designer works with PySide. http://doc.qt.io/qt-5/designer-quick-start.html Laura -- https://mail.python.org/mailm

Re: reg multiple login python

2015-10-05 Thread harirammanohar159
On Thursday, 1 October 2015 12:35:01 UTC+5:30, hariramm...@gmail.com wrote: > Hi All, > > Is there anyway i can login to remote servers at once and do the activity, i > can do one by one using for loop.. > > Thanks in advance. Hi All, I am able to achieve it using multiprocessing package...

Re: Check if a given value is out of certain range

2015-10-05 Thread Jussi Piitulainen
Michiel Overtoom writes: > Why not use a function? > > > if outside(x, 0, 10): > print("x has wrong value") > else: > print("x has good value") > > > where 'outside' is defined as: > > def outside(value, lowerbound, upperbound): > return value < lowerbound or va

Re: Check if a given value is out of certain range

2015-10-05 Thread Mark Lawrence
On 05/10/2015 09:18, Michiel Overtoom wrote: Why not use a function? if outside(x, 0, 10): print("x has wrong value") else: print("x has good value") where 'outside' is defined as: def outside(value, lowerbound, upperbound): return value < lowerboun

Re: PySide window does not resize to fit screen

2015-10-05 Thread Hedieh Ebrahimi
Hi Chris, Thanks for your answer. I get your point now. Unfortunately there are not layouts in my user interface. Smaller widget have been grouped using group boxes and then all these group boxes are put on the central widget. I would like to recreate my user interface using one of the design

Re: Check if a given value is out of certain range

2015-10-05 Thread Michiel Overtoom
Why not use a function? if outside(x, 0, 10): print("x has wrong value") else: print("x has good value") where 'outside' is defined as: def outside(value, lowerbound, upperbound): return value < lowerbound or value > upperbound Greetings, -- https://ma

Re: python and ARM memory types

2015-10-05 Thread dieter
voxner@gmail.com writes: > ... > But how do I specify (streaming,write-combining,write-back) memory types in > python ? Is there a library that I can use ? I am thinking of programming > some fixed memory space (say 0x1000_000 - 0x2000_000) as "WC or WT or > streaming" using the OS and then