Re: How to make a variable's late binding crosses the module boundary?

2022-08-28 Thread Jach Feng
Richard Damon 在 2022年8月29日 星期一上午10:47:08 [UTC+8] 的信中寫道: > On 8/27/22 7:42 AM, Mark Bourne wrote: > > Jach Feng wrote: > >> I have two files: test.py and test2.py > >> --test.py-- > >> x = 2 > >> def foo(): > >> print(x) > >> foo() > >> > >> x = 3 > >> foo() > >> > >> --test2.py--

Re: How to make a variable's late binding crosses the module boundary?

2022-08-28 Thread Richard Damon
On 8/27/22 7:42 AM, Mark Bourne wrote: Jach Feng wrote: I have two files: test.py and test2.py --test.py-- x = 2 def foo(): print(x) foo() x = 3 foo() --test2.py-- from test import * x = 4 foo() - Run test.py under Winows8.1, I get the expected result: e:\MyDocument>py test.py 2 3

Re: What can I do about this?

2022-08-28 Thread Dennis Lee Bieber
On Sun, 28 Aug 2022 18:40:17 -0400, gene heskett declaimed the following: >Collecting wxPython>=4.1 >   Using cached wxPython-4.2.0.tar.gz (71.0 MB) >   Preparing metadata (setup.py) ... error >   error: subprocess-exited-with-error > >     File

Re: python 3.10 vs breakage

2022-08-28 Thread Dennis Lee Bieber
On Fri, 26 Aug 2022 17:36:39 -0400, gene heskett declaimed the following: > >Bullseye is the current debian-11, buster is last years, bookworm is next. > >Linuxcnc builds just fine on armhf buster, with its python-3.9.4. fails >from 3.10 in bullseye. Pronterface.py can't find wxPython 4.0 or

Re: How to make a variable's late binding crosses the module boundary?

2022-08-28 Thread Jach Feng
Mark Bourne 在 2022年8月27日 星期六晚上7:42:37 [UTC+8] 的信中寫道: > import test > test.x = 4 > test.foo() > > -- > Mark. Yes, you are right. But because of I am using "from test import *" which makes the name "test" disappear in the test2 scope, so this is not work. I solved this problem by moving "x"

Re: How to make a variable's late binding crosses the module boundary?

2022-08-28 Thread Mark Bourne
Jach Feng wrote: I have two files: test.py and test2.py --test.py-- x = 2 def foo(): print(x) foo() x = 3 foo() --test2.py-- from test import * x = 4 foo() - Run test.py under Winows8.1, I get the expected result: e:\MyDocument>py test.py 2 3 But when run test2.py, the result is not

Re: What can I do about this?

2022-08-28 Thread gene heskett
On 8/28/22 19:39, Peter J. Holzer wrote: On 2022-08-28 18:40:17 -0400, gene heskett wrote: Persuant to my claim the py3.10 is busted, here is a sample. This is me, trying to make pronterface, inside a venv: When the package manager version will only run the gui-less "pronsole" but nothing else

Re: What can I do about this?

2022-08-28 Thread gene heskett
On 8/28/22 19:36, Chris Angelico wrote: On Mon, 29 Aug 2022 at 08:41, gene heskett wrote: Greatings all; Persuant to my claim the py3.10 is busted, here is a sample. This is me, trying to make pronterface, inside a venv: When the package manager version will only run the gui-less "pronsole"

Re: What can I do about this?

2022-08-28 Thread Peter J. Holzer
On 2022-08-28 18:40:17 -0400, gene heskett wrote: > Persuant to my claim the py3.10 is busted, here is a sample. This is me, > trying to make > pronterface, inside a venv: When the package manager version will only run > the gui-less "pronsole" > but nothing else from that all python kit runs as

Re: What can I do about this?

2022-08-28 Thread Chris Angelico
On Mon, 29 Aug 2022 at 08:41, gene heskett wrote: > > Greatings all; > > Persuant to my claim the py3.10 is busted, here is a sample. This is me, > trying to make > pronterface, inside a venv: When the package manager version will only > run the gui-less "pronsole" > but nothing else from that

What can I do about this?

2022-08-28 Thread gene heskett
Greatings all; Persuant to my claim the py3.10 is busted, here is a sample. This is me, trying to make pronterface, inside a venv: When the package manager version will only run the gui-less "pronsole" but nothing else from that all python kit runs as it should or at all. From the