Re: Shoulid constants be introduced to Python?

2017-11-17 Thread Karsten Hilbert
On Thu, Nov 16, 2017 at 05:35:59PM -0500, ROGER GRAYDON CHRISTMAN wrote: > Well, pi already does have a value: > import math math.pi > > 3.141592653589793 > > but it's not a constant in the sense you are looking for: And, it's not really a constant at all, it's only got a constant

[issue32031] Do not use the canonical path in pydoc test_mixed_case_module_names_are_lower_cased

2017-11-17 Thread Xavier de Gaye
Xavier de Gaye added the comment: The path returned by inspect.getabsfile(xml.etree.ElementTree) is not the canonical path, hence the test failure. -- ___ Python tracker

[issue24260] TabError behavior doesn't match documentation

2017-11-17 Thread Mark Lawrence
Change by Mark Lawrence : -- nosy: -BreamoreBoy ___ Python tracker ___ ___

[issue32055] Reconsider comparison chaining for containment tests

2017-11-17 Thread Nick Coghlan
Nick Coghlan added the comment: Aye, there are definitely cases where the answer isn't nonsense. Even for sets though, "a in b < c" isn't an intuitive spelling of "a in b and b < c" the way that "a < b < c" is an intuitive spelling of an ordering relation. Hence filing

[issue31867] Duplicated keys in MIME type_map with different values

2017-11-17 Thread Andrew Svetlov
Andrew Svetlov added the comment: New changeset f02f5e5c3eb815fff9578dc58de60374c6baaa3d by Andrew Svetlov (Henk-Jaap Wagenaar) in branch 'master': bpo-31867: Remove duplicates in default mimetypes. (#4388)

[issue31867] Duplicated keys in MIME type_map with different values

2017-11-17 Thread Andrew Svetlov
Andrew Svetlov added the comment: Henk-Jaap thanks for contribution! -- resolution: -> fixed stage: patch review -> resolved status: open -> closed ___ Python tracker

[issue32055] Reconsider comparison chaining for containment tests

2017-11-17 Thread Nick Coghlan
Nick Coghlan added the comment: Just a note on why I find "a in b < c" unintuitive, even for sets: my brain initially wanted to read it as equivalent to "a in b & c". -- ___ Python tracker

[issue24260] TabError behavior doesn't match documentation

2017-11-17 Thread Stefan Krah
Change by Stefan Krah : -- nosy: -skrah ___ Python tracker ___ ___ Python-bugs-list

[issue32031] Do not use the canonical path in pydoc test_mixed_case_module_names_are_lower_cased

2017-11-17 Thread Xavier de Gaye
Change by Xavier de Gaye : -- keywords: +patch pull_requests: +4383 stage: needs patch -> patch review ___ Python tracker ___

[issue32058] Faulty behaviour in email.utils.parseaddr if square brackets in subject

2017-11-17 Thread tom de wulf
New submission from tom de wulf : Probably a parsing bug in email.utils.parseaddr. How to recreate: >>> import email.utils >>> test = 'Subject: I am a bug [Random]\r\nFrom: someone >>> \r\n\r\n' >>> email.utils.parseaddr(test) ('', 'I') >>>

[issue32059] detect_modules() in setup.py must also search the sysroot paths

2017-11-17 Thread Xavier de Gaye
New submission from Xavier de Gaye : When cross-compiling, the gcc and clang `--sysroot=` compiler option may be used to change the logical path of the system headers and libraries to a path located within the install path of the cross-compiler tool chain. Android is a

[issue32060] Should an ABC fail if no abstract methods are defined?

2017-11-17 Thread Alex Corcoles
New submission from Alex Corcoles : Hi, $ python3 Python 3.5.3 (default, Jan 19 2017, 14:11:04) >>> import abc >>> class Foo(abc.ABC): ... pass ... >>> Foo() <__main__.Foo object at 0x7f253e6dcb38> I think declaring a class as ABC without declaring any abstract method is

[issue32055] Reconsider comparison chaining for containment tests

2017-11-17 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: `a in b < c` makes sense if b and c are sets. -- nosy: +serhiy.storchaka ___ Python tracker

Re: Should constants be introduced to Python?

2017-11-17 Thread bartc
On 16/11/2017 06:16, Saeed Baig wrote: Hey guys I am thinking of perhaps writing a PEP to introduce constants to Python. Something along the lines of Swift’s “let” syntax (e.g. “let pi = 3.14”). Since I’m sort of new to this, I just wanted to ask: - Has a PEP for this already been written? If

[issue24260] TabError behavior doesn't match documentation

2017-11-17 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: My model is the same as the Martin's one. I know how to implement this, but the code isn't simple. I'm going to do this after fixing other bugs in the tokenizer. -- nosy: +serhiy.storchaka priority: normal -> low

[issue29185] test_distutils fails on Android API level 24

2017-11-17 Thread Xavier de Gaye
Change by Xavier de Gaye : -- pull_requests: +4380 ___ Python tracker ___ ___

[issue32056] bug in Lib/wave.py

2017-11-17 Thread zhangdeyue
Change by zhangdeyue : -- keywords: +patch pull_requests: +4382 stage: -> patch review ___ Python tracker ___

[issue32056] bug in Lib/wave.py

2017-11-17 Thread 张德岳
New submission from 张德岳 : I found a bug in wave.py because there is no check for self._channel in _read_fmt_chunk function. When I try to open a wav file which channel is zero, it will crash bacause of divided by zero in initfp function. -- components: Library

[issue32031] Do not use the canonical path in pydoc test_mixed_case_module_names_are_lower_cased

2017-11-17 Thread Xavier de Gaye
Xavier de Gaye added the comment: The error: generic_x86_64:/data/local/tmp/python $ python -m test test_pydoc Run tests sequentially 0:00:00 [1/1] test_pydoc test test_pydoc failed -- Traceback (most recent call last): File

[issue32057] time.sleep(n) interrupted by signal

2017-11-17 Thread Bogdan Popa
Bogdan Popa added the comment: I forgot to mention that I am on macOS Sierra (10.12.6) and I ran the code on Python 3.4.6, 3.5.3 and 3.6.3, respectively. -- ___ Python tracker

[issue29753] Ctypes Packing Bitfields Incorrectly - Linux

2017-11-17 Thread Antti Haapala
Antti Haapala added the comment: "Antti, is there a place in the ctypes documentation that explicitly says ctypes is not meant to be used cross-platform? If not, shouldn't that be mentioned?" I don't know about that, but the thing is nowhere does it say that it is meant

[issue32053] Inconsistent use of tabs and spaces in indentation not always detected

2017-11-17 Thread Stefan Krah
Change by Stefan Krah : -- resolution: -> duplicate stage: -> resolved status: open -> closed superseder: -> TabError behavior doesn't match documentation ___ Python tracker

[issue24260] TabError behavior doesn't match documentation

2017-11-17 Thread Stefan Krah
Stefan Krah added the comment: I'm now in the camp of forbidding tabs. When I wrote my own parser a couple of years ago, I tested it on a huge body of Python files that were present on my system. Tabs always looked accidental. Is there any *known* code base that

[issue24260] TabError behavior doesn't match documentation

2017-11-17 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: Lets not continue a holy war here. I'm in the camp of tab-indenters. -- ___ Python tracker

[issue32057] time.sleep(n) interrupted by signal

2017-11-17 Thread STINNER Victor
STINNER Victor added the comment: I'm sorry but Python 3.4 doesn't accept bugfixes anymore. Same for Python 3.5. https://devguide.python.org/#status-of-python-branches > The following piece of code prints one line every second, as expected, on 3.6 > and 3.5 Good, at

[issue24260] TabError behavior doesn't match documentation

2017-11-17 Thread Stefan Krah
Stefan Krah added the comment: python-dev is becoming insufferable. -- ___ Python tracker ___

[issue32057] time.sleep(n) interrupted by signal

2017-11-17 Thread Bogdan Popa
New submission from Bogdan Popa : I ran into this while backporting some code from 3.6 to 3.5 and 3.4. The following piece of code prints one line every second, as expected, on 3.6 and 3.5, but it doesn't on 3.4. It looks like the signal is able to wake up the main

[issue32057] time.sleep(n) interrupted by signal

2017-11-17 Thread Bogdan Popa
Bogdan Popa added the comment: Fair enough. From reading PEP 475, it does look like that's what fixed it. Thanks Victor! -- resolution: -> wont fix stage: -> resolved status: open -> closed ___ Python tracker

[issue32058] Faulty behaviour in email.utils.parseaddr if square brackets in subject

2017-11-17 Thread R. David Murray
R. David Murray added the comment: Unfortunately the imap module in the stdlib doesn't provide a whole lot in the way of tools for parsing the imap data, just for sending it back and forth to the server. -- ___ Python

[issue30004] in regex-howto, improve example on grouping

2017-11-17 Thread Cristian Barbarosie
Cristian Barbarosie added the comment: I'm sorry, I have no experience at all with Git. Could you please do it for me ? The bug appears in two places, see my first two messages. Thank you -- ___ Python tracker

[issue32061] test_httpservers.test_undecodable_filename() fails with [Errno 92] Illegal byte sequence on macOS Sierra

2017-11-17 Thread STINNER Victor
New submission from STINNER Victor : x86-64 Sierra 3.6 failure: http://buildbot.python.org/all/#/builders/20/builds/81 == ERROR: test_undecodable_filename

[issue32062] test_venv fails if zlib is not available

2017-11-17 Thread STINNER Victor
STINNER Victor added the comment: Oh, Serhiy already fixed it: bpo-31999. -- resolution: -> duplicate stage: -> resolved status: open -> closed superseder: -> test_venv failed when the zlib module is not available ___

Re: "help( pi )"

2017-11-17 Thread Marko Rauhamaa
Paul Moore : > numbers don't have docstrings. There's no reason they couldn't: >>> help(2) Help on built-in number 2 in module builtins: 2 2 -> int The natural number immediately succeeding 1 (qv). The number of hemispheres in a healthy mammal's

[issue32058] Faulty behaviour in email.utils.parseaddr if square brackets in subject

2017-11-17 Thread R. David Murray
R. David Murray added the comment: parseaddr is for parsing the contents of an address header, not for parsing any additional text. So the correct way to call it is parseaddress('someone '). In any case, please look in to the new email policies,

[issue32061] test_httpservers.test_undecodable_filename() fails with [Errno 92] Illegal byte sequence on macOS Sierra

2017-11-17 Thread STINNER Victor
STINNER Victor added the comment: Oh, it's a duplicate of bpo-31380. -- resolution: -> duplicate stage: -> resolved status: open -> closed superseder: -> test_undecodable_filename() in Lib/test/test_httpservers.py broken on APFS

[issue31380] test_undecodable_filename() in Lib/test/test_httpservers.py broken on APFS

2017-11-17 Thread STINNER Victor
Change by STINNER Victor : -- nosy: +haypo ___ Python tracker ___ ___

[issue30004] in regex-howto, improve example on grouping

2017-11-17 Thread Mandeep Bhutani
Mandeep Bhutani added the comment: Cristian, Serhiy: I've submitted a PR for this bug. Cristian: I apologize for misspelling your name in a prior post. -- ___ Python tracker

Re: "help( pi )"

2017-11-17 Thread Paul Moore
On 17 November 2017 at 12:36, Stefan Ram wrote: > A web page says: > > “The argument to pydoc can be the name of a function, > module, or package, or a dotted reference to a class, > method, or function within a module or module in a package.” [...] > , but not for

EuroPython 2018: Location and Dates

2017-11-17 Thread M.-A. Lemburg
After a two month RFP bidding process with 19 venues from all over Europe, we are pleased to announce our selection of the location and venue for EuroPython 2018: * Location: Edinburgh, UK * Venue: Edinburgh International Conference Center (EICC) http://www.eicc.co.uk/ * Dates: July 23

[issue32060] Should an ABC fail if no abstract methods are defined?

2017-11-17 Thread R. David Murray
R. David Murray added the comment: No, you could create an ABC whose only purpose was to be a target of register calls. As with the issue you reference, this is something better implemented in a linter. I'll leave this open for at least one other dev to concur and

[issue30004] in regex-howto, improve example on grouping

2017-11-17 Thread Mandeep Bhutani
Mandeep Bhutani added the comment: Serhiy, Christian: I'll submit a PR for this later today. -- ___ Python tracker ___

[issue32062] test_venv fails if zlib is not available

2017-11-17 Thread STINNER Victor
New submission from STINNER Victor : test_venv should skip test_with_pip() test when the zlib module is missing. x86-64 Sierra 3.6 failure: http://buildbot.python.org/all/#/builders/20/builds/62 test_with_pip (test.test_venv.EnsurePipTest) ... FAIL

[issue32058] Faulty behaviour in email.utils.parseaddr if square brackets in subject

2017-11-17 Thread tom de wulf
tom de wulf added the comment: I do get this data from an IMAP fetch statement, see my code below: rv, data = imap.fetch(num, "(BODY[HEADER.FIELDS (FROM SUBJECT)])") if rv != 'OK': logging.error("Error getting message sender and subject (" +

[issue32063] test_multiprocessing_forkserver failed with OSError: [Errno 48] Address already in use

2017-11-17 Thread STINNER Victor
New submission from STINNER Victor : x86-64 Sierra 3.6: http://buildbot.python.org/all/#/builders/20/builds/62 0:06:16 load avg: 3.45 [ 87/405/1] test_multiprocessing_forkserver failed -- running: test_tokenize (77 sec) Process QueueManager-260: Traceback (most recent

[issue30004] in regex-howto, improve example on grouping

2017-11-17 Thread Mandeep Bhutani
Change by Mandeep Bhutani : -- keywords: +patch pull_requests: +4384 stage: needs patch -> patch review ___ Python tracker ___

[issue32060] Should an ABC fail if no abstract methods are defined?

2017-11-17 Thread R. David Murray
R. David Murray added the comment: The docs start out with "as outlined in PEP 3119; see the PEP for why this was added to Python". I think it would be a good doc enhancement request to extract the motivation and other description out of that pep and put it in the

[issue32046] 2to3 fix for operator.isCallable()

2017-11-17 Thread Guido van Rossum
Guido van Rossum added the comment: I would convert this to `callable()` -- the conversion to collections.abc.Callable is more verbose and requires an extra import (that can be slow). -- nosy: +gvanrossum ___ Python tracker

[issue32060] Should an ABC fail if no abstract methods are defined?

2017-11-17 Thread Raymond Hettinger
Raymond Hettinger added the comment: FWIW, I should have add a bit more explanation. The logic for ABCs instantiation is roughly: if any(method.is_abstract() for method in dir(cls)): raise TypeError('I refuse to instantiate') inst =

[issue32060] Should an ABC fail if no abstract methods are defined?

2017-11-17 Thread Raymond Hettinger
Raymond Hettinger added the comment: I concur. -- nosy: +rhettinger resolution: -> not a bug stage: -> resolved status: open -> closed ___ Python tracker

[issue32060] Should an ABC fail if no abstract methods are defined?

2017-11-17 Thread Alex Corcoles
Alex Corcoles added the comment: Are you referring to something akin to Java's marker interfaces? That is, a class with no methods which you inherit from just for semantic meaning (e.g. Java's serializable interface that you implement to indicate that the class is designed for

Re: Artificial creating of [Lists], is it possible? the best way...

2017-11-17 Thread eth0
On Fri, 17 Nov 2017 00:04:16 + in comp.lang.python, MRAB said: > On 2017-11-16 18:47, jakub.raj...@gmail.com wrote: > > Hello, im working on school project, its deck game Sorry! > > I need to create specific lists: > > My idea is about to using for > > For i in range (n): > > i=[] > >

[issue32059] detect_modules() in setup.py must also search the sysroot paths

2017-11-17 Thread Xavier de Gaye
Xavier de Gaye added the comment: > while on a standard platform where the root path of usr/include and usr/lib > is common, one would only need to set sysroot to this root path in CFLAGS s/CFLAGS/CC/ -- ___ Python tracker

Re: "help( pi )"

2017-11-17 Thread Paul Moore
On 17 November 2017 at 15:52, Marko Rauhamaa wrote: > Paul Moore : >> numbers don't have docstrings. > > There's no reason they couldn't: In the sense that the Python object model could be amended to attach docstrings to instances of classes like "int", and

[issue28414] SSL match_hostname fails for internationalized domain names

2017-11-17 Thread Nick Lamb
Nick Lamb added the comment: As much for myself when I next run into this on my checklist as for any other readers: Despite the appearance of nothing happening PR 3010 (linked) actually has a little bit of momentum and seems likely to eventually land in Python.

Re: Should constants be introduced to Python?

2017-11-17 Thread Marko Rauhamaa
Marcin Tustin : > I'm against this because Python's strength is its simplicity. This > doesn't actually simplify anything, but it does add a new language > feature to understand. And there will be eternal debates on the correct use of the feature. One of the ugliest

Re: Artificial creating of [Lists], is it possible? the best way...

2017-11-17 Thread Chris Angelico
On Sat, Nov 18, 2017 at 2:29 AM, eth0 wrote: > On Fri, 17 Nov 2017 00:04:16 + in comp.lang.python, MRAB said: >> On 2017-11-16 18:47, jakub.raj...@gmail.com wrote: >> > Hello, im working on school project, its deck game Sorry! >> > I need to create specific lists: >>

Re: Artificial creating of [Lists], is it possible? the best way...

2017-11-17 Thread Grant Edwards
On 2017-11-17, eth0 wrote: > On Fri, 17 Nov 2017 00:04:16 + in comp.lang.python, MRAB said: >> On 2017-11-16 18:47, jakub.raj...@gmail.com wrote: >> > Hello, im working on school project, its deck game Sorry! >> > I need to create specific lists: >> > My idea is

Re: from xx import yy

2017-11-17 Thread Bob van der Poel
On Thu, Nov 16, 2017 at 2:46 PM, Cameron Simpson wrote: > On 16Nov2017 09:42, bvdp wrote: > >> In my original case, I think (!!!), the problem was that I had a variable >> in mod1.py and when I did the "from mod1 import myvarible" all was fine. >> Python

[issue32016] Python 3.6.3 venv FAILURE

2017-11-17 Thread Éric Araujo
Éric Araujo added the comment: Can you find out the full error message from pip? -- nosy: +eric.araujo ___ Python tracker ___

[issue32064] python msilib view.fetch is not returning none

2017-11-17 Thread uday kiran
New submission from uday kiran : Please see my script attached. Once the records are completed, the View.Fetch() function should give a none value but intsead giving runtime error: _msi.MSIError: unknown error 103 It is already mentioned in the bugs.

Re: Artificial creating of [Lists], is it possible? the best way...

2017-11-17 Thread Rick Johnson
On Thursday, November 16, 2017 at 12:48:05 PM UTC-6, Jakub Raj ok wrote: > Artificial creating of [Lists], is it possible? the best way... There is nothing "artificial" about creating any object. Much less python lists. And i believe the usage of such word in the title of this thread was

[issue32064] python msilib view.fetch is not returning none

2017-11-17 Thread uday kiran
uday kiran added the comment: It seems you have added some patches as .c files, but how do we apply those on windows machines? No documentation related to it. https://bugs.python.org/file24795/_msi_fetch.patch.txt https://bugs.python.org/file11840/_msi.patch.txt Could

Re: "help( pi )"

2017-11-17 Thread Gregory Ewing
It *could* be made to work: import math class PI(float): __doc__ = "The circle constant (Note: tau is better :-)" math.pi = PI(math.pi) print(math.pi) help(math.pi) -- Greg -- https://mail.python.org/mailman/listinfo/python-list

Re: "help( pi )"

2017-11-17 Thread Chris Angelico
On Sat, Nov 18, 2017 at 8:27 AM, Gregory Ewing wrote: > It *could* be made to work: > > import math > > class PI(float): > > __doc__ = "The circle constant (Note: tau is better :-)" > > math.pi = PI(math.pi) > > print(math.pi) >

Re: Should constants be introduced to Python?

2017-11-17 Thread bartc
On 17/11/2017 15:14, Marcin Tustin wrote: I'm against this because Python's strength is its simplicity. If it was simple once, then it isn't any more. Perhaps you mean consistency, in having only one class of identifier which can always be assigned to. All the benefits of this can be

Re: Should constants be introduced to Python?

2017-11-17 Thread Marcin Tustin
Yes the same consideration applies to any new feature. I think that Python's reticence to add new features has been a strength. And I do think the benefit here is absolutely negligible. It's not that I don't like constants - but there's a bunch of things that go great together, like constants,

[issue32050] Deprecated python3 -x option

2017-11-17 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: The current short line of the description was enough to me for understanding what is the purpose of this option and how it can be used (I didn't use Windows for more than 10 years). But I was surprised not founding more detailed

[issue32022] Python crashes with mutually recursive code

2017-11-17 Thread Terry J. Reedy
Terry J. Reedy added the comment: It is possible that this is a duplicate of an existing crash report, but I am not familiar with such at all. With only the standard, non-specific error message, it is hard to search ;-). What OS are you using? --

[issue32022] Python crashes with mutually recursive code

2017-11-17 Thread Terry J. Reedy
Terry J. Reedy added the comment: I believe I used the 2nd version of kakuru.py. -- ___ Python tracker ___

[issue32022] Python crashes with mutually recursive code

2017-11-17 Thread Terry J. Reedy
Terry J. Reedy added the comment: PS. When you respond by EMail, please delete the quoted message, as it is redundant, on the web page, with the original copy above. -- ___ Python tracker

[issue32022] Python crashes with mutually recursive code

2017-11-17 Thread Shimon Malachi Cohen
Shimon Malachi Cohen added the comment: Cool, thanks! On Nov 18, 2017 5:29 AM, "Terry J. Reedy" wrote: > > Terry J. Reedy added the comment: > > I believe I used the 2nd version of kakuru.py. > > -- > >

[issue32022] Python crashes with mutually recursive code

2017-11-17 Thread Terry J. Reedy
Terry J. Reedy added the comment: The RESTART line means that you ran this in IDLE and that your program crashed the separate (sub)process that was running your code. When IDLE notices this, it starts a new subprocess. To test whether this is an IDLE-only problem, I ran

[issue32050] Deprecated python3 -x option

2017-11-17 Thread Terry J. Reedy
Terry J. Reedy added the comment: So the hack is not specific to DOS but is still needed for Windows .bat files. They run in Command Prompt, which was once called the DOS box. (I don't know if they work unaltered in PowerShell.) It seems that the doc should be updated.

[issue24260] TabError behavior doesn't match documentation

2017-11-17 Thread STINNER Victor
Change by STINNER Victor : -- nosy: +haypo ___ Python tracker ___ ___

Re: Should constants be introduced to Python?

2017-11-17 Thread Marcin Tustin
I'm against this because Python's strength is its simplicity. This doesn't actually simplify anything, but it does add a new language feature to understand. All the benefits of this can be achieved with linting. On Thu, Nov 16, 2017 at 1:16 AM, Saeed Baig wrote: > Hey

[issue31701] faulthandler dumps 'Windows fatal exception: code 0xe06d7363'

2017-11-17 Thread STINNER Victor
STINNER Victor added the comment: > Please ignore everything I said about AddVectoredContinueHandler. I finally > got a chance to test the code on Windows and the way it's called is not > suitable for faulthandler. Oh, good to know. Thank you for having tested that

[issue32065] range_iterator doesn't have length, leads to surprised result

2017-11-17 Thread R. David Murray
R. David Murray added the comment: By design, iterators do not have a length (see msg248496). -- nosy: +r.david.murray resolution: -> not a bug stage: -> resolved status: open -> closed ___ Python tracker

[issue32065] range_iterator doesn't have length, leads to surprised result

2017-11-17 Thread yegle
yegle added the comment: Hmm I think this also applies to list_listiterator. In general I'd expect these to be true: l = [1,2,3] r = range(3) assert len(l) == len(reversed(l)) assert len(r) == len(reversed(r)) -- ___ Python

[issue31701] faulthandler dumps 'Windows fatal exception: code 0xe06d7363'

2017-11-17 Thread Ilya Kulakov
Ilya Kulakov added the comment: Please ignore everything I said about AddVectoredContinueHandler. I finally got a chance to test the code on Windows and the way it's called is not suitable for faulthandler. -- ___ Python

[issue32065] range_iterator doesn't have length, leads to surprised result

2017-11-17 Thread yegle
New submission from yegle : This also affects xrange in Python2, so I chose the affected version as python27. range object (and xrange in Python2) has __len__(), but the range_iterator object created from __reversed__() doesn't have __len__. Python2: >>> x = xrange(10) >>>

Re: "help( pi )"

2017-11-17 Thread Python
On Sat, Nov 18, 2017 at 09:50:29AM +1100, Chris Angelico wrote: > Perhaps what we want is not so much "attach docstrings to floats" but > "get documentation for a module attribute, not for the object referred > to". The reason this can't really work is that members are just variables with

ctypes help

2017-11-17 Thread Python
Hello Pythonistas, I'm starting to play with ctypes, as I'd like to provide Python interfaces to a C/C++ library I have. For now I'm just messing with a very simple piece of code to get things sorted out. I'm working with this example C++ library, which just wraps a call to stat():

[issue31691] Include missing info on required build steps and how to build installer

2017-11-17 Thread Ivan Pozdeev
Change by Ivan Pozdeev : Removed file: https://bugs.python.org/file47260/0001-Add-missing-but-required-build-steps-and-how-to-buil.patch ___ Python tracker

Re: "help( pi )"

2017-11-17 Thread Cameron Simpson
On 17Nov2017 11:09, Dennis Lee Bieber wrote: On 17 Nov 2017 12:36:37 GMT, r...@zedat.fu-berlin.de (Stefan Ram) declaimed “The argument to pydoc can be the name of a function, module, or package, or a dotted reference to a class, method, or function within a module or

Re: "help( pi )"

2017-11-17 Thread Chris Angelico
On Sat, Nov 18, 2017 at 9:38 AM, Cameron Simpson wrote: > I don't think he's arguing that help magicly recognises 3.1415926536 as "pi" > and produces a docstring for it and all "sufficiently close" values. I'm > not. But the math module has bound "pi" to a specific float. Why

[issue32066] asyncio: Support pathlib.Path in create_unix_connection; sock arg should be optional

2017-11-17 Thread Yury Selivanov
Change by Yury Selivanov : -- components: asyncio nosy: asvetlov, yselivanov priority: normal severity: normal status: open title: asyncio: Support pathlib.Path in create_unix_connection; sock arg should be optional versions: Python 3.6, Python 3.7

[issue32066] asyncio: Support pathlib.Path in create_unix_connection; sock arg should be optional

2017-11-17 Thread Yury Selivanov
Change by Yury Selivanov : -- keywords: +patch pull_requests: +4386 stage: -> patch review ___ Python tracker ___

Re: ctypes help

2017-11-17 Thread Chris Angelico
On Sat, Nov 18, 2017 at 9:11 AM, Python wrote: > Hello Pythonistas, > > I'm starting to play with ctypes, as I'd like to provide Python > interfaces to a C/C++ library I have. For now I'm just messing with a > very simple piece of code to get things sorted out. I'm

[issue32065] range_iterator doesn't have length, leads to surprised result

2017-11-17 Thread STINNER Victor
Change by STINNER Victor : -- versions: +Python 3.7 ___ Python tracker ___ ___

Re: "help( pi )"

2017-11-17 Thread Chris Angelico
On Sat, Nov 18, 2017 at 10:34 AM, Python wrote: > On Sat, Nov 18, 2017 at 09:50:29AM +1100, Chris Angelico wrote: >> Perhaps what we want is not so much "attach docstrings to floats" but >> "get documentation for a module attribute, not for the object referred >> to". > >

[issue31701] faulthandler dumps 'Windows fatal exception: code 0xe06d7363'

2017-11-17 Thread Steve Dower
Steve Dower added the comment: SetUnhandledExceptionFilter could be a good option. I suspect the difference between that and AddVectorContinueHandler are because of the weird prioritization of the two types of handler, and are probably not significant enough to worry

[issue31701] faulthandler dumps 'Windows fatal exception: code 0xe06d7363'

2017-11-17 Thread Ilya Kulakov
Ilya Kulakov added the comment: Steve, the difficulty with SetUnhandledExceptionFilter is that it can replace filter installed by the user (e.g. one of loaded libraries). The information about AddVectoredContinueHandler is scarce, but according to what I found at [1]:

[issue31701] faulthandler dumps 'Windows fatal exception: code 0xe06d7363'

2017-11-17 Thread STINNER Victor
STINNER Victor added the comment: > I suspect the difference between that and AddVectorContinueHandler are > because of the weird prioritization of the two types of handler, and are > probably not significant enough to worry about here. Ok, thanks. I close the issue

Re: "help( pi )"

2017-11-17 Thread Chris Angelico
On Sat, Nov 18, 2017 at 10:35 AM, Stefan Ram wrote: > Dennis Lee Bieber writes: >>should >> help(3.1415926536) #or whatever precision is used in >> module math >>produce anything? > > That question made me try something else

[issue29753] Ctypes Packing Bitfields Incorrectly - Linux

2017-11-17 Thread Charles Machalow
Charles Machalow added the comment: All of Python is implicitly cross platform. If something isn't actually cross platform, it should be mentioned explicitly in the documentation. For example see the mmap documentation, it explicitly say on Unix it does X, on Windows it

Re: "help( pi )"

2017-11-17 Thread Python
On Sat, Nov 18, 2017 at 10:47:55AM +1100, Chris Angelico wrote: > On Sat, Nov 18, 2017 at 10:34 AM, Python wrote: > > On Sat, Nov 18, 2017 at 09:50:29AM +1100, Chris Angelico wrote: > >> Perhaps what we want is not so much "attach docstrings to floats" but > >> "get

Re: "help( pi )"

2017-11-17 Thread Chris Angelico
On Sat, Nov 18, 2017 at 2:12 PM, Python wrote: > On Sat, Nov 18, 2017 at 10:47:55AM +1100, Chris Angelico wrote: >> On Sat, Nov 18, 2017 at 10:34 AM, Python wrote: >> > On Sat, Nov 18, 2017 at 09:50:29AM +1100, Chris Angelico wrote: >> >> Perhaps

Re: ctypes help

2017-11-17 Thread Python
On Sat, Nov 18, 2017 at 10:49:40AM +1100, Chris Angelico wrote: > On Sat, Nov 18, 2017 at 9:11 AM, Python wrote: > > Hello Pythonistas, > > > > I'm starting to play with ctypes, as I'd like to provide Python > > interfaces to a C/C++ library I have. For now I'm just

[issue31643] test_uuid: test_getnode and test_windll_getnode fail if connected to the Internet via an Android phone

2017-11-17 Thread Ivan Pozdeev
Change by Ivan Pozdeev : -- pull_requests: +4387 stage: -> patch review ___ Python tracker ___

Re: "help( pi )"

2017-11-17 Thread Python
On Sat, Nov 18, 2017 at 02:19:25PM +1100, Chris Angelico wrote: > On Sat, Nov 18, 2017 at 2:12 PM, Python wrote: > > On Sat, Nov 18, 2017 at 10:47:55AM +1100, Chris Angelico wrote: > >> On Sat, Nov 18, 2017 at 10:34 AM, Python wrote: > >> > On Sat,

  1   2   >