Re: About the implementation of del in Python 3

2017-07-06 Thread Marko Rauhamaa
Ian Kelly : > On Thu, Jul 6, 2017 at 9:41 AM, Marko Rauhamaa wrote: >> As a good example of the style I'm looking for, take a look at: >> >>https://docs.oracle.com/javase/specs/jls/se7/html/jls-17.html> > > Java reference types have basically the same

[issue23644] g++ module compile fails with ‘_Atomic’ does not name a type

2017-07-06 Thread STINNER Victor
STINNER Victor added the comment: > ./Include/pyatomic.h:37:5: error: 'atomic_int' does not name a type I don't understand how you got this error. The line 37 of pyatomic.h is only compiled when you build Python itself. At least, since Python 3.5.1 and Python 3.6.0. Did you try to build

Re: Privy: An easy, fast lib to password-protect your data

2017-07-06 Thread Rhodri James
On 06/07/17 17:53, ofekmeis...@gmail.com wrote: Do you better understand what Privy is for now? If so, is there anything in particular you think could be made more clear in the docs? I think the point is that you failed to include any context in your advert. An unadorned link in a post

Re: About the implementation of del in Python 3

2017-07-06 Thread Marko Rauhamaa
Marko Rauhamaa : > Notice that Scheme refers directory to conventional RAM: s/directory/directly/ -- https://mail.python.org/mailman/listinfo/python-list

Re: About the implementation of del in Python 3

2017-07-06 Thread Steve D'Aprano
On Fri, 7 Jul 2017 01:21 am, Marko Rauhamaa wrote: > Steve D'Aprano : > >> On Thu, 6 Jul 2017 07:24 pm, Marko Rauhamaa wrote: >> >>> While talking about addresses might or might not be constructive, let >>> me just point out that there is no outwardly visible

Re: About the implementation of del in Python 3

2017-07-06 Thread Nathan Ernst
In Python, "==" is not a reference equality operator (and I hate Java for their misuse of the operator), so I absolutely disagree with using the Java description to describe Python's "==" operator, primarily because, well, it's wrong. Simple example: With Python 3.5.2 (should hold for any version

[issue30780] IDLE: configdialog - add tests for ConfigDialog GUI.

2017-07-06 Thread Terry J. Reedy
Terry J. Reedy added the comment: PR to fix type in moduleTearDown. -- ___ Python tracker ___ ___

[issue30862] parent logger should also check the level

2017-07-06 Thread Vinay Sajip
Vinay Sajip added the comment: New changeset 0653fba51c03d20fa4381ba0836acd17fd05b04b by Vinay Sajip in branch 'master': bpo-30862: Updated Logger.setLevel documentation. (GH-2604) https://github.com/python/cpython/commit/0653fba51c03d20fa4381ba0836acd17fd05b04b --

[issue30780] IDLE: configdialog - add tests for ConfigDialog GUI.

2017-07-06 Thread Terry J. Reedy
Changes by Terry J. Reedy : -- pull_requests: +2673 ___ Python tracker ___ ___

[issue23644] g++ module compile fails with ‘_Atomic’ does not name a type

2017-07-06 Thread STINNER Victor
STINNER Victor added the comment: See the following commit of bpo-25150: commit 6df29ada02d22c43a8d439a70b820cb1ceacca42 Author: Victor Stinner Date: Fri Sep 18 15:06:34 2015 +0200 Issue #25150: Hide the private _Py_atomic_xxx symbols from the public

Re: About the implementation of del in Python 3

2017-07-06 Thread Marko Rauhamaa
Chris Angelico : > On Fri, Jul 7, 2017 at 1:21 AM, Marko Rauhamaa wrote: >> What I'm looking for is snippets of Python code that illustrate the >> difference. >> >> That's how you can illustrate the difference between the "==" and "is" >> operators: >> >>

Re: About the implementation of del in Python 3

2017-07-06 Thread Chris Angelico
On Fri, Jul 7, 2017 at 3:05 AM, Marko Rauhamaa wrote: > Chris Angelico : > >> On Fri, Jul 7, 2017 at 1:21 AM, Marko Rauhamaa wrote: >>> What I'm looking for is snippets of Python code that illustrate the >>> difference. >>> >>> That's how you

[issue27584] New addition of vSockets to the python socket module

2017-07-06 Thread Cathy Avery
Cathy Avery added the comment: So I revised my code based on the reviews and I passed all the checks ... now what? Thanks, Cathy -- ___ Python tracker

[issue26506] [EASY] hex() documentation: mention "%x" % int

2017-07-06 Thread Mariatta Wijaya
Mariatta Wijaya added the comment: New changeset 67ba4fa467825d6a0c0a21cc54ff1df2ed1b by Mariatta (Manvisha Kodali) in branch 'master': bpo-26506: hex() documentation: mention %x % int (GH-2525) https://github.com/python/cpython/commit/67ba4fa467825d6a0c0a21cc54ff1df2ed1b --

[issue30779] IDLE: configdialog -- factor out Changes class

2017-07-06 Thread Terry J. Reedy
Terry J. Reedy added the comment: I am working on this now. -- ___ Python tracker ___ ___ Python-bugs-list

[issue23644] g++ module compile fails with ‘_Atomic’ does not name a type

2017-07-06 Thread STINNER Victor
STINNER Victor added the comment: Oh, wait, I read your message backward. You said that the fix doesn't work? Hum, how can I reproduce the issue? What is your use case? -- resolution: fixed -> status: closed -> open ___ Python tracker

[issue30862] parent logger should also check the level

2017-07-06 Thread Vinay Sajip
Changes by Vinay Sajip : -- pull_requests: +2672 ___ Python tracker ___ ___

Re: About the implementation of del in Python 3

2017-07-06 Thread Terry Reedy
On 7/6/2017 11:41 AM, Marko Rauhamaa wrote: Chris Angelico : The formal definition is that objects have identities, and that assignment (including function parameters and return values) gives you a reference to the same object. My example didn't contain a single assignment,

Re: About the implementation of del in Python 3

2017-07-06 Thread Terry Reedy
Sorry, finger twitch. Wish there were a minute grace period to recall such mistakes. On 7/6/2017 2:16 PM, Terry Reedy wrote: -- Terry Jan Reedy -- https://mail.python.org/mailman/listinfo/python-list

[issue30532] email.policy.SMTP.fold() mangles long headers

2017-07-06 Thread R. David Murray
R. David Murray added the comment: Thanks, Joel! -- resolution: -> fixed stage: backport needed -> resolved status: open -> closed type: -> behavior ___ Python tracker

[issue30532] email.policy.SMTP.fold() mangles long headers

2017-07-06 Thread R. David Murray
R. David Murray added the comment: New changeset 3bbdf990a2c1b0b303b950058e3177a1bd5f697a by R. David Murray (Joel Hillacre) in branch '3.5': bpo-30532: Fix whitespace folding in certain cases (#2592) https://github.com/python/cpython/commit/3bbdf990a2c1b0b303b950058e3177a1bd5f697a

[issue23644] g++ module compile fails with ‘_Atomic’ does not name a type

2017-07-06 Thread Melroy van den Berg
Melroy van den Berg added the comment: Yea I'm building Python 3.6.1 from source, using gcc and --with-cxx-main=correct/location/to/g++ flag. So the warning message appears during ./configure about that it can't find g++. I didn't try to patch it using the attachments of this issue. Since I

[issue30819] Linking with 'ld -b' fails with 64-bit using Itanium HP compiler

2017-07-06 Thread Robert Boehne
Changes by Robert Boehne : -- nosy: +haypo ___ Python tracker ___ ___ Python-bugs-list

[issue30861] StreamReader does not return reamaing and ready data buffer before raise the Exeption

2017-07-06 Thread pfreixes
pfreixes added the comment: As was said, the assumption here is the data that came to the buffer must be available. For example, the next snippet shows a Redis client that expects the data message plus the RST packet, where the redis-server was configured to accept max N connections, the

[issue30532] email.policy.SMTP.fold() mangles long headers

2017-07-06 Thread R. David Murray
R. David Murray added the comment: New changeset c60d2f5e8609b040ab58c498fde23928fe9dbef5 by R. David Murray (Joel Hillacre) in branch '3.6': bpo-30532: Fix whitespace folding in certain cases (#2591) https://github.com/python/cpython/commit/c60d2f5e8609b040ab58c498fde23928fe9dbef5

Re: About the implementation of del in Python 3

2017-07-06 Thread Chris Angelico
On Fri, Jul 7, 2017 at 7:10 AM, Marko Rauhamaa wrote: > Steve D'Aprano : > >> An address is a concrete location or place, in other words a physical >> position in some space, while identity is the abstract state or >> quality of being identical

[issue30860] Consolidate stateful C globals under a single struct.

2017-07-06 Thread Antoine Pitrou
Antoine Pitrou added the comment: After looking at the PR, I'm a bit skeptical about this. Suddenly a lot of things which are implementation details get moved to the public include files, which makes things more confusing from my POV. I also don't know why all globals should be consolidated

Re: About the implementation of del in Python 3

2017-07-06 Thread Marko Rauhamaa
Steve D'Aprano : > An address is a concrete location or place, in other words a physical > position in some space, while identity is the abstract state or > quality of being identical (sameness), in other words a state of > being. Whether id() returns one such thing

[issue30183] [HPUX] compilation error in pytime.c with cc compiler

2017-07-06 Thread Robert Boehne
Changes by Robert Boehne : -- pull_requests: +2674 ___ Python tracker ___ ___

[issue30861] StreamReader does not return reamaing and ready data buffer before raise the Exeption

2017-07-06 Thread Guido van Rossum
Guido van Rossum added the comment: We seem to have a failure to communicate. I'm sure your example code "works", but you're not showing what's in the data it receives that is important for the app to read (your example just prints it). And surely your app should be robust even if the

[issue23644] g++ module compile fails with ‘_Atomic’ does not name a type

2017-07-06 Thread STINNER Victor
STINNER Victor added the comment: I don't think that CPython can be built by g++. If you consider that it should, please open a new issue since it's a different use case. -- ___ Python tracker

[issue27268] Incorrect error message on float('')

2017-07-06 Thread Wolfgang Maier
Wolfgang Maier added the comment: Could somebody turn this into a PR to move things forward? I guess Nofar mistakenly set resolution to "works for me", but meant "patch works for me"? -- nosy: +wolma ___ Python tracker

About the implementation of del in Python 3

2017-07-06 Thread Dan Wissme
I thought that del L[i] would slide L[i+1:] one place to the left, filling the hole, but : >>> L [0, 10, 20, 30, 40, 50, 60, 70, 80, 90, 100] >>> id(L) 4321967496 >>> id(L[5])# address of 50 ? 4297625504 >>> del L[2] >>> id(L[4]) # new address of 50 ? 4297625504 >>> id(L) 4321967496 So

[issue30863] Rewrite PyUnicode_AsWideChar() and PyUnicode_AsWideCharString()

2017-07-06 Thread Serhiy Storchaka
New submission from Serhiy Storchaka: Since Python 3.3 PyUnicode_AsUnicodeAndSize() is deprecated in favour of PyUnicode_AsWideChar() and PyUnicode_AsWideCharString(). But the latter two are implemented using PyUnicode_AsUnicodeAndSize(). This prevents adding the deprecation compiler warning

Re: About the implementation of del in Python 3

2017-07-06 Thread Chris Angelico
On Thu, Jul 6, 2017 at 5:35 PM, Jussi Piitulainen wrote: > Incidentally, let no one point out that ids are not memory addresses. > It says in the interactive help that they are (Python 3.4.0): > > Help on built-in function id in module builtins: > > id(...) >

Re: About the implementation of del in Python 3

2017-07-06 Thread Terry Reedy
On 7/6/2017 3:08 AM, Dan Wissme wrote: I thought that del L[i] would slide L[i+1:] one place to the left, filling the hole, but : >>> L [0, 10, 20, 30, 40, 50, 60, 70, 80, 90, 100] >>> id(L) 4321967496 >>> id(L[5])# address of 50 ? 4297625504 >>> del L[2] >>> id(L[4]) # new

Re: About the implementation of del in Python 3

2017-07-06 Thread Jussi Piitulainen
Dan Wissme writes: > I thought that del L[i] would slide L[i+1:] one place to the left, > filling the hole, but : > L > [0, 10, 20, 30, 40, 50, 60, 70, 80, 90, 100] id(L) > 4321967496 id(L[5])# address of 50 ? > 4297625504 del L[2] id(L[4]) # new address of 50 ? >

[issue30863] Rewrite PyUnicode_AsWideChar() and PyUnicode_AsWideCharString()

2017-07-06 Thread Serhiy Storchaka
Changes by Serhiy Storchaka : -- pull_requests: +2667 ___ Python tracker ___ ___

[issue30861] StreamReader does not return reamaing and ready data buffer before raise the Exeption

2017-07-06 Thread Dima Tisnek
Dima Tisnek added the comment: My 2c: Pau's concern seems valid, in a sense that stream should work like TCP. That's what most users would assume -- read out data until the end, only then you can see what the actual error was (socket closed, or timeout or hard error) However, I suspect the

Re: Privy: An easy, fast lib to password-protect your data

2017-07-06 Thread ofekmeister
> The person spamming right now would be you. You just posted a link, > without any explanations, any marketing blurbs, nothing. I've explained everything as succinctly as I can in the readme. Pasting bits of it here would not benefit anyone. > Why would I use your tool instead of something

[issue30862] parent logger should also check the level

2017-07-06 Thread Vinay Sajip
Vinay Sajip added the comment: As RDM says, this behaviour is as designed. The logger's setLevel documentation says: "Sets the threshold for this logger to lvl. Logging messages which are less severe than lvl will be ignored. When a logger is created, the level is set to NOTSET (which causes

[issue30855] [3.5] test_tk: test_use() of test_tkinter.test_widgets randomly fails with "integer value too large to represent" on with AMD64 Windows8 3.5

2017-07-06 Thread STINNER Victor
STINNER Victor added the comment: New changeset f6d6480b93eca6f353784579108957108750c004 by Victor Stinner in branch '2.7': [2.7] bpo-30855: Trying to fix test_use on Windows. (#2586) https://github.com/python/cpython/commit/f6d6480b93eca6f353784579108957108750c004 --

[issue30847] asyncio: selector_events: add_urgent() for urgent data to read, 3rd argument of select.select()

2017-07-06 Thread Pim Klanke
Pim Klanke added the comment: This is in fact the third catagory of select(), "exceptional conditions", but because some find the term "exceptional" confusing when used in a Python module, we decided to use the term "urgent data", borrowed from the poll(2) man page. (see bpo-30844) An

[issue30799] Improved test coverage Lib/_osx_support.py 99%

2017-07-06 Thread chexex
New submission from chexex: I will appreciate any feedback. -- nosy: +ned.deily, ronaldoussoren ___ Python tracker ___

[issue30862] parent logger should also check the level

2017-07-06 Thread TaoQingyun
TaoQingyun added the comment: yes, I understand the effective level. my question is that before call ancestor's handler, should also check `c.isEnabledFor(record.levelno)` ``` def callHandlers(self, record): """ Pass a record to all relevant handlers. Loop through

[issue30865] python cannot import module located on a "VOLUME" directory

2017-07-06 Thread Adrien Pré
New submission from Adrien Pré: This issue created on python-docker project https://github.com/docker-library/python/issues/210 indicates that python cannot import a module if it is located on a docker-volume. yosifkit's comment suggest there is an issue in the UNC resolution with paths

[issue30866] Add _testcapi.stack_pointer() to measure the C stack consumption

2017-07-06 Thread STINNER Victor
Changes by STINNER Victor : -- pull_requests: +2670 ___ Python tracker ___ ___

[issue30866] Add _testcapi.stack_pointer() to measure the C stack consumption

2017-07-06 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: Usually we first merge a patch in master and after that cherry-pick it to other branches. -- ___ Python tracker ___

[issue30867] Add necessary macro `HAVE_OPENSSL_VERIFY_PARAM` to avoid invalid declaration

2017-07-06 Thread signal1587
New submission from signal1587: Compile Python (2.7.13) on platform which has OpenSSL (<0.9.8) will met error: /opt/Python-2.7.13/Modules/_ssl.c:177: error: syntax error before ‘*’ token Since return type `X509_VERIFY_PARAM` got added to OpenSSL in version 0.9.8. Surround the implementation

[issue30319] Change socket.close() to ignore ECONNRESET

2017-07-06 Thread STINNER Victor
STINNER Victor added the comment: Thanks Martin for the long explanation. To simplify a lot, there is and was never any warranty that a successful sock.send() call delivered data to the peer. Each layer does its best, but the data can be lost at any layer, and the peer is free to close the

[issue30855] [3.5] test_tk: test_use() of test_tkinter.test_widgets randomly fails with "integer value too large to represent" on with AMD64 Windows8 3.5

2017-07-06 Thread STINNER Victor
STINNER Victor added the comment: I backported fixes to 2.7 and 3.5 branches. The test fails randomly, so I close the issue and hope that it doesn't come back. If it comes back on 3.5, we should now get the identifier which caused the failure. I will reopen the issue if the bug occurs again.

[issue30866] Add _testcapi.stack_pointer() to measure the C stack consumption

2017-07-06 Thread STINNER Victor
Changes by STINNER Victor : -- pull_requests: +2669 ___ Python tracker ___ ___

Re: About the implementation of del in Python 3

2017-07-06 Thread Dan Wissme
Le 06/07/2017 à 09:29, Terry Reedy a écrit : On 7/6/2017 3:08 AM, Dan Wissme wrote: I thought that del L[i] would slide L[i+1:] one place to the left, filling the hole, but : >>> L [0, 10, 20, 30, 40, 50, 60, 70, 80, 90, 100] >>> id(L) 4321967496 >>> id(L[5])# address of 50 ? 4297625504

Re: About the implementation of del in Python 3

2017-07-06 Thread Marko Rauhamaa
Chris Angelico : > On Thu, Jul 6, 2017 at 5:35 PM, Jussi Piitulainen > wrote: >> Incidentally, let no one point out that ids are not memory addresses. >> It says in the interactive help that they are (Python 3.4.0): >> [...] > > Sorry, not the

[issue30866] Add _testcapi.stack_pointer() to measure the C stack consumption

2017-07-06 Thread STINNER Victor
New submission from STINNER Victor: In issues bpo-28870, bpo-29227, bpo-29233 and bpo-29234, I worked on reducing the C stack consumption. I now would to add the _testcapi.stack_pointer() that I used to be able to easily measure the stack consumption. Try for example attached

[issue30866] Add _testcapi.stack_pointer() to measure the C stack consumption

2017-07-06 Thread STINNER Victor
Changes by STINNER Victor : -- pull_requests: +2668 ___ Python tracker ___ ___

[issue30865] python cannot import module located on a "VOLUME" directory

2017-07-06 Thread Serhiy Storchaka
Changes by Serhiy Storchaka : -- components: +Windows nosy: +paul.moore, steve.dower, tim.golden, zach.ware ___ Python tracker

[issue30864] Compile failure for linux socket CAN support

2017-07-06 Thread Riccardo Magliocchetti
New submission from Riccardo Magliocchetti: I have an issue related to this while trying to compile statically Python 3.6.1 (but latest master looks the same) against a static musl. The problem is that i have AF_CAN defined because it's defined in linux/socket.h but by not having

[issue30847] asyncio: selector_events: add_urgent() for urgent data to read, 3rd argument of select.select()

2017-07-06 Thread STINNER Victor
STINNER Victor added the comment: Ok, it makes sense. Thanks :-) -- ___ Python tracker ___ ___

[issue30847] asyncio: selector_events: add_urgent() for urgent data to read, 3rd argument of select.select()

2017-07-06 Thread Pim Klanke
Pim Klanke added the comment: > "Let's say that we got read event on sockets A and B (in an ordered list from > selectors: A, then B), but B gets urgent data: should we handle B urgent data > before not-urgent A data?" IMO No. The same strategy applies. urgent data events on B have priority

[issue30866] Add _testcapi.stack_pointer() to measure the C stack consumption

2017-07-06 Thread STINNER Victor
Changes by STINNER Victor : -- pull_requests: +2671 ___ Python tracker ___ ___

[issue30339] test_multiprocessing_main_handling: "RuntimeError: Timed out waiting for results" on x86 Windows7 3.x

2017-07-06 Thread STINNER Victor
STINNER Victor added the comment: http://buildbot.python.org/all/builders/AMD64%20Windows7%20SP1%203.5/builds/229/steps/test/logs/stdio == FAIL: test_directory (test.test_multiprocessing_main_handling.SpawnCmdLineTest)

Re: About the implementation of del in Python 3

2017-07-06 Thread Dan Wissme
Le 06/07/2017 à 09:29, Terry Reedy a écrit : On 7/6/2017 3:08 AM, Dan Wissme wrote: I thought that del L[i] would slide L[i+1:] one place to the left, filling the hole, but : >>> L [0, 10, 20, 30, 40, 50, 60, 70, 80, 90, 100] >>> id(L) 4321967496 >>> id(L[5])# address of 50 ? 4297625504

Re: About the implementation of del in Python 3

2017-07-06 Thread Jussi Piitulainen
Chris Angelico writes: > On Thu, Jul 6, 2017 at 5:35 PM, Jussi Piitulainen > wrote: >> Incidentally, let no one point out that ids are not memory addresses. >> It says in the interactive help that they are (Python 3.4.0): >> >> Help on built-in function id in

[issue30867] Add necessary macro that insure`HAVE_OPENSSL_VERIFY_PARAM` to avoid invalid function declaration

2017-07-06 Thread signal1587
Changes by signal1587 : -- title: Add necessary macro `HAVE_OPENSSL_VERIFY_PARAM` to avoid invalid declaration -> Add necessary macro that insure`HAVE_OPENSSL_VERIFY_PARAM` to avoid invalid function declaration ___ Python

[issue30867] Add necessary macro that insure `HAVE_OPENSSL_VERIFY_PARAM` to avoid invalid function declaration

2017-07-06 Thread signal1587
Changes by signal1587 : -- title: Add necessary macro that insure`HAVE_OPENSSL_VERIFY_PARAM` to avoid invalid function declaration -> Add necessary macro that insure `HAVE_OPENSSL_VERIFY_PARAM` to avoid invalid function declaration

Re: About the implementation of del in Python 3

2017-07-06 Thread Steve D'Aprano
On Thu, 6 Jul 2017 06:51 pm, Dan Wissme wrote: > So what 'del L[i]' do exactly in memory ? Same as L.pop(i) ? with > complexity O(n-i) ? It depends on what L is and what the value of i is. If L is a list, and i is the last index of the list, then deleting it is quick. If i is 0, then Python has

[issue23644] g++ module compile fails with ‘_Atomic’ does not name a type

2017-07-06 Thread Melroy van den Berg
Melroy van den Berg added the comment: I also got this problem with gcc/g++ version 4.9.3. ./Include/pyatomic.h:37:5: error: 'atomic_int' does not name a type I'm using Python 3.6.1. It's not fixed! -- nosy: +Melroy van den Berg versions: +Python 3.6 -Python 3.5

[issue30862] parent logger should also check the level

2017-07-06 Thread R. David Murray
R. David Murray added the comment: @qingyunha: we are telling you that that would *introduce* a bug. This is working the way it is supposed to. Vinay, what if we rewrote the beginning of that paragraph like this: Sets the threshold for this logger to lvl. Logging messages which are less

[issue30865] python cannot import module located on a "VOLUME" directory

2017-07-06 Thread R. David Murray
R. David Murray added the comment: Reading through some of the linked material, it looks like the issue is with how UNC "symlinks" are resolved. -- nosy: +r.david.murray ___ Python tracker

Re: About the implementation of del in Python 3

2017-07-06 Thread Jussi Piitulainen
Marko Rauhamaa writes: > While talking about addresses might or might not be constructive, let > me just point out that there is no outwardly visible distinction > between "address" or "identity". With a generational or otherwise compacting garbage collector there would be. I believe that to be

[issue30858] Keyword can't be an expression?

2017-07-06 Thread R. David Murray
R. David Murray added the comment: If I saw your message, I would think "what is a 'simple name'?". There's no glossary entry for that, nor is it a concept used elsewhere in the documentation as far as I remember. One could instead use "single identifier", but the problem with both of

[issue30866] Add _testcapi.stack_pointer() to measure the C stack consumption

2017-07-06 Thread STINNER Victor
STINNER Victor added the comment: > Usually we first merge a patch in master and after that cherry-pick it to > other branches. Right. But in this case, I needed the patch for each branch, to run the test on all branches to write a blog post :-) Here are results (blog post spoiler!): Table

[issue30866] Add _testcapi.stack_pointer() to measure the C stack consumption

2017-07-06 Thread STINNER Victor
STINNER Victor added the comment: I just published my blog post: "My contributions to CPython during 2017 Q1" https://haypo.github.io/contrib-cpython-2017q1.html See the "Stack consumption" section. -- ___ Python tracker

[issue30860] Consolidate stateful C globals under a single struct.

2017-07-06 Thread Jeremy Kloth
Changes by Jeremy Kloth : -- nosy: +jkloth ___ Python tracker ___ ___

Re: About the implementation of del in Python 3

2017-07-06 Thread Steve D'Aprano
On Thu, 6 Jul 2017 07:24 pm, Marko Rauhamaa wrote: > While talking about addresses might or might not be constructive, let me > just point out that there is no outwardly visible distinction between > "address" or "identity". Er, yes there is. Address refers to a position in space. Identity

Re: About the implementation of del in Python 3

2017-07-06 Thread Chris Angelico
On Thu, Jul 6, 2017 at 7:24 PM, Marko Rauhamaa wrote: > While talking about addresses might or might not be constructive, let me > just point out that there is no outwardly visible distinction between > "address" or "identity". > > Equally well, we could replace those words

Re: About the implementation of del in Python 3

2017-07-06 Thread Marko Rauhamaa
Steve D'Aprano : > On Thu, 6 Jul 2017 07:24 pm, Marko Rauhamaa wrote: > >> While talking about addresses might or might not be constructive, let >> me just point out that there is no outwardly visible distinction >> between "address" or "identity". > > Er, yes there

[issue23644] g++ module compile fails with ‘_Atomic’ does not name a type

2017-07-06 Thread Melroy van den Berg
Melroy van den Berg added the comment: Ow sorry, I though it was already fixed in the latest stable version of 3.x. Since is issue is from 2015. -- ___ Python tracker

Re: About the implementation of del in Python 3

2017-07-06 Thread Jussi Piitulainen
MRAB writes: > On 2017-07-06 15:29, Jussi Piitulainen wrote: >> Marko Rauhamaa writes: >> >>> While talking about addresses might or might not be constructive, >>> let me just point out that there is no outwardly visible distinction >>> between "address" or

Re: About the implementation of del in Python 3

2017-07-06 Thread Marko Rauhamaa
Chris Angelico : > The formal definition is that objects have identities, and that > assignment (including function parameters and return values) gives you > a reference to the same object. My example didn't contain a single assignment, but a variation of your statement would

Re: About the implementation of del in Python 3

2017-07-06 Thread Chris Angelico
On Fri, Jul 7, 2017 at 12:56 AM, MRAB wrote: > Perhaps you should be thinking of it as passing around the end of a piece of > string, the other end being tied to the object itself. :-) You mean like Elbonian currency? http://dilbert.com/strip/2008-09-15 ChrisA --

Re: About the implementation of del in Python 3

2017-07-06 Thread Marko Rauhamaa
Jussi Piitulainen : > Marko Rauhamaa writes: > >> While talking about addresses might or might not be constructive, let >> me just point out that there is no outwardly visible distinction >> between "address" or "identity". > > With a generational or otherwise

[issue23644] g++ module compile fails with ‘_Atomic’ does not name a type

2017-07-06 Thread STINNER Victor
STINNER Victor added the comment: > I'm using Python 3.6.1. It's not fixed! Thanks for the confirmation of the fix ;-) -- ___ Python tracker ___

Re: About the implementation of del in Python 3

2017-07-06 Thread MRAB
On 2017-07-06 15:29, Jussi Piitulainen wrote: Marko Rauhamaa writes: While talking about addresses might or might not be constructive, let me just point out that there is no outwardly visible distinction between "address" or "identity". With a generational or otherwise compacting garbage

Re: About the implementation of del in Python 3

2017-07-06 Thread Jussi Piitulainen
Marko Rauhamaa writes: > Jussi Piitulainen: > >> For me it's enough to know that it's the object itself that is passed >> around as an argument, as a returned value, as a stored value, as a >> value of a variable. This is the basic fact that lets me understand >> the behaviour and performance of

Re: About the implementation of del in Python 3

2017-07-06 Thread Chris Angelico
On Fri, Jul 7, 2017 at 12:59 AM, Marko Rauhamaa wrote: >> Or you are using "address" in some abstract sense so that the "address" >> does not change when the internal representation of the object is moved >> to another location. > > "Address" is just a word. In fact, I don't

Re: About the implementation of del in Python 3

2017-07-06 Thread Chris Angelico
On Fri, Jul 7, 2017 at 1:21 AM, Marko Rauhamaa wrote: > Steve D'Aprano : > >> On Thu, 6 Jul 2017 07:24 pm, Marko Rauhamaa wrote: >> >>> While talking about addresses might or might not be constructive, let >>> me just point out that there is no

Re: About the implementation of del in Python 3

2017-07-06 Thread Ian Kelly
On Thu, Jul 6, 2017 at 9:41 AM, Marko Rauhamaa wrote: > As a good example of the style I'm looking for, take a look at: > >https://docs.oracle.com/javase/specs/jls/se7/html/jls-17.html> Java reference types have basically the same concept of identity as Python objects, so I

[issue30779] IDLE: configdialog -- factor out Changes class

2017-07-06 Thread Terry J. Reedy
Changes by Terry J. Reedy : -- pull_requests: +2677 ___ Python tracker ___ ___

Re: Test 0 and false since false is 0

2017-07-06 Thread Rick Johnson
On Thursday, July 6, 2017 at 9:29:29 PM UTC-5, Sayth Renshaw wrote: > I was trying to solve a problem and cannot determine how to filter 0's but > not false. > > Given a list like this > ["a",0,0,"b",None,"c","d",0,1,False,0,1,0,3,[],0,1,9,0,0,{},0,0,9] > > I want to be able to return this list

Re: Test 0 and false since false is 0

2017-07-06 Thread Skip Montanaro
I was trying to solve a problem and cannot determine how to filter 0's but not false. I'm typing on my phone so can't paste a session, so I will attempt to apply the Socratic method, and ask: Do you understand why your attempts have failed so far? In what way are False and 0 the same? In what

Re: Test 0 and false since false is 0

2017-07-06 Thread Dan Sommers
On Fri, 07 Jul 2017 02:48:45 +, Stefan Ram wrote: def isfalse( x ): > ... return x == 0 and str( type( x )) == "" > ... > Don't depend on string representations of objects, unless you know what you're doing. Do this instead: def isfalse(x): return x == 0 and type(x) is

[issue30869] regrtest: Add .idlerc to saved_test_environment

2017-07-06 Thread Louie Lu
Changes by Louie Lu : -- pull_requests: +2679 ___ Python tracker ___ ___ Python-bugs-list

[issue30869] regrtest: Add .idlerc to saved_test_environment

2017-07-06 Thread Louie Lu
New submission from Louie Lu: In bpo #30780, there is a mistake of tearDownModule didn't restore the use rCfg. To prevent future mistake, Adding .idlerc to regrtest saved_test_environment, so that `--fail-env-changed` option can detect .idlerc been changed in IDLE test. --

[issue30779] IDLE: configdialog -- factor out Changes class

2017-07-06 Thread Terry J. Reedy
Terry J. Reedy added the comment: Whoops, we seems to have partly overlapped (and made some of the same changes). I plan to push my PR sometime tomorrow (it also changes configdialog and revised tests) after looking as yours. Then move on to adding config tests, #30780. The tests for

[issue30780] IDLE: configdialog - add tests for ConfigDialog GUI.

2017-07-06 Thread Terry J. Reedy
Terry J. Reedy added the comment: New changeset 25a4206c243e3b1fa6f5b1c72a11b409b007694d by terryjreedy in branch 'master': bpo-30780: Fix error in idlelib.test_idle.test_configdialog (#2606) https://github.com/python/cpython/commit/25a4206c243e3b1fa6f5b1c72a11b409b007694d --

Test 0 and false since false is 0

2017-07-06 Thread Sayth Renshaw
I was trying to solve a problem and cannot determine how to filter 0's but not false. Given a list like this ["a",0,0,"b",None,"c","d",0,1,False,0,1,0,3,[],0,1,9,0,0,{},0,0,9] I want to be able to return this list ["a","b",None,"c","d",1,False,1,3,[],1,9,{},9,0,0,0,0,0,0,0,0,0,0] However if I

Re: get value from list using widget

2017-07-06 Thread Rick Johnson
On Wednesday, July 5, 2017 at 4:15:34 PM UTC-5, Terry Reedy wrote: > On 7/5/2017 12:34 PM, jorge.conr...@cptec.inpe.br wrote: > > > I would like know dow can I select and get the value from > > a list of values uisng widgets. > > One way is to learn tkinter and then learn to use the > Listbox

[issue30780] IDLE: configdialog - add tests for ConfigDialog GUI.

2017-07-06 Thread Terry J. Reedy
Terry J. Reedy added the comment: I posted PR 2612 for #30779 and expect to merge it tomorrow after sleep and final review. It includes passing revisions of existing configdialog tests. A PR dependent on 2612 could be posted before I do the merge. Follow the model of using xyzpage names in

  1   2   >