On Fri, Sep 15, 2023 at 6:53 AM scruel tao via Python-list <
python-list@python.org> wrote:
> ```python
> >>> class A:
> ... def __init__(self):
> ... pass
> ...
> >>> A.__init__
>
> >>> a = A()
> >>> a.__init__
> >
&
On 15/09/2023 11:49, scruel tao via Python-list wrote:
> ```python
>>>> class A:
> ... def __init__(self):
> ... pass
> On many books and even the official documents, it seems that
> many authors prefer to call `__init__` as a "method" rather
>
.
--
https://mail.python.org/mailman/listinfo/python-list
Am Sat, Sep 16, 2023 at 02:17:19PM +1200 schrieb Rimu Atkinson via Python-list:
> Everyone uses virtual environments.
Umm, like, no.
Karsten
--
GPG 40BE 5B0E C98E 1713 AFA6 5BC0 3BEA AC80 7D4F C89B
--
https://mail.python.org/mailman/listinfo/python-list
may have
trouble duplicating the results with a somewhat different setup.
-Original Message-
From: Python-list On
Behalf Of Albert-Jan Roskam via Python-list
Sent: Sunday, September 17, 2023 5:02 AM
To: Peter J. Holzer
Cc: python-list@python.org
Subject: Re: Postgresql equivalent of
On 9/17/2023 11:48 AM, AVI GROSS via Python-list wrote:
Timing things that are fairly simple is hard enough to do repeatedly, but when
it involves access to slower media and especially to network connections to
servers, the number of things that can change are enormous. There are all kinds
of
On 9/17/2023 5:01 AM, Albert-Jan Roskam via Python-list wrote:
On Sep 15, 2023 19:45, "Peter J. Holzer via Python-list"
wrote:
On 2023-09-15 17:42:06 +0200, Albert-Jan Roskam via Python-list wrote:
> This is more related to Postgresql than to Python, I
might need to be larger so clipped image is right size)
options.initWidth = (options.clipwidth / options.scale)
options.initHeight = (options.clipheight / options.scale)
if options.width>options.initWidth:
options.initWidth = options.width
if options.height>options.initHeight:
options.initHeight = options.height
app = AppKit.NSApplication.sharedApplication()
# create an app delegate
delegate = AppDelegate.alloc().init()
AppKit.NSApp().setDelegate_(delegate)
# create a window
rect = Foundation.NSMakeRect(0,0,100,100)
win = AppKit.NSWindow.alloc()
win.initWithContentRect_styleMask_backing_defer_ (rect,
AppKit.NSBorderlessWindowMask, 2, 0)
if options.debug:
win.orderFrontRegardless()
# create a webview object
webview = WebKit.WebView.alloc()
webview.initWithFrame_(rect)
# turn off scrolling so the content is actually x wide and not x-15
webview.mainFrame().frameView().setAllowsScrolling_(objc.NO)
webview.setPreferencesIdentifier_('webkit2png')
webview.preferences().setLoadsImagesAutomatically_(not options.noimages)
# add the webview to the window
win.setContentView_(webview)
# create a LoadDelegate
loaddelegate = WebkitLoad.alloc().init()
loaddelegate.options = options
loaddelegate.urls = args
webview.setFrameLoadDelegate_(loaddelegate)
app.run()
if __name__ == '__main__' : main()
Best,
James
--
https://mail.python.org/mailman/listinfo/python-list
? I do plan to use threads and locks.
3. Does this seem widely useful enough to be worth trying to get into Python
itself? It would be nice if this specific behavior, which probably has even
more nuances than I already am aware of, were safely achievable out of the
box.
Best,
Antonio
--
https://mail.python.org/mailman/listinfo/python-list
erstand if you try it for yourself. Google has
many excellent resources, here is one
https://www.freecodecamp.org/news/how-to-setup-virtual-environments-in-python/
Best of luck :)
R
--
https://mail.python.org/mailman/listinfo/python-list
ypi.org/project/quart/
How well does gevent monkey-patch into a Flask app?
A penny for your thoughts
Thanks!
R
--
https://mail.python.org/mailman/listinfo/python-list
On Mon, 18 Sept 2023 at 13:45, Rimu Atkinson via Python-list
wrote:
>
> Hi all,
>
> I'm writing a fediverse server app, similar to kbin https://kbin.pub/en
> and lemmy https://join-lemmy.org/. It's like reddit except anyone can
> run a server in the same way email wor
On 9/16/2023 7:57 PM, Rimu Atkinson via Python-list wrote:
It is nothing bad about using virtual environments but also not about
not using them. In my own work I haven't see a use case where I needed
them. And I expect that some day I'll encounter a use case for it. This
here is not
On Mon, 18 Sept 2023 at 13:49, anthony.flury via Python-list
wrote:
>
>
>
> To me __init__ is a method, but that is implemented internally as
> function associated to a class
>
What is a method, if it is not a function associated with a class?
ChrisA
--
https://mail.python.or
ll it, the "bound method" knows that t is associated
with `a` and puts that in as the first argument (usually named `self`).
Cheers,
Cameron Simpson
--
https://mail.python.org/mailman/listinfo/python-list
Op 16/09/2023 om 10:17 schreef Meowxiik via Python-list:
Hello,
For the third time I am trying to work with `PYTHONWARNINGS` filter,
and for the third time I am having a terrible time. I'd like to seek
your assistance, I have a few questions:
**Question 1:** Does the environment var
Op 15/09/2023 om 15:05 schreef anthony.flury via Python-list:
Like all of the other methods you shouldn't ever need to
call them directly : these are called dunder methods and represent
functions and features which are called by other operators.
The only recommended way to c
let's still remember:
All methods are functions, but not every function is a method.
Thanks again for helping, you guys are really nice!
--
https://mail.python.org/mailman/listinfo/python-list
On 9/18/23 02:16, Peter J. Holzer via Python-list wrote:
On 2023-09-15 14:15:23 +, c.buhtz--- via Python-list wrote:
I tried to install it via "pipx install -e .[develop]". It's pyproject.toml
has a bug: A missing dependency "dateutil". But "dateutil" is
On 9/18/23 12:56, c.buhtz--- via Python-list wrote:
On 2023-09-18 10:16 "Peter J. Holzer via Python-list"
wrote:
On 2023-09-15 14:15:23 +, c.buhtz--- via Python-list wrote:
I tried to install it via "pipx install -e .[develop]". It's
pyproject.toml has a
On 9/18/2023 2:56 PM, c.buhtz--- via Python-list wrote:
On 2023-09-18 10:16 "Peter J. Holzer via Python-list"
wrote:
On 2023-09-15 14:15:23 +, c.buhtz--- via Python-list wrote:
I tried to install it via "pipx install -e .[develop]". It's
pyproject.toml has a
andidate-released/33105#we-hope-you-enjoy-the-new-releases-9>We
hope you enjoy the new releases!
Thanks to all of the many volunteers who help make Python Development and
these releases possible! Please consider supporting our efforts by
volunteering yourself or through organization contributions to the Python
Software Foundation <https://www.python.org/psf-landing/>.
Your release team,
Thomas Wouters
Ned Deily
Steve Dower
Łukasz Langa
--
Thomas Wouters
--
https://mail.python.org/mailman/listinfo/python-list
On 23/09/23 4:51 am, Stefan Ram wrote:
[]=[]
(Executes with no error.)
#
[]=[]
( 1 )
#\_/#
(Executes with no error.)
--
Greg
--
https://mail.python.org/mailman/listinfo/python-list
hat I tried generator expressions both inside parentheses and not,
without success.
--
Jonathan Gossage
--
https://mail.python.org/mailman/listinfo/python-list
y = test1(*[a for a in st])
y = test1(*st)
Maybe any of these would be ok for you?
Regards,
DG
> On 25 Sep 2023, at 17:15, Jonathan Gossage via Python-list
> wrote:
>
> I am having a problem using generator expressions to supply the arguments
> for a class instance init
On 9/25/2023 10:15 AM, Jonathan Gossage via Python-list wrote:
I am having a problem using generator expressions to supply the arguments
for a class instance initialization. The following example shows the
problem:
class test1(object):
def __init__(self, a, b):
self.name = a
implement business ideas - efficiently in both time and costs :::
eGenix.com Software, Skills and Services GmbH Pastor-Loeh-Str.48
D-40764 Langenfeld, Germany. CEO Dipl.-Math. Marc-Andre Lemburg
Registered at Amtsgericht Duesseldorf: HRB 46611
https://www.egenix.com/company/contact/
https://www.malemburg.com/
--
https://mail.python.org/mailman/listinfo/python-list
Mon, Sep 25, 2023 at 11:15 AM Thomas Passin via Python-list <
python-list@python.org> wrote:
> On 9/25/2023 10:15 AM, Jonathan Gossage via Python-list wrote:
> > I am having a problem using generator expressions to supply the arguments
> > for a class instance initialization.
On Tue, 26 Sept 2023 at 01:39, Jonathan Gossage via Python-list
wrote:
>
> Many thanks, all. It turned out that my problem was not fully understanding
> the use and power of the unpack operator *. Using it to activate my
> generator made things start to work. I changed the line whe
... :-)
bye,
--
piergiorgio
--
https://mail.python.org/mailman/listinfo/python-list
On Tue, 26 Sept 2023 at 02:52, Piergiorgio Sartor via Python-list
wrote:
>
> On 23/09/2023 09.41, Stefan Ram wrote:
> > r...@zedat.fu-berlin.de (Stefan Ram) writes:
> >> []=[]
> >
> >I was watching a video of a David Beazley talk "Python
> >Conc
It's not a bug, it's an empty unpacking.
Just as you can write
[A,B] = [1,2] # Sets A to 1, B to 2
Best wishes
Rob Cliffe
On 23/09/2023 04:41, Greg Ewing via Python-list wrote:
On 23/09/23 4:51 am, Stefan Ram wrote:
[]=[]
(Executes with no error.)
#
[]=[]
( 1 )
#\_/#
didn’t add it to the
path correctly, any help is greatly appreciated.
Very Respectfully,
Pau Vilchez
--
https://mail.python.org/mailman/listinfo/python-list
ou received this message by mistake, please reply to this message and
follow with its deletion, so that we can ensure such a mistake does not
occur in the future.
--
https://mail.python.org/mailman/listinfo/python-list
On 27/09/23 3:30 pm, Chris Roy-Smith wrote:
surely running a 64 bit version of python in a 23mbit version of windows
will cause significant problems!
23 millibits? I don't think you'd be able to run much at all
with that few bits! :-)
--
Greg
--
https://mail.python.org/mailman/listi
" That suggests to me that it should try to acquire the GIL again
and wait until it can (although possibly also that it's not an expected use
and Python thread states are expected to be more 1:1 with C threads).
On Wed, Sep 27, 2023 at 3:53 AM MRAB via Python-list
wrote:
> On 2023-09
/bin/python3 -c'import sys;print(sys.version)'
3.12.0rc3 (main, Sep 27 2023, 09:35:10) [GCC 13.2.1 20230801]
user@host:~/devel
$
--
Robin Becker
--
https://mail.python.org/mailman/listinfo/python-list
On 9/25/23 12:10, Pau Vilchez via Python-list wrote:
Hello Python Team,
I am somehow unable to completely remove Python 3.10.9 (64 Bit) from my
computer. I have tried deleting the Appdata folder then repairing and then
uninstalling but it still persists in the remove/add program function in
On 9/27/2023 7:17 AM, Zuri Shaddai Kuchipudi via Python-list wrote:
hello everyone this the error that im getting while trying to install and
upgrade pip on what is the solution for it?
C:\repository\pst-utils-pc-davinci-simulator>pip install
You are using pip version 7.0.1, however vers
On Thu, 28 Sept 2023 at 01:16, Zuri Shaddai Kuchipudi via Python-list
wrote:
>
> hello everyone this the error that im getting while trying to install and
> upgrade pip on what is the solution for it?
>
The solution is to upgrade to Python 3.
https://pip.pypa.io/en/latest/develop
se it still relies on the system Python interpreter.
Not sure what this really means, nor how to get python to be in my venv.
--
https://mail.python.org/mailman/listinfo/python-list
On 9/27/23 05:17, Zuri Shaddai Kuchipudi via Python-list wrote:
hello everyone this the error that im getting while trying to install and
upgrade pip on what is the solution for it?
C:\repository\pst-utils-pc-davinci-simulator>pip install
You are using pip version 7.0.1, however version 23.
rrymartell larrymartell 16 Sep 27 11:21 python3 ->
> /usr/bin/python3
...
> Not sure what this really means, nor how to get python to be in my venv.
WHy do you want python to be "in your venv"?
--
https://mail.python.org/mailman/listinfo/python-list
On Wed, Sep 27, 2023 at 12:42 PM Jon Ribbens via Python-list
wrote:
>
> On 2023-09-27, Larry Martell wrote:
> > I was under the impression that in a venv the python used would be in
> > the venv's bin dir. But in my venvs I see this in the bin dirs:
> >
> > lrw
Hi Larry,
You could just create venv with option '—copies'
For example:
python -m venv -–copies .venv
From: Larry Martell via Python-list
Sent: 27 сентября 2023 г. 22:48
To: Jon Ribbens
Cc: python-list@python.org
Subject: Re: path to python in venv
On Wed, Sep 27, 2023 at 12:42 PM J
On Wed, Sep 27, 2023 at 12:53 PM Niktar Lirik wrote:
>
> Hi Larry,
>
> You could just create venv with option '—copies'
>
>
>
> For example:
>
> python -m venv -–copies .venv
Thanks! That is just what I was looking for.
> From: Larry Martell via Py
On 9/27/23 13:46, Larry Martell via Python-list wrote:
On Wed, Sep 27, 2023 at 12:42 PM Jon Ribbens via Python-list
wrote:
On 2023-09-27, Larry Martell wrote:
I was under the impression that in a venv the python used would be in
the venv's bin dir. But in my venvs I see this in the bin
On 2023-09-27, Larry Martell wrote:
> On Wed, Sep 27, 2023 at 12:42 PM Jon Ribbens via Python-list
> wrote:
>> On 2023-09-27, Larry Martell wrote:
>> > I was under the impression that in a venv the python used would be in
>> > the venv's bin dir. But in
On 9/27/23 14:02, Zuri Shaddai Kuchipudi via Python-list wrote:
Why it's trying to select an incompatible version when you ask to
upgrade is not something I'd like to speculate on, for me personally
that's a surprise. Maybe something else you did before?
Also make sure you'
On Thu, 28 Sept 2023 at 07:27, Mats Wichmann via Python-list
wrote:
>
> Upgrading to Python 3 is the best answer... except when it isn't. If
> you want to convert a small project it's usually not too hard; and using
> a conversion tool can work well.
Just remember that P
On 9/27/2023 2:53 PM, Larry Martell via Python-list wrote:
I was under the impression that in a venv the python used would be in
the venv's bin dir. But in my venvs I see this in the bin dirs:
lrwxrwxrwx 1 larrymartell larrymartell7 Sep 27 11:21 python -> python3
lrwxrwxrwx 1 larr
On 28/09/2023 10:05, Barry via Python-list wrote:
So this must be the source of my confusion
user@host:~
$ python312 -mvenv --help
..
--upgrade Upgrade the environment directory to use this version
of Python, assuming Python has been upgraded in-place
Loris
--
This signature is currently under constuction.
--
https://mail.python.org/mailman/listinfo/python-list
On 9/28/2023 9:23 AM, Zuri Shaddai Kuchipudi via Python-list wrote:
On Wednesday, 27 September 2023 at 23:33:02 UTC+2, Chris Angelico wrote:
On Thu, 28 Sept 2023 at 07:27, Mats Wichmann via Python-list
wrote:
Upgrading to Python 3 is the best answer... except when it isn't. If
you wa
, '=', value)
a = A()
a.x = 1
print('a.x =', a.x)
--
Greg
--
https://mail.python.org/mailman/listinfo/python-list
ailingSingleton' object has no attribute
'special_value'
Where's the error in my thinking (or code) ?
Thanks,
Karsten
--
GPG 40BE 5B0E C98E 1713 AFA6 5BC0 3BEA AC80 7D4F C89B
--
https://mail.python.org/mailman/listinfo/python-list
On 9/30/23 13:00, Karsten Hilbert via Python-list wrote:
A type annotation isn't supposed to change what code does,
or so I thought:
#
class Borg:
_instances:dict = {}
def __new__(cls, *args, **
Am Sun, Oct 01, 2023 at 09:04:05AM +1300 schrieb dn via Python-list:
> >class WorkingSingleton(Borg):
> >
> > def __init__(self):
> > print(self.__class__.__name__, ':')
> > try:
> > self.already_init
intent: a class where each instance is aware of every other
> instance - yet
> the word "Singleton" implies there's only one (cf a dict full of ...)?
The latter.
Regards,
Karsten
--
GPG 40BE 5B0E C98E 1713 AFA6 5BC0 3BEA AC80 7D4F C89B
--
https://mail.python.org/mailman/listinfo/python-list
On Sun, 1 Oct 2023 at 22:58, Karsten Hilbert via Python-list
wrote:
>
> Sorry for having conflated the core of the matter with all
> the Borg shenanigans, that's where I found the problem in my
> real code, so there :-)
g (set to True
when you initialize), and look it up with getattr() with a default value
of False.
--
Richard Damon
--
https://mail.python.org/mailman/listinfo/python-list
On Mon, 2 Oct 2023 at 09:10, Barry via Python-list
wrote:
>
>
>
> > On 1 Oct 2023, at 19:36, Richard Damon via Python-list
> > wrote:
> >
> > Perhaps a better method would be rather than just using the name and
> > catching the exception, use a rea
= bytes(qs_array[offset])
struct.pack_into(buf,"https://mail.python.org/mailman/listinfo/python-list
our efforts by
volunteering yourself or through organization contributions to the Python
Software Foundation <https://www.python.org/psf-landing/>.
Your release team,
Thomas Wouters
Ned Deily
Steve Dower
Łukasz Langa
--
Thomas Wouters
--
https://mail.python.org/mailman/listinfo/python-list
the extra overhead, and it's more
difficult yet if I'm using the Python integer output in a C program. Your
solution solves those problems.
Oct 2, 2023, 17:11 by python-list@python.org:
> On 2023-10-01 23:04, Jen Kris via Python-list wrote:
>
>>
>> Iwant to write
ct.pack_into("https://mail.python.org/mailman/listinfo/python-list
offset` is `0`, `1`, `2`, ...
> but it should be `0 *8`, `1 * 8`, `2 * 8`, ...
>
> * The `vi` should be something which fits with the format:
> integers in your case. But you pass bytes.
>
> Try `struct.pack_into(" instead of your loop.
>
>
> Next time: carefully read the documentation and think carefully
> about the types involved.
>
--
https://mail.python.org/mailman/listinfo/python-list
work I have done:
buf = bytes((len(qs_array)) * 8)
for offset in range(len(qs_array)):
item_to_write = bytes(qs_array[offset])
struct.pack_into(buf, "https://mail.python.org/mailman/listinfo/python-list
Jen Kris via Python-list schreef op 2/10/2023 om 17:06:
My previous message just went up -- sorry for the mangled formatting. Here it
is properly formatted:
I want to write a list of 64-bit integers to a binary file. Every example I
have seen in my research converts it to .txt, but I want
On Wed, 4 Oct 2023 at 15:27, dn via Python-list wrote:
> - should the class have been called either;
>
> class SomethingSingleton():
>
> or a Singleton() class defined, which is then sub-classed, ie
>
> class Something( Singleton ):
>
> in order to better com
alled, and returns that instance subsequently. The problem then
doesn't arise.
--
Greg
--
https://mail.python.org/mailman/listinfo/python-list
On Wed, 4 Oct 2023 at 17:47, Greg Ewing via Python-list
wrote:
>
> On 4/10/23 5:25 pm, dn wrote:
> > The first question when dealing with the Singleton Pattern is what to do
> > when more than one instantiation is attempted
>
> My preferred way of handling singletons is
reinstall it because I didn’t add it to
the path correctly, any help is greatly appreciated.
Very Respectfully,
Pau Vilchez
--
https://mail.python.org/mailman/listinfo/python-list
On 25.9.2023 19.58, Pau Vilchez via Python-list wrote:
Hello Python Team,
I am somehow unable to completely remove Python 3.10.9 (64 Bit) from my
computer. I have tried deleting the Appdata folder then repairing and then
uninstalling but it still persists in the remove
Am Wed, Oct 04, 2023 at 05:25:04PM +1300 schrieb dn via Python-list:
> The first question when dealing with the Singleton Pattern is what to do when
> more than
> one instantiation is attempted:
>
> - silently return the first instance
This, in my case.
> and so, returnin
On 10/4/23 13:08, Roland Müller via Python-list wrote:
On 25.9.2023 19.58, Pau Vilchez via Python-list wrote:
Hello Python Team,
I am somehow unable to completely remove Python 3.10.9 (64 Bit)
from my
computer. I have tried deleting the Appdata folder then repairing
and then
.
--
https://mail.python.org/mailman/listinfo/python-list
mya.G via Python-list"
Date: 10/10/23 04:43 (GMT+10:00) To:
python-list@python.org Subject: regarding installation of python version
The problem is how many times I have uninstalled the python version but
always it is showing the same version after the installation of new
v
callback, 1)
--
Chris Green
·
--
https://mail.python.org/mailman/listinfo/python-list
On Fri, 13 Oct 2023 at 01:48, Chris Green via Python-list
wrote:
>
> In the following code is the event polled by the Python process
> running the code or is there something cleverer going on such that
> Python sees an interrupt when the input goes high (or low)?
>
This isn'
Chris Angelico wrote:
> On Fri, 13 Oct 2023 at 01:48, Chris Green via Python-list
> wrote:
> >
> > In the following code is the event polled by the Python process
> > running the code or is there something cleverer going on such that
> > Python sees an interrupt wh
ation contributions to the Python
Software Foundation.
Regards from lovely Czechia,
Your release team,
Thomas Wouters
Ned Deily
Steve Dower
Łukasz Langa
--
Thomas Wouters
--
https://mail.python.org/mailman/listinfo/python-list
te out the full object
path every time.
--
https://mail.python.org/mailman/listinfo/python-list
On Tue, 17 Oct 2023 at 12:55, Bongo Ferno via Python-list
wrote:
>
> Where I can ask python developers for a new feature?
>
> This feature would allow us to create short aliases for long object paths,
> similar to the with statement. This would make code more readable and
chael*
--
https://mail.python.org/mailman/listinfo/python-list
possible with
Python and with that 'simple_websocket_server' package used?
Thanks for any hints (or search keywords, or code samples)!
Janis
[*] https://pypi.org/project/simple-websocket-server/
--
https://mail.python.org/mailman/listinfo/python-list
tional[str] = None
foo: Default[str, "bar"] would be equivalent to foo: Optional[str] = "bar"
or something like that. Basically, any way to avoid writing `= None` over and
over again.
--
https://mail.python.org/mailman/listinfo/python-list
On Thu, 19 Oct 2023 at 10:07, Janis Papanagnou via Python-list
wrote:
>
> I am pondering about writing a client/server software with
> websockets as communication protocol. The clients will run
> in browser as Javascript programs and the server may be in
> any (any sensible) progr
On Thu, 19 Oct 2023 at 10:11, Matthew Carruth via Python-list
wrote:
>
> We have the `Optional[T]` type as a short-hand for Union[T | None] and
> telling us that said argument may not be present.
>
> However, I find that a majority of the time, we also want to set a default
>
and I also appreciate your offer
and will probably come back soon with a question... - Thanks again!
Janis
--
https://mail.python.org/mailman/listinfo/python-list
(valid) code ...
In Python a distinction can be made between "runnable" and "valid" :-D
Karsten
--
https://mail.python.org/mailman/listinfo/python-list
hat inspects the annotations at runtime and makes whatever changes it
likes, but that's part of what I described as "shenanigans".
ChrisA
--
https://mail.python.org/mailman/listinfo/python-list
ttributeError: print('first instantiation'); self.initialized = True
and then changing that to
>>> try: self.initialized:bool
Karsten
--
https://mail.python.org/mailman/listinfo/python-list
zed:bool
But that's not equivalent code. You might just as well say that the
ellipsis here suddenly changes the code:
self.initialized
self.initialized = ...
These are completely different, and they behave differently. Both are
valid, but they mean different things.
ChrisA
--
https://mail.python.org/mailman/listinfo/python-list
> > >>> True
> >
> > and then changing that to
> >
> > >>> try: self.initialized:bool
>
> But that's not equivalent code.
I learned as much (RHS vs LHS).
But it did not _intuitively_ resonate with the sentiment
"type annotation does not change the running of code".
Karsten
--
https://mail.python.org/mailman/listinfo/python-list
ivalent code.
>
> I learned as much (RHS vs LHS).
>
> But it did not _intuitively_ resonate with the sentiment
> "type annotation does not change the running of code".
Unfortunately, that simply means that your intuition was wrong. It
doesn't change my prior statement.
ChrisA
--
https://mail.python.org/mailman/listinfo/python-list
> You can actually just do that with simple assignment!
>
> short_view = my_object.stuff.long_stuff.sub_object
> print(short_view.some_method())
but then have to delete the variable manually
del short_view
--
https://mail.python.org/mailman/listinfo/python-list
need yet another? Yes, you can create one of those ways but what
is the big deal with deleting a variable when no longer used?
Examples might be the "finally" clause or the "with" statement or just
putting the variable in a nested scope.
-Original Message-----
From: Pytho
if "i"
was already used in another place..
--
https://mail.python.org/mailman/listinfo/python-list
io.TextIOWrapper name='/dev/null' mode='r' encoding='UTF-8'>
>>> print(f)
<_io.TextIOWrapper name='/dev/null' mode='r' encoding='UTF-8'>
--
https://mail.python.org/mailman/listinfo/python-list
2101 - 2200 of 5713 matches
Mail list logo