[issue32616] Significant performance problems with Python 2.7 built with clang 3.x or 4.x

2018-02-07 Thread INADA Naoki

Change by INADA Naoki :


--
resolution:  -> fixed
stage: patch review -> resolved
status: open -> closed

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue32431] Two bytes objects of zero length don't compare equal

2018-02-07 Thread Xiang Zhang

Xiang Zhang  added the comment:

In my mind I don't think here is any problem. The code

val = PyBytes_FromStringAndSize (NULL, 20);
Py_SIZE(val) = 0;

doesn't create a zero length bytes object. A resizing I think should always 
means reorganizing the internal representation, including changing the size 
attribute. Using Py_SIZE won't trigger a full resizing. The code is not 
resizing but just breaks the internal representation and then leads to bugs. In 
C level, if you want, it's easy to muck Python objects. And exposing that much 
implementation details in documentation seems unnecessary.

--
nosy: +xiang.zhang

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue32791] Add\Remove Programs entry is not created.

2018-02-07 Thread WilliamM

New submission from WilliamM :

I've been writing a script for the Python 3.X install package and encountering 
some issues due to that.

I'm using the installation property InstallAllUsers=1 but find that Python is 
still placing it's Add/Remove programs entry in user context.

Applications usually write system level installs to 
HKLM:\SOFTWARE\Microsoft\Windows\CurrentVersion\Uninstall or 
HKLM:\SOFTWARE\Wow6432Node\Microsoft\Windows\CurrentVersion\Uninstall

What I'm encountering with Python is that it's writing them to 
HKCU:\Software\Microsoft\Windows\CurrentVersion\Uninstall

This is causing some difficulty as it prevents software such as SCCM, KACE, 
Altiris from being able to detect the main program install or a user with 
elevated privileges from being able to remove it.

Deploying the software will end up with the entry located the System Account's 
registry within 
HKU\S-5-1-18\Software\Microsoft\WIndows\CurrentVersion\Uninstall\{Prodct GUID}

To add a bit more info, only the dependencies show up in 
HKLM:\SOFTWARE\Wow6432Node\Microsoft\Windows\CurrentVersion\Uninstall

Python 3.6.4 TCL/TK support (32-Bit)
Python 3.6.4 Development Libraries (32-Bit)
Python 3.6.5 Documentation (32-Bit)
Python 3.6.4 Utility Scripts (32-Bit)
Python 3.6.4 Executables (32-Bit)
Python launcher (32-Bit)
Python 3.6.4 Test Suite (32-Bit)
Python 3.6.4 Core Interpreter  (32-Bit)
Python 3.6.4 Standard Library (32-Bit)

However the "Python 3.6.4 (32-Bit)" Install that has the installation and 
bundled uninstall package is located in 
HKU\S-1-5-18\Software\Microsoft\WIndows\CurrentVersion\Uninstall\{9218130b-5ad0-4cf7-82be-6993cfd6cb84}

Is there a known workaround/solution for this or something that can be resolved 
in a later build?

--
components: Windows
messages: 311814
nosy: WilliamM, paul.moore, steve.dower, tim.golden, zach.ware
priority: normal
severity: normal
status: open
title: Add\Remove Programs entry is not created.
type: behavior
versions: Python 3.6

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue32790] Keep trailing zeros in precision for string format option g

2018-02-07 Thread Severin Wünsch

New submission from Severin Wünsch :

The documentation starts the the string format parameter 'g':

General format. For a given precision p >= 1, this rounds the number to **p 
significant digits** and then formats the result in either fixed-point format 
or in scientific notation, depending on its magnitude.

I think the behavior of format is inconsistent here:
>>> format(0.1949, '.2g')
returns '0.19' as expected but
>>> format(0.1950, '.2g')
returns '0.2' instead of '0.20'

This behavior for float is in my opinion the correct one here
>>> format(0.1950, '.2f')
returns '0.20'

--
messages: 311813
nosy: sk1d
priority: normal
severity: normal
status: open
title: Keep trailing zeros in precision for string format option g
type: behavior
versions: Python 3.7

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue32786] Didnot work strftime() when hangeul in format sting

2018-02-07 Thread Larry Hastings

Change by Larry Hastings :


--
nosy:  -larry

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue32786] Didnot work strftime() when hangeul in format sting

2018-02-07 Thread Myungseo Kang

Myungseo Kang  added the comment:

It works correctly in python 3.6

I think this problem is occured only python 3.4
First, I changed this code like below.

```
'{0:%Y}년 {0:%-m}월 {0:%-d}일'.format(proposal.hold_end_date)
```

But I wonder why doesn't work in only python 3.4

--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue32394] socket lib beahavior change in 3.6.4

2018-02-07 Thread Ma Lin

Ma Lin  added the comment:

Here is PR 5585 for 3.6 branch.

For 3.7+, I would suggest patch in socketmodule.c like this:

PyMODINIT_FUNC
PyInit__socket(void)
{
PyObject *m, *has_ipv6;
...
...
...
+#ifdef MS_WINDOWS
+   return remove_unusable_flags(m);
+#else
return m;
+#endif
}

In this way, we handle the flags in a separated function 
remove_unusable_flags(m).
It keeps both socket.py and socketmodule.c neat.

Timelines FYI:

3.6.5 candidate: 2018-03-12 (tenative)
3.6.5 final: 2018-03-26 (tentative)

3.7.0 beta 2: 2018-02-26
3.7.0 beta 3: 2018-03-26
3.7.0 beta 4: 2018-04-30

> What's about other OS/flags?
> Should we commit that every exposed socket flag is supported in runtime?
> It looks like very heavy burden.

I have an idea about this concern, I will post it after some experiments.

--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue32394] socket lib beahavior change in 3.6.4

2018-02-07 Thread Ma Lin

Change by Ma Lin :


--
pull_requests: +5403

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue32773] distutils should NOT preserve timestamps

2018-02-07 Thread Jay Yin

Change by Jay Yin :


--
keywords: +patch
pull_requests: +5401
stage:  -> patch review

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue32706] test_check_hostname() of test_ftplib started to fail randomly

2018-02-07 Thread Barry A. Warsaw

Barry A. Warsaw  added the comment:

Yep, I'm seeing those same failures in our internal build of 3.7.0b1.  I'll 
just disable the tests for now and nosy on this issue.

--
nosy: +barry

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue32773] distutils should NOT preserve timestamps

2018-02-07 Thread Jay Yin

Jay Yin  added the comment:

would it be ok for me to make a patch for this as practice?, I will be making a 
PR though, I will be making the -- option available for backward compatibility.

--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue32585] Add ttk::spinbox to tkinter.ttk

2018-02-07 Thread Alan Moore

Alan Moore  added the comment:

Thanks, I'm guessing  the update_idletasks() needed to be called after 
changing the value of command, since the button clicks do this as part 
of the method. If that's not right, let me know.

I've added the options to the list and pushed the changes to the PR.

On 02/07/2018 03:21 PM, Serhiy Storchaka wrote:
> Serhiy Storchaka  added the comment:
>
> I have fixed tests on HiDPI displays. Two issues are left:
>
> 1. test_command still fails randomly. Seems adding update_idletasks() 
> invocation fixes this. And calling pack() looks redundant.
>
> 2. Following warnings are emitted:
>
> SpinboxTest.OPTIONS doesn't contain "exportselection"
> SpinboxTest.OPTIONS doesn't contain "font"
> SpinboxTest.OPTIONS doesn't contain "foreground"
>
> Just add these options to the list. Maybe conditionally if they are not 
> supported in 8.5.
>
> --
>
> ___
> Python tracker 
> 
> ___
>

--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue30825] csv.Sniffer does not detect lineterminator

2018-02-07 Thread Terry J. Reedy

Terry J. Reedy  added the comment:

While Sniffer *returns* a dialect with lineterminator = '\r\n', it *uses* '\n' 
for splitting.  This is slightly odd, as it leaves lines terminated by '\r' 
while detecting within-line parameters, but it does not affect such detection.

Are there csv files in the wild that use \r as line terminator.  If so, they 
will not currently get split.

--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue30825] csv.Sniffer does not detect lineterminator

2018-02-07 Thread Terry J. Reedy

Terry J. Reedy  added the comment:

Looking at the code and docstring, lineterminator was intentionally (knowingly) 
not sniffed, making this a feature addition.

--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue30825] csv.Sniffer does not detect lineterminator

2018-02-07 Thread Terry J. Reedy

Terry J. Reedy  added the comment:

The csv expert listed in https://devguide.python.org/experts/ is marked as 
inactive, and I have never used the module.  So you might need to ask for help 
on core-mentorship list.

The csv doc for Sniffer.sniff says "Analyze the given sample and return a 
Dialect subclass reflecting the parameters found."  It is not clear to me 
whether 'the parameters found' is meant to be all possible parameters or just 
those found.  So, to be conservative, I will initially treat this an a feature 
addition for the the next version, rather than a bug to also be fixed in 
current versions.  It does seem like a reasonable request.

--
nosy: +skip.montanaro, terry.reedy
type: behavior -> enhancement
versions: +Python 3.8 -Python 3.6

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue32585] Add ttk::spinbox to tkinter.ttk

2018-02-07 Thread Serhiy Storchaka

Serhiy Storchaka  added the comment:

I have fixed tests on HiDPI displays. Two issues are left:

1. test_command still fails randomly. Seems adding update_idletasks() 
invocation fixes this. And calling pack() looks redundant.

2. Following warnings are emitted:

SpinboxTest.OPTIONS doesn't contain "exportselection"
SpinboxTest.OPTIONS doesn't contain "font"
SpinboxTest.OPTIONS doesn't contain "foreground"

Just add these options to the list. Maybe conditionally if they are not 
supported in 8.5.

--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue32585] Add ttk::spinbox to tkinter.ttk

2018-02-07 Thread Serhiy Storchaka

Serhiy Storchaka  added the comment:

If set DPI to low value, the size of a spinbox widget (winfo_width(), 
winfo_height()) is (185, 20), and the test is passed. If set it to high value, 
the size is (305, 30), and the test is failed.

--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue32585] Add ttk::spinbox to tkinter.ttk

2018-02-07 Thread Serhiy Storchaka

Serhiy Storchaka  added the comment:

This is because of HiDPI display. Mouse events are generated with pixel 
coordinates (x=width - 5, y=5), but these coordinates are out of a button on 
scaled widget.

--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue31937] Add the term "dunder" to the glossary

2018-02-07 Thread Stéphane Wirtel

Stéphane Wirtel  added the comment:

David, 

I have no objection to closing this issue and I totally agree with your comment.

--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue32585] Add ttk::spinbox to tkinter.ttk

2018-02-07 Thread Serhiy Storchaka

Serhiy Storchaka  added the comment:

Tests that are failing on my computer:

==
FAIL: test_command (tkinter.test.test_ttk.test_widgets.SpinboxTest)
--
Traceback (most recent call last):
  File "/home/serhiy/py/cpython/Lib/tkinter/test/test_ttk/test_widgets.py", 
line 1145, in test_command
self.assertTrue(success)
AssertionError: [] is not true

==
FAIL: test_format (tkinter.test.test_ttk.test_widgets.SpinboxTest)
--
Traceback (most recent call last):
  File "/home/serhiy/py/cpython/Lib/tkinter/test/test_ttk/test_widgets.py", 
line 1199, in test_format
self.assertEqual(len(value), 10)
AssertionError: 1 != 10

==
FAIL: test_increment (tkinter.test.test_ttk.test_widgets.SpinboxTest)
--
Traceback (most recent call last):
  File "/home/serhiy/py/cpython/Lib/tkinter/test/test_ttk/test_widgets.py", 
line 1186, in test_increment
self.assertEqual(self.spin.get(), '5')
AssertionError: '1' != '5'
- 1
+ 5


==
FAIL: test_to (tkinter.test.test_ttk.test_widgets.SpinboxTest)
--
Traceback (most recent call last):
  File "/home/serhiy/py/cpython/Lib/tkinter/test/test_ttk/test_widgets.py", 
line 1163, in test_to
self.assertEqual(self.spin.get(), '5')
AssertionError: '4' != '5'
- 4
+ 5


==
FAIL: test_values (tkinter.test.test_ttk.test_widgets.SpinboxTest)
--
Traceback (most recent call last):
  File "/home/serhiy/py/cpython/Lib/tkinter/test/test_ttk/test_widgets.py", 
line 1248, in test_values
self.assertEqual(self.spin.get(), '1')
AssertionError: 'a' != '1'
- a
+ 1


==
FAIL: test_wrap (tkinter.test.test_ttk.test_widgets.SpinboxTest)
--
Traceback (most recent call last):
  File "/home/serhiy/py/cpython/Lib/tkinter/test/test_ttk/test_widgets.py", 
line 1220, in test_wrap
self.assertEqual(self.spin.get(), '1')
AssertionError: '10' != '1'
- 10
?  -
+ 1


--

This may be a race condition depended on window manager or speed of CPU or GPU.

--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue31937] Add the term "dunder" to the glossary

2018-02-07 Thread R. David Murray

R. David Murray  added the comment:

EAFP and BDFL are not python folk terminology (the former never was, the latter 
may have originated with us but it has widespread use).  They are also 
acronyms.  'dunder' is the phonetic spelling of a way of pronouncing 
punctuation.  Raymond's examples of 'stir' and 'repper' are similar: phonetic 
spellings of ways of pronouncing something that isn't a word.

It seems to me that such phonetic spellings do no belong in the glossary.  The 
counter argument is that unlike the other two 'dunder' does appear 
*occasionally* in text...but the only place it appears in our documentation 
(that I can find via grep) is in the enum docs, and there it should be replaced 
by the correct term "special methods", especially since it there it is spelled 
"__dunder__".

For 'stir' and 'repper' the text spelling is __str__/str and __repr__/repr, for 
'dunder XXX' the correct text spelling is the special method name, and for the 
"dunder method" the correct spelling (and I would argue the correct 
pronunciation :) is "special method".  That is, 'dunder' is mostly used in 
speech, not text.  It is not a "word" in the sense that the rest of the 
glossary entries are.
  
So, I vote with Raymond and others that this term does *not* belong in our 
glossary.

I recommend closing this issue as rejected.

--
nosy: +r.david.murray

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue32775] fnmatch.translate() can produce a pattern which emits a nested set warning

2018-02-07 Thread Serhiy Storchaka

Change by Serhiy Storchaka :


--
keywords: +patch
pull_requests: +5400
stage:  -> patch review

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue31937] Add the term "dunder" to the glossary

2018-02-07 Thread Stéphane Wirtel

Stéphane Wirtel  added the comment:

Just added the term in the glossary

If you want to review this PR, thank you

--
nosy: +matrixise

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue31937] Add the term "dunder" to the glossary

2018-02-07 Thread Stéphane Wirtel

Change by Stéphane Wirtel :


--
keywords: +patch
pull_requests: +5399
stage: needs patch -> patch review

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue32769] Add 'annotations' to the glossary

2018-02-07 Thread Stéphane Wirtel

New submission from Stéphane Wirtel :

There is a description of the annotation in the Glossary, but with 'function 
annotation'

maybe we could rename 'function annotation' by 'annotation'

--
nosy: +matrixise

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue32784] Wrong argument name for csv.DictReader in documentation

2018-02-07 Thread Mariatta Wijaya

Mariatta Wijaya  added the comment:

Thanks everyone!

--
resolution:  -> fixed
stage: patch review -> resolved
status: open -> closed

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue32784] Wrong argument name for csv.DictReader in documentation

2018-02-07 Thread Mariatta Wijaya

Mariatta Wijaya  added the comment:


New changeset 672fd7d8162f76aff8423fa5c7bfd2b1e91faf57 by Mariatta (Stéphane 
Wirtel) in branch '2.7':
bpo-32784: Wrong argument name for csv.DictReader in documentation (GH-5575)
https://github.com/python/cpython/commit/672fd7d8162f76aff8423fa5c7bfd2b1e91faf57


--
nosy: +Mariatta

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue32789] Note missing from logging.debug() docs

2018-02-07 Thread Pedro

Pedro  added the comment:

Might be cleaner to just say, "The arguments are interpreted as for 
debug/info/warning/error/critical/exception/log," but with the bookmark URL 
pointing to the Logger methods.

--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue32789] Note missing from logging.debug() docs

2018-02-07 Thread Pedro

New submission from Pedro :

The docs for Logger.debug() 
(https://docs.python.org/3/library/logging.html#logging.Logger.debug) specify 
that exc_info can take an exception instance as of version 3.5.

However, the docs for logging.debug() 
(https://docs.python.org/3/library/logging.html#logging.debug) do not, even 
though logging.debug() redirects to an instance of Logger and so can take the 
same types of arguments.

--
assignee: docs@python
components: Documentation
messages: 311792
nosy: docs@python, pgacv2
priority: normal
severity: normal
status: open
title: Note missing from logging.debug() docs
type: enhancement
versions: Python 3.5, Python 3.6, Python 3.7, Python 3.8

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue32767] Mutating a list while iterating: clarify the docs

2018-02-07 Thread Stefan Pochmann

Stefan Pochmann  added the comment:

And `bytearray`.

--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue32783] ln(2) isn't accurate in _math.c in cpython

2018-02-07 Thread Mark Dickinson

Mark Dickinson  added the comment:

Closing. There's no actual bug here.

--
resolution:  -> not a bug
stage: needs patch -> resolved
status: open -> closed

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue32783] ln(2) isn't accurate in _math.c in cpython

2018-02-07 Thread Mark Dickinson

Mark Dickinson  added the comment:

> I'm inclined to just close this as "not a bug".

Sounds good to me.

The ideal would probably be to use a hex literal here. They're part of C99 (see 
section 6.4.4.2), but last time I checked Visual Studio didn't support them. I 
don't know whether that's changed recently.

--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue32784] Wrong argument name for csv.DictReader in documentation

2018-02-07 Thread Stéphane Wirtel

Stéphane Wirtel  added the comment:

Hi David, 

At the final, I didn't propose my PR with the renaming. because PyPy and 
CPython use f as the first parameter of these classes.

If @Serhiy does the review of my PR, we can close this issue.

--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue32788] Better error handling in sqlite3

2018-02-07 Thread Serhiy Storchaka

New submission from Serhiy Storchaka :

The proposed patch makes unexpected errors raised when look up an attribute or 
a key in a dict (like MemoryError, KeyboardInterrupt, etc) be leaked to a user 
instead of be overridden by TypeError or AttributeError.

--
components: Extension Modules
messages: 311786
nosy: ghaering, serhiy.storchaka
priority: normal
severity: normal
stage: patch review
status: open
title: Better error handling in sqlite3
type: enhancement
versions: Python 3.8

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue32784] Wrong argument name for csv.DictReader in documentation

2018-02-07 Thread R. David Murray

R. David Murray  added the comment:

Stéphane: I don't understand your question about changing the name of the 
parameter.  As far as I can see the only thing to do here is backport the doc 
fix to 2.7.

--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue31572] Avoid suppressing all exceptions in PyObject_HasAttr()

2018-02-07 Thread Serhiy Storchaka

Change by Serhiy Storchaka :


--
dependencies: +Better error handling in ctypes, Better error handling in sqlite3

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue32788] Better error handling in sqlite3

2018-02-07 Thread Serhiy Storchaka

Change by Serhiy Storchaka :


--
keywords: +patch
pull_requests: +5398

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue32787] Better error handling in ctypes

2018-02-07 Thread Serhiy Storchaka

Change by Serhiy Storchaka :


--
nosy: +amaury.forgeotdarc, belopolsky, meador.inge

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue32787] Better error handling in ctypes

2018-02-07 Thread Serhiy Storchaka

Change by Serhiy Storchaka :


--
keywords: +patch
pull_requests: +5397

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue32787] Better error handling in ctypes

2018-02-07 Thread Serhiy Storchaka

New submission from Serhiy Storchaka :

The proposed patch makes unexpected errors raised when look up an attribute or 
a key in a dict (like MemoryError, KeyboardInterrupt, etc) be leaked to a user 
instead of be overridden by TypeError or AttributeError.

--
components: Extension Modules, ctypes
messages: 311785
nosy: serhiy.storchaka
priority: normal
severity: normal
stage: patch review
status: open
title: Better error handling in ctypes
type: enhancement
versions: Python 3.8

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue32786] Didnot work strftime() when hangeul in format sting

2018-02-07 Thread Larry Hastings

Larry Hastings  added the comment:

This is not an Argument Clinic problem.

--
components: +Library (Lib) -Argument Clinic

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue1100942] Add datetime.time.strptime and datetime.date.strptime

2018-02-07 Thread Stéphane Wirtel

Stéphane Wirtel  added the comment:

I have updated the patch for 3.8, create a PR and fixed the documentation of 
_strptime._strptime, because this function returns a 3-tuple and not a 2-tuple 
as indicated in its comment. 

Thank you

--
versions: +Python 3.8 -Python 3.7

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue16202] sys.path[0] security issues

2018-02-07 Thread Thomas Arendsen Hein

Thomas Arendsen Hein  added the comment:

I just stumbled across this problem when starting "idle3" in a directory 
containing a copy of textwrap.py which was not compatible with python3.

In issue13506 idle3 was changed to behave like the regular python shell, i.e. 
as described here in this issue, and since my ~/.pythonrc.py imports readline, 
I could reproduce this problem by creating a bogus readline.py file and 
starting a python interpreter.

So besides being a security issue when starting python or idle in untrusted 
directories, it may cause technical issues when working in directories 
containing .py files with certain names.

--
nosy: +ThomasAH

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue1100942] Add datetime.time.strptime and datetime.date.strptime

2018-02-07 Thread Stéphane Wirtel

Change by Stéphane Wirtel :


--
pull_requests: +5396

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue29248] os.readlink fails on Windows

2018-02-07 Thread SSE4

SSE4  added the comment:

opened PR https://github.com/python/cpython/pull/5577

--
nosy: +SSE4

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue32616] Significant performance problems with Python 2.7 built with clang 3.x or 4.x

2018-02-07 Thread INADA Naoki

INADA Naoki  added the comment:


New changeset 2942b909d9a428e6683d90b3436cfa4a81bd5d8a by INADA Naoki in branch 
'2.7':
bpo-32616: Disable computed gotos by default for clang < 5 (GH-5574)
https://github.com/python/cpython/commit/2942b909d9a428e6683d90b3436cfa4a81bd5d8a


--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue29248] os.readlink fails on Windows

2018-02-07 Thread Roundup Robot

Change by Roundup Robot :


--
pull_requests: +5395

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue32786] Didnot work strftime() when hangeul in format sting

2018-02-07 Thread Stéphane Wirtel

Stéphane Wirtel  added the comment:

Thank you for your contribution,

Just one question, do you have the same issue with Python 3.6 because
Python 3.4 is a security release, Python 3.6 is a bugfix release.

Thank you,

--
nosy: +matrixise

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue32781] lzh_tw is missing in locale.py

2018-02-07 Thread Po-Hsu Lin

Po-Hsu Lin  added the comment:

Yes I think you are right, 
return None sounds like a good approach to me as we might have zh_TW translated 
but not lzh_TW.

--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue32751] wait_for(future, ...) should wait for the future (even if a timeout occurs)

2018-02-07 Thread Andrew Svetlov

Andrew Svetlov  added the comment:

Theoretically we can start monitoring cancelled tasks and report about them if 
the task is still not finished, say, in a minute or two.
It is a new feature, sure.

I'm fine with waiting for cancelled task in wait_for().

--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue32751] wait_for(future, ...) should wait for the future (even if a timeout occurs)

2018-02-07 Thread Nathaniel Smith

Nathaniel Smith  added the comment:

How do you tell the difference between a cancelled task that's about to exit, 
and one that will never exit?

--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue31961] subprocess._execute_child doesn't accept a single PathLike argument for args

2018-02-07 Thread Eryk Sun

Eryk Sun  added the comment:

If a PathLike args value is supported in Windows, then it must be processed 
through list2cmdline, in case it needs to be quoted. Also, the preferred usage 
is to pass args as a list when shell is false. This common case shouldn't be 
penalized as a TypeError. Also, passing `executable` as PathLike should be 
supported, as is already the case in the POSIX implementation. For example.

_execute_child:

if executable is not None and not isinstance(executable, str):
executable = os.fsdecode(executable)

if not isinstance(args, str):
try:
args = list2cmdline(args)
except TypeError:
if isinstance(args, bytes):
args = os.fsdecode(args)
elif isinstance(args, os.PathLike):
args = list2cmdline([args])
else:
raise

list2cmdline should support PathLike arguments via os.fsdecode. This removes an 
existing inconsistency since the POSIX implementation converts args via 
PyUnicode_FSConverter in Modules/_posixsubprocess.c. For example:

list2cmdline:

for arg in seq:
if not isinstance(arg, str):
arg = os.fsdecode(arg)

Finally, passing args as a string when shell is false can never be deprecated 
on Windows. list2cmdline works in most cases, but Windows CreateProcess takes a 
command line, and applications are free to parse the command line however they 
want. IMHO, the case that should be deprecated is passing args as a 
list/sequence when shell is true.

--
nosy: +eryksun

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue32394] socket lib beahavior change in 3.6.4

2018-02-07 Thread Andrew Svetlov

Andrew Svetlov  added the comment:

Ok

--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue32751] wait_for(future, ...) should wait for the future (even if a timeout occurs)

2018-02-07 Thread Andrew Svetlov

Andrew Svetlov  added the comment:

Agree.
Should we report about cancelled but still executing tasks?
It would be a nice feature.
I'm talking not about `wait_for` only but task cancellation in general.

--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com