Re: Python scope question

2019-03-12 Thread Arup Rakshit
Hello, Thanks for this beautiful link. This is amazing. Thanks, Arup Rakshit a...@zeit.io > On 13-Mar-2019, at 12:11 AM, DL Neil wrote: > > Arup, > > > On 13/03/19 3:38 AM, Arup Rakshit wrote: >> I have questions how nonlocal and global affecting the variable assignment. >> Also how ea

[RELEASE] Python 3.7.3rc1 is now available for testing.

2019-03-12 Thread Ned Deily
Python 3.7.3rc1 is now available for testing. 3.7.3rc1 is the release preview of the next maintenance release of Python 3.7, the latest feature release of Python. Assuming no critical problems are found prior to 2019-03-25, no code changes are planned between now and the final release. This release

Re: 3D visualizations in Python

2019-03-12 Thread Larry Martell
On Tue, Mar 12, 2019 at 6:55 PM Jakub Bista wrote: > > Hello. I want to do 3D visualization in Python. Which framework do you > recommend me for creating such a Interface? https://plot.ly/python/ -- https://mail.python.org/mailman/listinfo/python-list

3D visualizations in Python

2019-03-12 Thread Jakub Bista
Hello. I want to do 3D visualization in Python. Which framework do you recommend me for creating such a Interface? -- https://mail.python.org/mailman/listinfo/python-list

Re: Python scope question

2019-03-12 Thread DL Neil
Arup, On 13/03/19 3:38 AM, Arup Rakshit wrote: I have questions how nonlocal and global affecting the variable assignment. Also how each print statement looking up the values for the spam variable. This scope thing in python is very confusing too me still. Can anyone help me to understand th

RE: Multiprocessing vs subprocess

2019-03-12 Thread Schachner, Joseph
Re: " My understanding (so far) is that the tradeoff of using multiprocessing is that my manager script can not exit until all the work processes it starts finish. If one of the worker scripts locks up, this could be problematic. Is there a way to use multiprocessing where processes are launched

Re: Convert Windows paths to Linux style paths

2019-03-12 Thread Paul Moore
On Tue, 12 Mar 2019 at 14:54, Malcolm Greene wrote: > > Looking for best practice technique for converting Windows style paths to > Linux paths. Is there an os function or pathlib method that I'm missing or is > it some combination of replacing Windows path separators with Linux path > separato

Re: Convert Windows paths to Linux style paths

2019-03-12 Thread Bill Campbell
On Tue, Mar 12, 2019, Malcolm Greene wrote: >Looking for best practice technique for converting Windows style paths to >Linux paths. Is there an os function or pathlib method that I'm missing or >is it some combination of replacing Windows path separators with Linux path >separators plus some othe

Re: Convert Windows paths to Linux style paths

2019-03-12 Thread Thomas Jollans
On 12/03/2019 15.51, Malcolm Greene wrote: > Looking for best practice technique for converting Windows style paths to > Linux paths. Is there an os function or pathlib method that I'm missing or is > it some combination of replacing Windows path separators with Linux path > separators plus some

Re: Multiprocessing vs subprocess to run Python scripts in parallel

2019-03-12 Thread Chris Angelico
On Wed, Mar 13, 2019 at 2:01 AM Malcolm Greene wrote: > > Use case: I have a Python manager script that monitors several conditions > (not just time based schedules) that needs to launch Python worker scripts to > respond to the conditions it detects. Several of these worker scripts may end > u

Multiprocessing vs subprocess to run Python scripts in parallel

2019-03-12 Thread Malcolm Greene
Use case: I have a Python manager script that monitors several conditions (not just time based schedules) that needs to launch Python worker scripts to respond to the conditions it detects. Several of these worker scripts may end up running in parallel. There are no dependencies between individu

0x80070005 - acess denied when installing Python

2019-03-12 Thread Louis Aucamp
Goodday to all Members I need help with an installation problem. The background is as follows: I used PyScripter and Python 3.7 for learning python. I am taking a course on Edx "introduction to data science" and one of the requirements is that you install Anaconda. I have had bad experiences with a

Re: "use strict"

2019-03-12 Thread Michael Torrie
On 03/11/2019 01:00 PM, Abdur-Rahmaan Janhangeer wrote: > the problem was that i was reviewing the code, since everything worked (no > errors but wrong output for sure) it took sometimes to find that var. it > was like someone telling me there is fish in that lake and i was throwing > my line tryin

Convert Windows paths to Linux style paths

2019-03-12 Thread Malcolm Greene
Looking for best practice technique for converting Windows style paths to Linux paths. Is there an os function or pathlib method that I'm missing or is it some combination of replacing Windows path separators with Linux path separators plus some other platform specific logic? Thank you, Malcolm

Re: Python scope question

2019-03-12 Thread Grant Edwards
On 2019-03-12, Arup Rakshit wrote: > I have questions how nonlocal and global affecting the variable > assignment. Also how each print statement looking up the values for > the spam variable. This scope thing in python is very confusing too > me still. Can anyone help me to understand this code w

Python scope question

2019-03-12 Thread Arup Rakshit
I have questions how nonlocal and global affecting the variable assignment. Also how each print statement looking up the values for the spam variable. This scope thing in python is very confusing too me still. Can anyone help me to understand this code w.r.t to scope in Python? def scope_test()

Re: System Beep?

2019-03-12 Thread Chris Angelico
On Wed, Mar 13, 2019 at 12:16 AM wrote: > > On Saturday, March 9, 2019 at 12:53:35 AM UTC-5, Terry Reedy wrote: > > On 3/8/2019 1:13 PM, Steve wrote: > > > How can I cause a system beep using code? > > > > >>> import winsound as ws > > >>> ws.Beep(500, 1000) > > > > and > > > > >>> from tkinter

Re: "Post install setup does not work as expected with pip install"

2019-03-12 Thread Peter Otten
Saba Kauser wrote: > Hello, > > I have a post install class that looks like this: > if('darwin' in sys.platform): > class PostInstall(install): > """ Post installation - run install_name_tool on Darwin """ > def run(self): > clipath = os.getenv('IBM_DB_HOME', '@loa

Re: System Beep?

2019-03-12 Thread ssmitch
On Saturday, March 9, 2019 at 12:53:35 AM UTC-5, Terry Reedy wrote: > On 3/8/2019 1:13 PM, Steve wrote: > > How can I cause a system beep using code? > > >>> import winsound as ws > >>> ws.Beep(500, 1000) > > and > > >>> from tkinter import Tk > >>> root = Tk() > >>> root.bell() > > work f

Re: "use strict"

2019-03-12 Thread Rhodri James
[[Replacing snipped context:]] > = Abdur-Rahmaan, no indent is me. On 12/03/2019 11:32, Abdur-Rahmaan Janhangeer wrote: > no i mean > > # *-* use strict *-* Ugh. > program > typovar = x # line y > > ... > > > Traceback: > on the fly var at line y Yes, but how is the program supposed

Re: "use strict"

2019-03-12 Thread Rhodri James
On 12/03/2019 11:41, Abdur-Rahmaan Janhangeer wrote: i also proposed # -*- explicit -*- To expand on my previous "ugh", I don't like hiding major run-time changes in cryptic comments. Behaviour like this should be very explicit in the way that a comment isn't, and shouldn't be so easily the

"Post install setup does not work as expected with pip install"

2019-03-12 Thread Saba Kauser
Hello, I have a post install class that looks like this: if('darwin' in sys.platform): class PostInstall(install): """ Post installation - run install_name_tool on Darwin """ def run(self): clipath = os.getenv('IBM_DB_HOME', '@loader_path/clidriver') pri

Re: "use strict"

2019-03-12 Thread Abdur-Rahmaan Janhangeer
ok, writing a pep-like document to explain all at once. sorry for eyes-hurting and brain-hunting. Abdur-Rahmaan Janhangeer http://www.pythonmembers.club | https://github.com/Abdur-rahmaanJ Mauritius -- https://mail.python.org/mailman/listinfo/python-list

Re: "use strict"

2019-03-12 Thread Chris Angelico
On Tue, Mar 12, 2019 at 11:18 PM Abdur-Rahmaan Janhangeer wrote: > > excuses. > > have you used Js? well a bit like that in py. Yes, I have used JS, and in fact it's a critical part of my day job. But JS has a big difference in that you *declare* variables. As Rhodri says, asking for mandatory va

Re: "use strict"

2019-03-12 Thread Abdur-Rahmaan Janhangeer
excuses. have you used Js? well a bit like that in py. not necessarily unused as currently as it is, you can use the real one many times, the typo one many times. it's not an error but it's not what you expect. a linter basically parses the text, proposing to catch that without linter. the root

Re: "use strict"

2019-03-12 Thread Chris Angelico
On Tue, Mar 12, 2019 at 11:02 PM Abdur-Rahmaan Janhangeer wrote: > > by keeping a list /a record of those variables beforehand and knowing that no > new assignments in loops or such blocks of code. > Please, quote posts with proper context. Your posts are all context-free, which is great for a g

Re: "use strict"

2019-03-12 Thread Abdur-Rahmaan Janhangeer
by keeping a list /a record of those variables beforehand and knowing that no new assignments in loops or such blocks of code. Abdur-Rahmaan Janhangeer http://www.pythonmembers.club | https://github.com/Abdur-rahmaanJ Mauritius -- https://mail.python.org/mailman/listinfo/python-list

Re: "use strict"

2019-03-12 Thread Abdur-Rahmaan Janhangeer
by some special symbols before the variable name like _that some code: _tht ^ Traceback: ... Abdur-Rahmaan Janhangeer http://www.pythonmembers.club | https://github.com/Abdur-rahmaanJ Mauritius -- https://mail.python.org/mailman/listinfo/python-list

Re: "use strict"

2019-03-12 Thread Chris Angelico
On Tue, Mar 12, 2019 at 10:58 PM Abdur-Rahmaan Janhangeer wrote: > > by some special symbols before the variable name > > like > > _that > > some code: > _tht > I don't understand. How is Python to know that "_that" is correct but "_tht" is not? ChrisA -- https://mail.python.org/mailman/li

Re: "use strict"

2019-03-12 Thread Chris Angelico
On Tue, Mar 12, 2019 at 10:43 PM Abdur-Rahmaan Janhangeer wrote: > > no just the var you want to track maybe > > _var > > or something like that, i want to solve that problem and this is just a > proposal > How do you specify which variables should be tracked? What defines this? Be completely cle

Re: "use strict"

2019-03-12 Thread Abdur-Rahmaan Janhangeer
i also proposed # -*- explicit -*- above Abdur-Rahmaan Janhangeer http://www.pythonmembers.club | https://github.com/Abdur-rahmaanJ Mauritius -- https://mail.python.org/mailman/listinfo/python-list

Re: "use strict"

2019-03-12 Thread Abdur-Rahmaan Janhangeer
no just the var you want to track maybe _var or something like that, i want to solve that problem and this is just a proposal Abdur-Rahmaan Janhangeer http://www.pythonmembers.club | https://github.com/Abdur-rahmaanJ Mauritius -- https://mail.python.org/mailman/listinfo/python-list

Re: "use strict"

2019-03-12 Thread Rhodri James
On 12/03/2019 11:32, Abdur-Rahmaan Janhangeer wrote: no i mean # *-* use strict *-* Ugh. program typovar = x # line y ... Traceback: on the fly var at line y Yes, but how is the program supposed to know that typovar is a typo? Are you proposing mandatory declarations for al

Re: "use strict"

2019-03-12 Thread Abdur-Rahmaan Janhangeer
no i mean # *-* use strict *-* program typovar = x # line y ... Traceback: on the fly var at line y Abdur-Rahmaan Janhangeer http://www.pythonmembers.club | https://github.com/Abdur-rahmaanJ Mauritius -- https://mail.python.org/mailman/listinfo/python-list

Re: "use strict"

2019-03-12 Thread Rhodri James
On 11/03/2019 19:08, Abdur-Rahmaan Janhangeer wrote: proposing a special python syntax for it, like if flag set, it halts execution. not relying on external tools like linters. Do you mean on the command line, like "python --lint-me-baby myprog.py"? I could live with that, though I'd hate to

Re: Converting hex data to image

2019-03-12 Thread dimplemathew . 17
On Tuesday, March 12, 2019 at 2:53:49 PM UTC+5:30, Peter Otten wrote: > dimplemathew...@gmail.com wrote: > > >> Save the image to a file (in binary mode!) and then try to open it with > >> an image viewer. The data may be corrupted. > > > > When i tried doing that it says Invalid Image... > > So

Re: Converting hex data to image

2019-03-12 Thread Peter Otten
dimplemathew...@gmail.com wrote: >> Save the image to a file (in binary mode!) and then try to open it with >> an image viewer. The data may be corrupted. > > When i tried doing that it says Invalid Image... So it looks like the problem occurs somewhere before you are decoding the image with th

Re: Converting hex data to image

2019-03-12 Thread dimplemathew . 17
On Tuesday, March 12, 2019 at 2:09:06 PM UTC+5:30, Peter Otten wrote: > dimplemathew...@gmail.com wrote: > > > On Monday, March 11, 2019 at 4:32:48 PM UTC+5:30, Peter Otten wrote: > >> dimplemathew...@gmail.com wrote: > >> > >> > Hi i have a similar challenge where i need to store the thumbnailPh

Re: Converting hex data to image

2019-03-12 Thread Peter Otten
dimplemathew...@gmail.com wrote: > On Monday, March 11, 2019 at 4:32:48 PM UTC+5:30, Peter Otten wrote: >> dimplemathew...@gmail.com wrote: >> >> > Hi i have a similar challenge where i need to store the thumbnailPhoto >> > attribute to my local db and display the image every-time user logs in. >