RE: reduction

2016-05-31 Thread Dan Strohl via Python-list
ch object itself. (good for more complex issues, but probably increases the size of each object) - create an index or caching structure of some sort as you find the objects, (good for saving computation time if the determination is "hard" and you hit the same ones again and again) - create a dictionary structure instead of a list. (good for fast lookups with known data) - using something like pandas or another data analysis library (SciPy, NumPy, iPython Notebook). (especially good if your data is more numbers based than you seem to be indicating) - writing the data to a database and using that for matching. (good If you have LOTS of data to compare). Some of these are probably overkill, some probably won't work at all for what you are trying to achieve. Dan -- https://mail.python.org/mailman/listinfo/python-list

Re: Recommendation for GUI lib?

2016-06-07 Thread Roland Koebler via Python-list
Python-bindings. But I was never happy with Qt and think some GUI-concepts of GTK+ are much better than the ones of Qt, and I like Glade much more than the Qt designer. best regards Roland -- https://mail.python.org/mailman/listinfo/python-list

Re: i'm a python newbie & wrote my first script, can someone critique it?

2016-06-10 Thread Larry Hudson via Python-list
than variables. But in general (in all programming languages) it is usually better and safer to avoid globals if possible. # -------- # NOW FINISH print("" + get_timestamp() + " " + get_script_filename() + " FINISHED.") #import os #os._exit(0) Yes, your exit() is redundant and you are correct to comment it out. But again I suggest that you get used to using print formatting, it is really versatile. -- -=- Larry -=- -- https://mail.python.org/mailman/listinfo/python-list

Re: how to search item in list of list

2016-06-13 Thread Larry Hudson via Python-list
7;01': 1}, ['000', '0 01', '010', '011', '100', '101', '110', '111'], 'yz', 'start')], [(2, {'11': 1, '10': 0, '00': 1, '01': 1}, ['000', '001', '010', '011', '100', '101', '110', '1 11'], 'xz', 'start')], [(1, {'11': 1, '10': 1, '00': 0, '01': 1}, ['00', '01', ' 11', '11', '10', '11', '11', '11'], 'xy', 'node')], [(1, {'11': 1, '10': 1, '00' : 0, '01': 1}, ['00', '01', '10', '11', '11', '11', '11', '11'], 'xy', 'node')], [(1, {'11': 1, '10': 1, '00': 0, '01': 1}, ['00', '00', '10', '10', '10', '10', '11', '11'], 'xy', 'node')], [(1, {'11': 1, '10': 1, '00': 0, '01': 1}, ['00', '00', '10', '11', '10', '10', '10', '11'], 'xy', 'node')], [(1, {'11': 1, '10': 1, '00': 0, '01': 1}, ['00', '00', '10', '10', '10', '11', '10', '11'], 'xy', 'n ode')]] I (manually) reformatted your list and found you have a missing left square bracket in the middle. But the way your list is formatted here I really can't tell you where it is -- you'll have to reformat it and/or use an editor that highlights matching brackets to find it yourself. Most programming editors have that bracket matching capability. -- -=- Larry -=- -- https://mail.python.org/mailman/listinfo/python-list

Proposal: named return values through dict initialization and unpacking

2016-06-21 Thread Ari Freund via Python-list
**RunShellCmd("ls .") # Here we don't care about order. -- https://mail.python.org/mailman/listinfo/python-list

Re: ASCII or Unicode? (was best text editor for programming Python on a Mac)

2016-06-21 Thread Larry Hudson via Python-list
Mint Linux (and I think Ubuntu is the same. I don't know about other distros.): From the menu, select Preferences->Keyboard->Layouts->Options->Position of Compose Key This opens a list of checkboxes with about a dozen choices -- select whatever you want (I use the Menu key). -- -=- Larry -=- -- https://mail.python.org/mailman/listinfo/python-list

Re: Operator Precedence/Boolean Logic

2016-06-22 Thread Larry Hudson via Python-list
in the design of Python... Wart?? I *strongly* disagree. I find it one of the strengths of Python, it enhances Python's expressiveness. Of course, everyone is entitled to their own opinion...and this is mine. -- -=- Larry -=- -- https://mail.python.org/mailman/listinfo/python-list

Pandas to CSV and .dbf

2016-06-23 Thread David Shi via Python-list
Has anyone tested on Pandas to CSV and .dbf lately? I am looking for proven, tested examples to output Panda Data Frame to CSV and dbf files. Looking forward to hearing from you. Regards. David -- https://mail.python.org/mailman/listinfo/python-list

Which one is the best XML-parser?

2016-06-23 Thread David Shi via Python-list
Which one is the best XML-parser? Can any one tell me? Regards. David -- https://mail.python.org/mailman/listinfo/python-list

Which one is the best JSON parser?

2016-06-23 Thread David Shi via Python-list
Can any one tell me? Regards. David -- https://mail.python.org/mailman/listinfo/python-list

How to reset IPython notebook file association

2016-06-25 Thread David Shi via Python-list
-- https://mail.python.org/mailman/listinfo/python-list

JSON to Pandas data frame

2016-06-25 Thread David Shi via Python-list
How to convert a JSON object into a Pandas data frame? I know that for XML, there are XML parsers. Regards. David -- https://mail.python.org/mailman/listinfo/python-list

Re: Proposal: named return values through dict initialization and unpacking

2016-06-26 Thread Ari Freund via Python-list
Thanks everybody. There seems to be a lot of resistance to dict unpacking, in addition to the problem with my proposed shorthand dict() initialization syntax pointed out by Steven D'Aprano, so I won't be pursuing this. -- https://mail.python.org/mailman/listinfo/python-list

Live installation of Pandas for Windows 64

2016-06-27 Thread David Shi via Python-list
Is there a live installation of Pandas for Windows 64? Regards. David -- https://mail.python.org/mailman/listinfo/python-list

Re: Appending an asterisk to the end of each line

2016-07-05 Thread Larry Hudson via Python-list
's empty. Not your problem, but you can simplify your read/write loop to: for line in f_in: f_out.write(line[:-1] + ' *\n') The 'line[:-1]' expression gives you the line up to but not including the trailing newline. Alternately, use: f_out.write(line.rstrip() + ' *\n') -- -=- Larry -=- -- https://mail.python.org/mailman/listinfo/python-list

How asyncio works? and event loop vs exceptions

2016-07-22 Thread Marco S. via Python-list
non-blocking, but in this case exceptions can't be caught in a try statement. Is this correct? If so, asyncio programming style can't be a little divergent from what was the philosophy of Python until now? -- https://mail.python.org/mailman/listinfo/python-list

Re: Why not allow empty code blocks?

2016-07-24 Thread Marco Sulla via Python-list
e): __tablename__ = 'parent' id = Column(Integer, primary_key=True) children = relationship("Child"), # comma inserted by error. children will be a tuple and SQLAlchemy will fail with misleading errors -- https://mail.python.org/mailman/listinfo/python-list

Re: How asyncio works? and event loop vs exceptions

2016-07-25 Thread Marco Sulla via Python-list
On 23 July 2016 at 16:06, Ian Kelly wrote: > On Fri, Jul 22, 2016 at 6:27 PM, Marco S. via Python-list > wrote: >> Furthermore I have a question about exceptions in asyncio. If I >> understand well how it works, tasks exceptions can be caught only if >> you wait for tas

Two constructive reviewers sought

2016-07-27 Thread David Shi via Python-list
be one of reviewers, please email [email protected] with your full contact details. Regards. David -- https://mail.python.org/mailman/listinfo/python-list

Python slang

2016-08-05 Thread Marco Sulla via Python-list
matter of disambiguation (null, in many languages, is not equal to null). -- https://mail.python.org/mailman/listinfo/python-list

Re: Python slang

2016-08-06 Thread Marco Sulla via Python-list
On 6 August 2016 at 00:31, Chris Angelico wrote: > On Sat, Aug 6, 2016 at 8:00 AM, Marco Sulla via Python-list > wrote: > This isn't slang; it's jargon Right. >> * `raise` instead of `throw` > > Quite a few other languages talk about raising exceptions rather th

Re: Python slang

2016-08-06 Thread Michael Selik via Python-list
On Sat, Aug 6, 2016, 10:10 AM Marco Sulla via Python-list < [email protected]> wrote: > On 6 August 2016 at 00:31, Chris Angelico wrote: > > On Sat, Aug 6, 2016 at 8:00 AM, Marco Sulla via Python-list > > wrote: > >> * `dict` instead of `map` > > >

Re: Python slang

2016-08-06 Thread Marco Sulla via Python-list
On 6 August 2016 at 20:03, Michael Selik wrote: > On Sat, Aug 6, 2016, 10:10 AM Marco Sulla via Python-list > wrote: >> >> On 6 August 2016 at 00:31, Chris Angelico wrote: >> > "map" has many other meanings (most notably the action wherein you >

Re: Python slang

2016-08-06 Thread Marco Sulla via Python-list
ane words come out my mouth and a little >> fairy dies. >> > > You open your mouth and a fairy dies hmm. Can I offer you a breath mint? > :) Do you have also a plenary indulgence? -- https://mail.python.org/mailman/listinfo/python-list

Re: Python slang

2016-08-06 Thread Marco Sulla via Python-list
rding to > Wolfram Alpha, the average length of words in English is 5.1 characters: > > http://www.wolframalpha.com/input/?i=average+english+word+length > > but of the ten most common words themselves, nine are of three or fewer > characters: > > "the of to and a in is it you that" And according to Wolfram Alpha, the readability of Huckleberry Finn is 5.5. I think it doesn't fit in this discussion in the same way :P -- https://mail.python.org/mailman/listinfo/python-list

Re: Python slang

2016-08-06 Thread Marco Sulla via Python-list
> ?column? > -- > NULL > (1 row) > > But SQL's NULL is a cross between C's NULL, IEEE's NaN, Cthulhu, and Emrakul. Yes, I was thinking manly to SQL. That furthermore is NOT a programming language. So I suppose I have also to ask why "None" instead of "Null" -- https://mail.python.org/mailman/listinfo/python-list

Network protocols, sans I/O,(Hopefully) the future of network protocols in Python

2016-08-08 Thread Mark Lawrence via Python-list
This may be of interest to some of you http://www.snarky.ca/network-protocols-sans-i-o -- My fellow Pythonistas, ask not what our language can do for you, ask what you can do for our language. Mark Lawrence -- https://mail.python.org/mailman/listinfo/python-list

Re: Issue in parsing the strings in python code

2018-11-12 Thread Brian Oney via Python-list
t; > That looks conveniently aligned. Can't you just slice each line to get > the entries you are after? > I believe the idea is to allow the help seeker to piece the following puzzle together. $ nmcli -t NAME,SOMETHINGELSE c show >>> help(subprocess.Popen) >>>

Re: IDLE Default Working Directory

2018-11-12 Thread Brian Oney via Python-list
p", "copyright", "credits" or "license" for more information.>>> import pyhelp.change_to_current_dirCurrent directory is:/home/oneyDirectory of this file is:/home/oney/pyhelp/change_to_current_dir.pyCurrent directory now is:/home/oney/pyhelp>>>  HTH -- https://mail.python.org/mailman/listinfo/python-list

Re: IDLE Default Working Directory

2018-11-14 Thread Brian Oney via Python-list
/project/directory') That is brittle though. What if the student don't all have access to that directory? What if they fail to put the project directory in the right place? What if the network drives are down and you end up working locally? You could send them a zip-file of everything including my first suggestion and it would just work. HTH -- https://mail.python.org/mailman/listinfo/python-list

Re: All of a sudden code started throwing errors

2018-11-14 Thread Brian Oney via Python-list
On Wed, 2018-11-14 at 09:47 +0100, srinivasan wrote: > -68 >= -60 It's a problem with your test of wifi strength. Good job of making informative output and running tests! -- https://mail.python.org/mailman/listinfo/python-list

Re: how to match list members in py3.x

2018-11-25 Thread Brian Oney via Python-list
python syntax consider the py3 tutorial. https://docs.python.org/3/tutorial/index.html HTH -- https://mail.python.org/mailman/listinfo/python-list

Python2.7 unicode conundrum

2018-11-25 Thread Robert Latest via Python-list
0 69 6e 74 28 28 73 2c 20 29 29 0a 0a |int((s,))..| 003c dh@jenna:~/python$ python unicode.py ä (u'\xe4',) dh@jenna:~/python$ -- https://mail.python.org/mailman/listinfo/python-list

Re: Python2.7 unicode conundrum

2018-11-26 Thread Robert Latest via Python-list
e right, this wasn't the minimal example for my problem after all. Turns out that the actual issue is somewhere between SQLAlchemy and MySQL. I took a more specific questioon overt to stackoverflow.com Thanks robert -- https://mail.python.org/mailman/listinfo/python-list

Re: Error Python version 3.6 does not support this syntax.

2018-11-27 Thread Brian Oney via Python-list
xception HTW -- https://mail.python.org/mailman/listinfo/python-list

Re: What Python books to you recommend to beginners?

2018-11-28 Thread Brian Oney via Python-list
oks for just that. Given your audience "Python for Data Analysis, 2nd Edition" by Wes McKinney would suit well. The Python tutorial should suit for basic syntax. HTH -- https://mail.python.org/mailman/listinfo/python-list

Side by side comparison - CPython, nuitka, PyPy

2018-12-21 Thread Anthony Flury via Python-list
/mailman/listinfo/python-list

Undocumented issue: Open system call blocks on named pipes (and a feature request)

2018-12-27 Thread Daniel Ojalvo via Python-list
mented. The feature request would be to add a non-blocking option to the default open system call. I've also found this with some named special character files, but I don't have a reproduction at the moment. Thank you and have a good day! Dan -- https://mail.python.org/mailman/listinfo/python-list

RE: Undocumented issue: Open system call blocks on named pipes (and a feature request)

2018-12-28 Thread Daniel Ojalvo via Python-list
diagnose. That all being said, I think I would like to put in a feature request for a non-blocking option. How should I go about doing so? Thanks again, Dan -Original Message- From: Chris Angelico Sent: Thursday, December 27, 2018 7:10 PM To: [email protected] Subject: Re: Undocume

Re: mouse click automation

2019-01-01 Thread Brian Oney via Python-list
I am unfamiliar with pynput. I have had good experience with pyautogui. As your script isn't yet advanced, you may consider it. https://pyautogui.readthedocs.io/en/latest/introduction.html -- https://mail.python.org/mailman/listinfo/python-list

Re: Encounter issues to install Python

2019-01-06 Thread Olivier Oussou via Python-list
On 08/10/18 20:21, Olivier Oussou via Python-list wrote: Hi!I downloaded and installed python 3.6.4 (32-bit) on my computer but I have problems and can not access the python interface. I need your technical assistance to solve this matter.  Best regard! Olivier OUSSOUMedical entomologist,

Re: How to find files with a string

2019-01-09 Thread Brian Oney via Python-list
ed with exit code 1 > > Could you help me to solve this thread? the error message is somewhat clear. You need to add a key-value pair to a dictionary. You may consider changing 'res' to a 'list'. You then need to 'append'. Either way, 'find_value' will return the filename regardless of whether the value is present or not. That should get you started. -- https://mail.python.org/mailman/listinfo/python-list

Re: Encounter issues to install Python

2019-01-15 Thread Anthony Flury via Python-list
access, and how are you doing that ? * Do you get error messages? Unless you tell us what the problem is we can't possibly help. On 08/10/18 20:21, Olivier Oussou via Python-list wrote: Hi!I downloaded and installed python 3.6.4 (32-bit) on my computer but I have problems and can n

ANN: A new version (0.4.4) of python-gnupg has been released. It contains a security-related change - please update to this version

2019-01-24 Thread Vinay Sajip via Python-list
ot; if verified else "Not verified" 'Verified' As always, your feedback is most welcome (especially bug reports [3],patches and suggestions for improvement, or any other points via themailing list/discussion group [4]). Enjoy! Cheers Vinay SajipRed Dove Consultants Ltd. [1] https://bitbucket.org/vinay.sajip/python-gnupg[2] https://pypi.python.org/pypi/python-gnupg/0.4.4[3] https://bitbucket.org/vinay.sajip/python-gnupg/issues[4] https://groups.google.com/forum/#!forum/python-gnupg[5] https://bitbucket.org/vinay.sajip/python-gnupg/downloads/ -- https://mail.python.org/mailman/listinfo/python-list

Can't run setup.py offline due to setup_requires - setup.py calls home

2019-02-11 Thread Chris Narkiewicz via Python-list
06d2443f2a4d5ddc9f6a5554a0322aaed99: [Errno 111] Connection refused Is there any way to stop Distutils from calling home? Best regards, Chris Narkiewicz -- https://mail.python.org/mailman/listinfo/python-list

Re: Can't run setup.py offline due to setup_requires - setup.py calls home

2019-02-11 Thread Chris Narkiewicz via Python-list
Is there any extra step I have to take? Best regards, Chris signature.asc Description: OpenPGP digital signature -- https://mail.python.org/mailman/listinfo/python-list

Re: Can't run setup.py offline due to setup_requires - setup.py calls home

2019-02-11 Thread Chris Narkiewicz via Python-list
On 11/02/2019 19:30, Chris Narkiewicz via Python-list wrote: > Is there any extra step I have to take? Ok, I'll respond to myself, as this was really silly. Debian ships hopelessly obsolete pip 9.PEP 518 is supported in pip 10+. Cheers, Chris signature.asc Description: OpenPGP

Using PyArg_ParseTuple to with optional fields.

2019-02-28 Thread Anthony Flury via Python-list
[email protected] <mailto:[email protected]> *Twitter* : @TonyFlury <https://twitter.com/TonyFlury/> -- https://mail.python.org/mailman/listinfo/python-list

Extension Module for Python 3.6 +

2019-03-01 Thread Anthony Flury via Python-list
[email protected]> *Twitter* : @TonyFlury <https://twitter.com/TonyFlury/> -- https://mail.python.org/mailman/listinfo/python-list

pydistutils.cfg injection

2019-03-11 Thread Chris Narkiewicz via Python-list
hile working for me, could still be an issue for somebody else. What do you think? Is such change feasible? I can make a patch - how to submit it? Best regards, Chris Narkiewicz signature.asc Description: OpenPGP digital signature -- https://mail.python.org/mailman/listinfo/python-list

Text Similarity/Comparison Question

2019-03-26 Thread David Lynch via Python-list
MAC: D1050-262 Cell: 704-408.5157 [email protected]<mailto:[email protected]> [WellsFargoLogo_w_SC] -- https://mail.python.org/mailman/listinfo/python-list

RE: Generating generations of files

2019-04-30 Thread Avi Gross via Python-list
ser choosing odd names may cause unusual problems in some cases. -- https://mail.python.org/mailman/listinfo/python-list

Re: PYTHON equivalents of BITAND and BITSHIFT of MATLAB

2019-05-01 Thread Brian Oney via Python-list
d rounding to the nearest integer towards negative infinity. Any overflow bits are truncated. ' So the equivalent would be: >>> typeBits = FCF >> 9 Cheers Brian -- https://mail.python.org/mailman/listinfo/python-list

Re: CAD Application

2019-05-06 Thread Brian Oney via Python-list
FreeCAD is written in Python. It has a python interpreter. -- https://mail.python.org/mailman/listinfo/python-list

Building a statically linked Python, and pip

2019-05-07 Thread Simon Michnowicz via Python-list
Centre* Monash University 15 Innovation Walk, Building 75, Clayton Campus Wellington Road, VIC 3800 Australia T: +61 3 9902 0794 M: +61 3 0418 302 046 E: [email protected] monash.edu -- https://mail.python.org/mailman/listinfo/python-list

Re: Automate extract domain

2019-05-12 Thread Jon Ribbens via Python-list
ou mean just the top level? In which case you can just do fullname.rsplit(".", 1)[-1]. If you mean "the registrable domain" (such as example.com, example.co.uk, etc) then you will need to look at https://publicsuffix.org/ -- https://mail.python.org/mailman/listinfo/python-list

ANN: distlib 0.2.9 released on PyPI

2019-05-14 Thread Vinay Sajip via Python-list
uggestions for improvements,please give some feedback using the issue tracker! [3] Regards, Vinay Sajip [1] https://pypi.org/project/distlib/0.2.9/[2] https://distlib.readthedocs.io/en/latest/overview.html#change-log-for-distlib[3] https://bitbucket.org/pypa/distlib/issues/new -- https://mail.python.org/mailman/listinfo/python-list

Why Python has no equivalent of JDBC of Java?

2019-05-19 Thread Marco Sulla via Python-list
E and LD_LIBRARY_PATH Finally, you can use cx_Oracle. Java? You have only to download ojdbcN.jar and add it to Maven/Gradle. Why Python has no equivalent to JDBC? -- https://mail.python.org/mailman/listinfo/python-list

Re: Why Python has no equivalent of JDBC of Java?

2019-05-20 Thread Marco Sulla via Python-list
anies uses Oracle unluckily. Oracle and MSSQL. And I must say that surprisingly, being a Microsoft product, I find MSSQL more simple to install than Oracle, like Postregres, and has an easier SQL syntax. Like Postgres. -- https://mail.python.org/mailman/listinfo/python-list

Re: PEP 594 cgi & cgitb removal

2019-05-23 Thread Jon Ribbens via Python-list
apache, or (local only) even CGIHTTPServer.py. I don't know what the > current hotness in httpd's is though. nginx is the current hotness. CGI has not been hotness since the mid 90s. -- https://mail.python.org/mailman/listinfo/python-list

RE: More CPUs doen't equal more speed

2019-05-23 Thread Avi Gross via Python-list
months or years if run exhaustively on something like a grid search trying huge numbers of combinations. Good luck. Avi -Original Message----- From: Python-list On Behalf Of Bob van der Poel Sent: Thursday, May 23, 2019 2:40 PM To: Python Subject: More CPUs doen't equal more speed I&#

Re: PEP 594 cgi & cgitb removal

2019-05-24 Thread Jon Ribbens via Python-list
far as I can tell, it's just a script to automatically upload bits of code into various cloud providers, none of which use CGI. -- https://mail.python.org/mailman/listinfo/python-list

Re: PEP 594 cgi & cgitb removal

2019-05-25 Thread Jon Ribbens via Python-list
On 2019-05-25, Michael Torrie wrote: > On 05/24/2019 04:27 AM, Jon Ribbens via Python-list wrote: >> Sorry, in what sense do you mean "Serverless is CGI"? >> >> As far as I can tell, it's just a script to automatically upload >> bits of code into vari

Re: Why Python has no equivalent of JDBC of Java?

2019-06-16 Thread Marco Sulla via Python-list
braries. So in this particular case Python *could* be more performant than Java. I don't know, you should do some benchmark with different queries, different in nature, complexity and number of rows retrieved, on the same db, accessed once with Java and once with Python. The problem is benchmarking Java not so easy as Python. It's very boring. -- https://mail.python.org/mailman/listinfo/python-list

Subprocess

2019-06-17 Thread Douglas Beard via Python-list
mail.python.org/mailman/listinfo/python-list

Re: How do you insert an item into a dictionary (in python 3.7.2)?

2019-06-28 Thread Jon Ribbens via Python-list
.6 onwards - dicts are ordered. There's no way to insert an item anywhere other than at the end though. -- https://mail.python.org/mailman/listinfo/python-list

Re: Handle foreign character web input

2019-06-29 Thread Alan Meyer via Python-list
hat to choose depends on your needs and resources. And of course all bets are off if some of your data is Chinese, Japanese, Hebrew, or maybe even Russian or Greek. Sometimes I think, Why don't we all just learn Esperanto? But we all know that that isn't going to happen. Alan -- https://mail.python.org/mailman/listinfo/python-list

Re: Handle foreign character web input

2019-06-29 Thread Jon Ribbens via Python-list
27; will do a decent stab of it if the language is vaguely European. Certainly, storing the UTF-8 string and also the 'unidecoded' ASCII string and searching on both is unlikely to hurt and will often help. Additionally using Metaphone or similar will probably also help. -- https://mail.python.org/mailman/listinfo/python-list

Re: Do I need a parser?

2019-06-29 Thread Alan Meyer via Python-list
iera hablar español tan bien como usted habla inglés, estaría muy feliz. (You should have seen what that looked like before I applied Google Translate :) Alan -- https://mail.python.org/mailman/listinfo/python-list

Cannot delete or modify

2019-07-09 Thread Hla Kyi via Python-list
Dear Sir / Madam,     I have subscribed mailing Python-list.    I have installed and used " Python 3.7.2". I try to modify or uninstall it. Please see the attached screen shot.    Please help me how to uninstall and modify. Best Regards. Kyi - Modify.jpg49kB python-list-requ...@

load extention spatialite in sqlite on windows

2019-07-10 Thread MICHAEL LANE via Python-list
/mydll/mod_sptatialite' But I got the same error. conn.load_extension('c:\\mydll\\mod_spatialite') sqlalchemy.exc.OperationalError: (sqlite3.OperationalError) OsError 0xc1 (193) (Background on this error at: http://sqlalche.me/e/e3q8) My directory contain the unzip of: http://www.gaia-gis.it/gaia-sins/windows-bin-x86/mod_spatialite-4.3.0a-win-x86.7z The directory is set in %PATH% Any hint will be appreciated. Thanks Michael -- https://mail.python.org/mailman/listinfo/python-list

Problem to delete or modify

2019-07-10 Thread Hla Kyi via Python-list
Dear Sir/ Madam,     1. I try to modify, some of the check boxes can not be selected.    2. I try to uninstall, "successfully uninstall" message is come out. When I exit it "if you have any problem, please contact  [email protected] " message is come out.     I instal

Problem to delete or modify Python program and to read "signature.asc"

2019-07-11 Thread Hla Kyi via Python-list
Dear Sir/ Madam,     1. I try to modify, some of the check boxes can not be selected.    2. I try to uninstall, "successfully uninstall" message is come out. When I exit it "if you have any problem, please contact  [email protected] " message is come out.     I instal

Re: How to execute shell command in Python program?

2019-07-20 Thread Chris Narkiewicz via Python-list
immicks. If you want to feed the command from stdin, this becomes a bit more complicated as you need to start a subprocess and use PIPE to feed it. Cheers, Chris Narkiewicz signature.asc Description: OpenPGP digital signature -- https://mail.python.org/mailman/listinfo/python-list

Re: Proper shebang for python3

2019-07-20 Thread Brian Oney via Python-list
min/ Nice. Emacs (well spacemacs) is my authority. The key sequence 'SPC i !' inserts #!/usr/bin/env python as specified in the insert-shebang package https://github.com/psachin/insert-shebang My limited experience tells me to expect the user (me) to know what they're doing, hence env. Why not make a compromise? What would be a potential pitfall of the following spitbang? #!python -- https://mail.python.org/mailman/listinfo/python-list

Re: Proper shebang for python3

2019-07-21 Thread Brian Oney via Python-list
od decision. Most of the conversation applies to sysadmins concerned with answering your question in absolute terms. When you start writing scripts which are restricted to a specific environment and are intended to be distributed, you may revisit this thread. Be blissful until then :). Chris et al have "fixed" things for you. -- https://mail.python.org/mailman/listinfo/python-list

Difference between os.path.isdir and Path.is_dir

2019-07-25 Thread Maksim Fomin via Python-list
" > >>> os.path.isdir(dummy) > > False > >>> Path(dummy).is_dir() > > True > > > or was it overlooked? > > with kind regards, > -gdg > > - > > https://mail.python.org/mailm

Re: [Python-ideas] Fwd: Re: PEP: add a `no` keyword as an alias for `not`

2019-08-02 Thread Andrew Barnert via Python-list
sales and isopen:`, but it would do the wrong thing if `no` is special syntax that reverses the sense of the `if` rather than a normal operator that binds more tightly than `and`. -- https://mail.python.org/mailman/listinfo/python-list

Re: if bytes != str:

2019-08-04 Thread Jon Ribbens via Python-list
to_bytes = lambda s: s.encode('utf-8') if isinstance(s, str) else s to_str = lambda b: b.decode('utf-8') if isinstance(b, bytes) else b -- https://mail.python.org/mailman/listinfo/python-list

Re: _unquote

2019-08-04 Thread Jon Ribbens via Python-list
higher up in the file you mention in order to find where it's imported: from six.moves.urllib.parse import urlparse, unquote as _unquote So it's 'six.moves.urllib.parse.unquote'... Look up the package 'six' on pypi to find its documentation: https://pypi.org/project/six/ -- https://mail.python.org/mailman/listinfo/python-list

Re: Please help me

2019-08-06 Thread Brian Oney via Python-list
ages/python or https://realpython.com/python-development-visual-studio-code/ -- https://mail.python.org/mailman/listinfo/python-list

How do i execute some code when I have subscribed to a topic with a message payload for mqtt in python?

2019-08-08 Thread Spencer Du via Python-list
age to topic","microscope/light_sheet_microscope/UI") client.publish("microscope/light_sheet_microscope/UI",device) time.sleep(2) # wait print("subscribing ") client.subscribe("microscope/light_sheet_microscope/UI") client.loop_stop() #stop the loop Thanks Spencer -- https://mail.python.org/mailman/listinfo/python-list

Re: How do i execute some code when I have subscribed to a topic with a message payload for mqtt in python?

2019-08-08 Thread Spencer Du via Python-list
e to topic","microscope/light_sheet_microscope/UI") > client.publish("microscope/light_sheet_microscope/UI",device) > time.sleep(2) # wait > print("subscribing ") > client.subscribe("microscope/light_sheet_microscope/UI") > client.loop_stop() #stop the loop > > Thanks > Spencer -- https://mail.python.org/mailman/listinfo/python-list

Re: Web framework for static pages

2019-08-12 Thread Brian Oney via Python-list
oking forward to further answers. HTH -- https://mail.python.org/mailman/listinfo/python-list

ANN: A new version (0.4.5) of python-gnupg has been released.

2019-08-12 Thread Vinay Sajip via Python-list
points via themailing list/discussion group [4]). Enjoy! Cheers Vinay SajipRed Dove Consultants Ltd. [1] https://bitbucket.org/vinay.sajip/python-gnupg[2] https://pypi.org/project/python-gnupg/0.4.5[3] https://bitbucket.org/vinay.sajip/python-gnupg/issues[4] https://groups.google.com/forum/#!forum/python-gnupg[5] https://bitbucket.org/vinay.sajip/python-gnupg/downloads/-- -- https://mail.python.org/mailman/listinfo/python-list

Re: Web framework for static pages

2019-08-12 Thread Jon Ribbens via Python-list
be entirely served by for example Apache. If it's really that small then it sounds like what you are looking for is known as a "text editor". -- https://mail.python.org/mailman/listinfo/python-list

Re: Web framework for static pages

2019-08-13 Thread Jon Ribbens via Python-list
developer - as a user you just use the Liquid templating system, which is more-or-less identical to Django's. -- https://mail.python.org/mailman/listinfo/python-list

Re: Web framework for static pages

2019-08-13 Thread Jon Ribbens via Python-list
ot;malformed". Just use HTML 5, and indeed you should check your code to ensure it is pure, perfect and well-formed. -- https://mail.python.org/mailman/listinfo/python-list

Re: Web framework for static pages

2019-08-13 Thread Brian Oney via Python-list
L HTML 5? Is it the >ability >to write websites using a text editor only what makes web companies >continue the malformed input cycle, or is it legacy websites? > >-Morten It's all text. Or do you have a better suggestion? What is wrong with templates? -- https://mail.python.org/mailman/listinfo/python-list

How do I decouple these two modules?

2019-08-28 Thread Spencer Du via Python-list
ght_sheet_microscope/UI") def on_message(self, mqttc, userdata, message): msg = str(message.payload.decode("utf-8")) print("File which you want to import(with .py extension)") print("message topic=", message.topic) print("message qos=", message.qos) print("message retain flag=", message.retain) def run(self): self.connect("broker.hivemq.com", 1883, 60) Thanks Spencer -- https://mail.python.org/mailman/listinfo/python-list

unable to to install paython

2019-08-28 Thread Alemu Geletew via Python-list
-- https://mail.python.org/mailman/listinfo/python-list

Re: open, close

2019-08-31 Thread Max Zettlmeißl via Python-list
x27;t be called. -- https://mail.python.org/mailman/listinfo/python-list

Re: open, close

2019-09-01 Thread Max Zettlmeißl via Python-list
se from such simple examples. After all, if all the program does is process one file and shut down afterwards, this would not be an aspect to worry about. -- https://mail.python.org/mailman/listinfo/python-list

PYTHON DIDNT DETECTED

2019-09-01 Thread АРТЁМ БОЗАДЖИ via Python-list
0x031DFC50> Python 3.7.4 (tags/v3.7.4:e09359112e, Jul 8 2019, 19:29:22) [MSC v.1916 32 bit (Intel)] on win32 Type "help", "copyright", "credits" or "license" for more information. import 'atexit' # >>>                                                                                                                                                                                                                                                                                                                                                           С уважением, АРТЁМ БОЗАДЖИ [email protected] -- https://mail.python.org/mailman/listinfo/python-list

Re: "Edit With Python" option missing

2019-09-01 Thread DL Neil via Python-list
ram without editing the code, most of us utilise 'the command line', eg python3 source.py -- Regards =dn -- https://mail.python.org/mailman/listinfo/python-list

How to create list for stuff inside mqtt and GUI?.

2019-09-01 Thread Spencer Du via Python-list
== 0: print("Connected to broker") else: print("Connection failed") # mqttc.subscribe("microscope/light_sheet_microscope/UI") def on_message(self, mqttc, userdata, message): msg = str(message.payload.decode("utf-8")) print("message recieved= " + msg) # print("File which you want to import(with .py extension)") print("message topic=", message.topic) print("message qos=", message.qos) print("message retain flag=", message.retain) def run(self): self.connect("broker.hivemq.com", 1883, 60) Thanks. -- https://mail.python.org/mailman/listinfo/python-list

Re: Hi how do I import files inside a txt file?

2019-09-02 Thread DL Neil via Python-list
evices.txt" as test1,test2 Take care to read them as comma separated. Or if you have control then write them on separate lines. Regards. -- Pankaj Jangid Hi Pankaj I dont understand so what is complete code then? Thanks Spencer -- https://mail.python.org/mailman/listinfo/python-list Pard

Re: How to remove a string from a txt file?

2019-09-04 Thread DL Neil via Python-list
far? How to identify the beginning of the sub-string to be removed? How to identify the end of the sub-string? How does one "remove a string" AND "kept in this format"? -- Regards =dn -- https://mail.python.org/mailman/listinfo/python-list

Re: Formatting floating point

2019-09-04 Thread DL Neil via Python-list
On 5/09/19 5:12 AM, Dave via Python-list wrote: ... My question is why, and where do I find a reliable source of information on formatting numbers?  Not interested in replacement values like '{} {}'.format(1, 2). Agreed: there's ton(ne)s of information 'out there&

Re: Finding lines in .txt file that contain keywords from two different set()

2019-09-08 Thread DL Neil via Python-list
picked-out of the sets of files (easy tests - for *only* those small section of the code!), or that the logic linking the key-words is faulty (another *small* test, easily coded - and at first fed with 'fake' key-words which prove the various test cases, and thus, when run, (attempt to) prove your logic and code!) -- Regards =dn -- https://mail.python.org/mailman/listinfo/python-list

<    30   31   32   33   34   35   36   37   38   39   >