[issue35643] SyntaxWarning: invalid escape sequence in Modules/_sha3/cleanup.py

2019-01-06 Thread Benjamin Peterson


Benjamin Peterson  added the comment:


New changeset 3e0144a6c95433f347bb7e44a98c84deae8853ff by Benjamin Peterson 
(Miss Islington (bot)) in branch '3.6':
closes bpo-35643: Fix a SyntaxWarning: invalid escape sequence in 
Modules/_sha3/cleanup.py (GH-11413)
https://github.com/python/cpython/commit/3e0144a6c95433f347bb7e44a98c84deae8853ff


--

___
Python tracker 

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



[issue35676] class TestCase: docs are not correct

2019-01-06 Thread אורי רודברג

Change by אורי רודברג :


--
versions: +Python 3.4, Python 3.8

___
Python tracker 

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



[issue35668] Improve test coverage for idlelib

2019-01-06 Thread Terry J. Reedy


Terry J. Reedy  added the comment:

I like having multiple commits with explanatory messages.  They get squashed 
when merging into master.  Unless I get distracted and forget, I will squash 
the messages.

--

___
Python tracker 

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



[issue35676] class TestCase: docs are not correct

2019-01-06 Thread אורי רודברג

אורי רודברג  added the comment:

1. I think the main problem is where it's documented "first, second" while the 
real argument names are different.

2. I think maybe https://docs.python.org/2.7/library/unittest.html is also 
affected in functions such as:

assertGreater(first, second, msg=None)
assertGreaterEqual(first, second, msg=None)
assertLess(first, second, msg=None)
assertLessEqual(first, second, msg=None)

--
versions: +Python 2.7

___
Python tracker 

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



[issue35676] class TestCase: docs are not correct

2019-01-06 Thread אורי רודברג

New submission from אורי רודברג :

I think some functions of `class TestCase` are not documented correctly in the 
docs. For example in https://docs.python.org/3.5/library/unittest.html and also 
https://docs.python.org/3.6/library/unittest.html and 
https://docs.python.org/3.7/library/unittest.html.

Some of the functions which are not documented correctly:

assertListEqual
assertSetEqual
assertDictEqual
assertIsNone

And many other functions.

You can see some more details on https://github.com/python/typeshed/issues/2716.

--
assignee: docs@python
components: Documentation
messages: 333137
nosy: docs@python, אורי רודברג
priority: normal
severity: normal
status: open
title: class TestCase: docs are not correct
versions: Python 3.5, Python 3.6, Python 3.7

___
Python tracker 

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



[issue35668] Improve test coverage for idlelib

2019-01-06 Thread Terry J. Reedy


Change by Terry J. Reedy :


--
pull_requests:  -10914

___
Python tracker 

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



[issue35668] Improve test coverage for idlelib

2019-01-06 Thread Terry J. Reedy


Change by Terry J. Reedy :


--
pull_requests:  -10915

___
Python tracker 

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



[issue35668] Improve test coverage for idlelib

2019-01-06 Thread Terry J. Reedy


Change by Terry J. Reedy :


--
pull_requests:  -10916

___
Python tracker 

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



[issue35598] IDLE: Modernize config_key module

2019-01-06 Thread Terry J. Reedy


Terry J. Reedy  added the comment:

I moved PR 11427 to new issue #35675.

--
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



[issue35675] IDLE: Refactor config_key module.

2019-01-06 Thread Cheryl Sabella


Change by Cheryl Sabella :


--
keywords: +patch
pull_requests: +10920

___
Python tracker 

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



[issue33084] Computing median, median_high an median_low in statistics library

2019-01-06 Thread David Mertz


David Mertz  added the comment:

I believe that the current behavior of `statistics.median[|_low|_high\]` is 
simply broken.  It relies on the particular behavior of Python sorting, which 
only utilizes `.__lt__()` between objects, and hence does not require a total 
order.

I can think of absolutely no way to characterize these as reasonable results:

Python 3.7.1 | packaged by conda-forge | (default, Nov 13 2018, 09:50:42)
>>> statistics.median([9, 9, 9, nan, 1, 2, 3, 4, 5])
1
>>> statistics.median([9, 9, 9, nan, 1, 2, 3, 4])
nan

--
nosy: +David Mertz

___
Python tracker 

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



[issue35675] IDLE: Refactor config_key module.

2019-01-06 Thread Terry J. Reedy


New submission from Terry J. Reedy :

Continuation of #35598.  Cheryl said there (rearranged):
"PR11427 refactors the main frame from the window.  My main goal in splitting 
them was more for readability rather than for being able to add it to a Tabbed 
window.  As a follow up to this refactor, I hope to split the Basic and 
Advanced frames into their own tabs, mostly to clean up the create_widgets and 
to organize the supporting functions."


A pair of tabs on a ttk Notebook would make this more like configdialog.

--
messages: 333134
nosy: cheryl.sabella, terry.reedy
priority: normal
severity: normal
stage: patch review
status: open
title: IDLE: Refactor config_key module.
type: enhancement
versions: 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



[issue29515] socket module missing IPPROTO_IPV6, IPPROTO_IPV4 on Windows

2019-01-06 Thread Andrew Brezovsky


Andrew Brezovsky  added the comment:

Can confirm this is still a problem in latest versions of 3.5, 3.6, and 3.7

Any progress made on this?

--
nosy: +abrezovsky

___
Python tracker 

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



[issue35530] Counter-intuitive logging API

2019-01-06 Thread Vinay Sajip


Change by Vinay Sajip :


--
resolution:  -> not a bug
stage:  -> 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



[issue34439] Expose venv --prompt value to an environment value

2019-01-06 Thread Vinay Sajip


Vinay Sajip  added the comment:

Duplicate of bpo-35328, which has a PR.

--
nosy: +vinay.sajip
resolution:  -> duplicate
stage:  -> 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



[issue35537] use os.posix_spawn in subprocess

2019-01-06 Thread STINNER Victor


STINNER Victor  added the comment:

I created bpo-35674: "Expose os.posix_spawnp()" to later support executable 
with no directory in subprocess.

--

___
Python tracker 

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



[issue20104] expose posix_spawn(p)

2019-01-06 Thread STINNER Victor


STINNER Victor  added the comment:

Serhiy:
> And os.posix_spawnp() still is not implemented.

I created bpo-35674 to see how to expose this feature.

--

___
Python tracker 

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



[issue35674] Expose os.posix_spawnp()

2019-01-06 Thread STINNER Victor


STINNER Victor  added the comment:

Historically, Python used to mimick the libc: there are os.stat() and 
os.lstat() for example. But later, os.stat(*, follow_symlinks=False) 
keyword-only parameter has been added: if true, lstat() is used internally.

--

___
Python tracker 

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



[issue35674] Expose os.posix_spawnp()

2019-01-06 Thread STINNER Victor


New submission from STINNER Victor :

bpo-20104 exposed os.posix_spawn(), but not os.posix_spawnp().

os.posix_spawnp() would be useful to support executable with no directory. See 
bpo-35537 "use os.posix_spawn in subprocess".

I'm not sure what is the best API:

* Add os.posix_spawnp()? duplicate the documentation and some parts of the C 
code (but share most of the C code)
* Add a new optional parameter to os.posix_spawn()? Ideas of names: 'use_path' 
or 'search_executable'. Internally, the glibc uses SPAWN_XFLAGS_USE_PATH flag 
to distinguish posix_spawn() and posix_spawnp().

execvp() uses the PATH environment variable, or use confstr(_CS_PATH) if PATH 
is not set. I guess that posix_spawnp() also uses confstr(_CS_PATH) if PATH is 
not set.

Currently, my favorite option is to add a new optional 'use_path' parameter to 
the existing os.posix_spawn() function.

--
components: Interpreter Core
messages: 333128
nosy: pablogsal, serhiy.storchaka, vstinner
priority: normal
severity: normal
status: open
title: Expose os.posix_spawnp()
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



[issue35537] use os.posix_spawn in subprocess

2019-01-06 Thread STINNER Victor


STINNER Victor  added the comment:

"The native spawn(2) system introduced in Oracle Solaris 11.4 shares a lot of 
code with the forkx(2) and execve(2)."
https://blogs.oracle.com/solaris/posix_spawn-as-an-actual-system-call

--

___
Python tracker 

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



[issue35537] use os.posix_spawn in subprocess

2019-01-06 Thread STINNER Victor


STINNER Victor  added the comment:

I wrote PR 11452 which is based on PR 11242 but adds support for 'env' and 
'restore_signals' parameters and checks the operating system and libc version 
to decide if posix_spawn() can be used by subprocess.

In my implementation, posix_spawn() is only used on macOS and glibc 2.26 or 
newer (and glibc 2.24 and newer on Linux).

According to Alexey Izbyshev, musl should be safe as well, but I don't know how 
to test musl on my Fedora, nor how to check if Python is linked to musl, nor 
what is the minimum musl version which is safe.

--

___
Python tracker 

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



[issue35537] use os.posix_spawn in subprocess

2019-01-06 Thread STINNER Victor


Change by STINNER Victor :


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

___
Python tracker 

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



[issue35537] use os.posix_spawn in subprocess

2019-01-06 Thread STINNER Victor


Change by STINNER Victor :


--
keywords: +patch, patch, patch
pull_requests: +10917, 10918, 10919
stage:  -> patch review

___
Python tracker 

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



[issue35667] activate for venv containing apostrophe doesn't work in powershell

2019-01-06 Thread Eryk Sun


Eryk Sun  added the comment:

> I am not sure about the difference in semantics between powershell and 
> command prompt with respect to quoting since

CMD only uses single quotes in `for /f` loops, in which it's either a command 
or a literal string (w/ the "usebackq" option). This is not a problem in 
activate.bat. 

Double quotes in file names generally shouldn't be a problem in Windows. As far 
as I know, only the named-pipe file system allows them in pipe-file names (e.g. 
r'\\?\pipe\"pipename"'), and for regular files they're allowed in stream names 
(e.g. 'filename:"streamname"'). Otherwise, double quote should be reserved in 
file names as the DOS_DOT wildcard character.

--
nosy: +eryksun

___
Python tracker 

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



[issue35537] use os.posix_spawn in subprocess

2019-01-06 Thread STINNER Victor


Change by STINNER Victor :


--
keywords: +patch, patch
pull_requests: +10917, 10918
stage:  -> patch review

___
Python tracker 

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



[issue35668] Improve test coverage for idlelib

2019-01-06 Thread anthony shaw


Change by anthony shaw :


--
keywords: +patch, patch, patch
pull_requests: +10913, 10914, 10916
stage:  -> patch review

___
Python tracker 

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



[issue35668] Improve test coverage for idlelib

2019-01-06 Thread anthony shaw


Change by anthony shaw :


--
keywords: +patch, patch, patch, patch
pull_requests: +10913, 10914, 10915, 10916
stage:  -> patch review

___
Python tracker 

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



[issue35668] Improve test coverage for idlelib

2019-01-06 Thread anthony shaw


Change by anthony shaw :


--
keywords: +patch, patch
pull_requests: +10913, 10914
stage:  -> patch review

___
Python tracker 

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



[issue35668] Improve test coverage for idlelib

2019-01-06 Thread anthony shaw


Change by anthony shaw :


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

___
Python tracker 

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



[issue35668] Improve test coverage for idlelib

2019-01-06 Thread anthony shaw


anthony shaw  added the comment:

thanks Cheryl,

here's my branch https://github.com/tonybaloney/cpython/tree/idlelib_tests

I've already seen some code which is 17 years old!

--

___
Python tracker 

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



[issue35537] use os.posix_spawn in subprocess

2019-01-06 Thread STINNER Victor

STINNER Victor  added the comment:

Gregory:
> Thanks for all your research and reference links on this!  As a 
> _posixsubprocess maintainer, I am not against either posix_spawn or vfork 
> being used directly in the future when feasible.

Are you against using posix_spawn() in subprocess? Or only in _posixsubprocess?

--

Alexey Izbyshev identified a difference between _posixsubprocess and 
posix_spawn() PR 11242: error handling depends a lot on the libc implementation.
https://github.com/python/cpython/pull/11242#issuecomment-449478778

* On recent glibc, posix_spawn() fails (non-zero return value) and set errno to 
ENOENT if the executed program doesn't exist... but not all platforms have this 
behavior.
* On FreeBSD, if setting posix_spawn() "attributes" or execute posix_spawn() 
"file actions" fails, posix_spawn() succeed but the child process exits 
immediately with exit code 127 without trying to call execv(). If execv() 
fails, posix_spawn() succeed, but the child process exit with exit code 127.
* The worst seems to be: "In my test on Ubuntu 14.04, ./python -c "import 
subprocess; subprocess.call(['/xxx'], close_fds=False, restore_signals=False)" 
silently returns with zero exit code."

execv() can fail for a lot of different reasons. Extract of Linux execve() 
manual page:
---
   E2BIG  The total number of bytes in the environment (envp) and argument 
list (argv) is too large.

   EACCES Search permission is denied on a component of the path prefix of 
filename or the name of a script interpreter.  (See also
  path_resolution(7).)

   EACCES The file or a script interpreter is not a regular file.

   EACCES Execute permission is denied for the file or a script or ELF 
interpreter.

   EACCES The filesystem is mounted noexec.

   EAGAIN (since Linux 3.1)
  Having  changed  its  real  UID  using one of the set*uid() 
calls, the caller was—and is now still—above its RLIMIT_NPROC
  resource limit (see setrlimit(2)).  For a more detailed 
explanation of this error, see NOTES.

   EFAULT filename or one of the pointers in the vectors argv or envp 
points outside your accessible address space.

   EINVAL An ELF executable had more than one PT_INTERP segment (i.e., 
tried to name more than one interpreter).

   EIOAn I/O error occurred.

   EISDIR An ELF interpreter was a directory.

   ELIBBAD
  An ELF interpreter was not in a recognized format.

   ELOOP  Too many symbolic links were encountered in resolving filename or 
the name of a script or ELF interpreter.

   ELOOP  The maximum recursion limit was reached during  recursive  script 
 interpretation  (see  "Interpreter  scripts",  above).
  Before Linux 3.8, the error produced for this case was ENOEXEC.

   EMFILE The per-process limit on the number of open file descriptors has 
been reached.

   ENAMETOOLONG
  filename is too long.

   ENFILE The system-wide limit on the total number of open files has been 
reached.

   ENOENT The  file  filename or a script or ELF interpreter does not 
exist, or a shared library needed for the file or interpreter
  cannot be found.

   ENOEXEC
  An executable is not in a recognized format, is for the wrong 
architecture, or has some other format error that means  it
  cannot be executed.

   ENOMEM Insufficient kernel memory was available.

   ENOTDIR
  A component of the path prefix of filename or a script or ELF 
interpreter is not a directory.

   EPERM  The  filesystem  is  mounted  nosuid, the user is not the 
superuser, and the file has the set-user-ID or set-group-ID bit
  set.

   EPERM  The process is being traced, the user is not the superuser and 
the file has the set-user-ID or set-group-ID bit set.

   EPERM  A "capability-dumb" applications would not obtain the full set of 
permitted capabilities granted by the executable  file.
  See capabilities(7).

   ETXTBSY
  The specified executable was open for writing by one or more 
processes.
---

Simply exit with exit code 127 (FreeBSD behavior) doesn't allow to know if the 
program have been executed or not.

For example, "git bisect run" depends on the exit code: exit code 127 means 
"command not found". But with posix_spawn(), exit code 127 can means something 
else...

I'm disappointed by the qualify of the posix_spawn() implementation on FreeBSD 
and old glibc...

--

I'm now confused.

Should we still use posix_spawn() on some platforms? For example, posix_spawn() 
seems to have a well defined error reporting according to its manual page:
https://developer.apple.com/library/archive/documentation/System/Conceptual/ManPages_iPhoneOS/man2/posix_spawn.2.html

"""
RETURN VALUES
 If the pid argument is NULL, no pid is returned to the calling process;
 if it is non-NULL, then posix_spawn() and 

[issue35673] Loader for namespace packages

2019-01-06 Thread Barry A. Warsaw


Barry A. Warsaw  added the comment:

On the first point, I'd categorize this as a documentation bug, and in fact, 
it's inconsistent with the language reference, which doesn't have the same 
language:

https://docs.python.org/3/reference/import.html#__loader__

On the second point, it probably does make sense to register the ABC.

--

___
Python tracker 

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



[issue35673] Loader for namespace packages

2019-01-06 Thread Barry A. Warsaw


Change by Barry A. Warsaw :


--
nosy: +barry

___
Python tracker 

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



[issue35671] reserved identifier violation

2019-01-06 Thread STINNER Victor


STINNER Victor  added the comment:

Hi, I'm sorry but I don't understand your problem. Are you trying to build 
Python using C++? If yes, do you get a compilation error? I'm not sure that 
it's supported.

Or do you try to build a C extension for Python using a C++ compiler?

--

___
Python tracker 

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



[issue35660] IDLE: Fix imports in window.py

2019-01-06 Thread Terry J. Reedy


Change by Terry J. Reedy :


--
nosy:  -miss-islington
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



[issue35660] IDLE: Fix imports in window.py

2019-01-06 Thread miss-islington


miss-islington  added the comment:


New changeset be37dbff1ce3fa2ddd9115352b31ac0f6b44c193 by Miss Islington (bot) 
in branch '3.7':
bpo-35660: Fix imports in idlelib.window (GH-11434)
https://github.com/python/cpython/commit/be37dbff1ce3fa2ddd9115352b31ac0f6b44c193


--
nosy: +miss-islington

___
Python tracker 

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



[issue35660] IDLE: Fix imports in window.py

2019-01-06 Thread miss-islington


Change by miss-islington :


--
pull_requests: +10909, 10910, 10911, 10912

___
Python tracker 

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



[issue35660] IDLE: Fix imports in window.py

2019-01-06 Thread miss-islington


Change by miss-islington :


--
pull_requests: +10909

___
Python tracker 

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



[issue35660] IDLE: Fix imports in window.py

2019-01-06 Thread miss-islington


Change by miss-islington :


--
pull_requests: +10909, 10910

___
Python tracker 

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



[issue35660] IDLE: Fix imports in window.py

2019-01-06 Thread miss-islington


Change by miss-islington :


--
pull_requests: +10909, 10910, 10912

___
Python tracker 

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



[issue35660] IDLE: Fix imports in window.py

2019-01-06 Thread Terry J. Reedy


Terry J. Reedy  added the comment:


New changeset 11303dd6035a7d7f78025ce5a3e3b9bdf7380c9a by Terry Jan Reedy 
(Cheryl Sabella) in branch 'master':
bpo-35660: Fix imports in idlelib.window (#11434)
https://github.com/python/cpython/commit/11303dd6035a7d7f78025ce5a3e3b9bdf7380c9a


--

___
Python tracker 

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



[issue35660] IDLE: Fix imports in window.py

2019-01-06 Thread Terry J. Reedy


Change by Terry J. Reedy :


--
title: IDLE: Remove import * from window.py -> IDLE: Fix imports in window.py

___
Python tracker 

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



[issue35670] os functions return '??' for unicode characters in paths on windows

2019-01-06 Thread Steve Dower


Steve Dower  added the comment:

To be more clear, the fix is literally Python 3 and the str/bytes change. 
You've discovered one of the reasons that was necessary.

--

___
Python tracker 

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



[issue35488] pathlib Path.match does not behave as described

2019-01-06 Thread Brett Cannon


Brett Cannon  added the comment:


New changeset 83da926b89daf80013ea966037c2c0e1e9d25c6b by Brett Cannon (Anthony 
Shaw) in branch 'master':
bpo-35488: Add tests for ** glob matching in pathlib (GH-11171)
https://github.com/python/cpython/commit/83da926b89daf80013ea966037c2c0e1e9d25c6b


--

___
Python tracker 

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



[issue12707] Deprecate addinfourl getters

2019-01-06 Thread Ashwin Ramaswami


Change by Ashwin Ramaswami :


--
keywords: +patch, patch, patch, patch
pull_requests: +10905, 10906, 10907, 10908
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



[issue12707] Deprecate addinfourl getters

2019-01-06 Thread Ashwin Ramaswami


Change by Ashwin Ramaswami :


--
keywords: +patch, patch, patch
pull_requests: +10905, 10906, 10908
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



[issue12707] Deprecate addinfourl getters

2019-01-06 Thread Ashwin Ramaswami


Change by Ashwin Ramaswami :


--
keywords: +patch, patch
pull_requests: +10905, 10906
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



[issue12707] Deprecate addinfourl getters

2019-01-06 Thread Ashwin Ramaswami


Change by Ashwin Ramaswami :


--
keywords: +patch
pull_requests: +10905
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



[issue35582] Argument Clinic: inline parsing code for functions with only positional parameters

2019-01-06 Thread Raymond Hettinger


Change by Raymond Hettinger :


--
pull_requests: +10903, 10904

___
Python tracker 

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



[issue35582] Argument Clinic: inline parsing code for functions with only positional parameters

2019-01-06 Thread Raymond Hettinger


Change by Raymond Hettinger :


--
pull_requests: +10903

___
Python tracker 

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



[issue35667] activate for venv containing apostrophe doesn't work in powershell

2019-01-06 Thread Karthikeyan Singaravelan


Karthikeyan Singaravelan  added the comment:

>From the error I think the quotes are not properly escaped while doing text 
>replacement in venv activate file template at [0] while it's generated? On 
>linux/Mac double quotes are used and hence the error is not triggered with 
>single quote in virtualenv name. Using double quote in virtualenv name 
>triggers the parse error.

$  python3.7 -m venv py37\"-bpo-35667-venv
$  source py37\"-bpo-35667-venv/bin/activate
py37"-bpo-35667-venv/bin/activate:57: parse error near `then'

Looking into the py37\"-bpo-35667-venv/bin/activate script there is below line 
where the double quote is unbalanced : 

if [ "x(py37"-bpo-35667-venv) " != x ] ; then
PS1="(py37"-bpo-35667-venv) ${PS1:-}"
else

I tried escaping the quotes with backslash at [0] but I get a similar error. I 
guess it's similar case in Powershell as I can see from Activate.ps1 but I 
haven't tested it. I am not sure about the difference in semantics between 
powershell and command prompt with respect to quoting since I don't have access 
to Windows.

py37\'-bpo-35667-venv/bin/Activate.ps1 file with unbalanced quote

function global:prompt {
Write-Host -NoNewline -ForegroundColor Green '(py37'-bpo-35667-venv) '
_OLD_VIRTUAL_PROMPT
}


[0] 
https://github.com/python/cpython/blob/a5b76167dedf4d15211a216c3ca7b98e3cec33b8/Lib/venv/__init__.py#L280

--
nosy: +vinay.sajip, xtreak

___
Python tracker 

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



[issue35671] reserved identifier violation

2019-01-06 Thread Raymond Hettinger


Change by Raymond Hettinger :


--
nosy: +vstinner

___
Python tracker 

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



[issue35551] Encoding and alias issues

2019-01-06 Thread Ashwin Ramaswami


Change by Ashwin Ramaswami :


--
keywords: +patch, patch, patch, patch
pull_requests: +10899, 10900, 10901, 10902
stage:  -> patch review

___
Python tracker 

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



[issue35551] Encoding and alias issues

2019-01-06 Thread Ashwin Ramaswami


Change by Ashwin Ramaswami :


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

___
Python tracker 

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



[issue35551] Encoding and alias issues

2019-01-06 Thread Ashwin Ramaswami


Change by Ashwin Ramaswami :


--
keywords: +patch, patch
pull_requests: +10899, 10900
stage:  -> patch review

___
Python tracker 

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



[issue35551] Encoding and alias issues

2019-01-06 Thread Ashwin Ramaswami


Change by Ashwin Ramaswami :


--
keywords: +patch, patch, patch
pull_requests: +10899, 10900, 10902
stage:  -> patch review

___
Python tracker 

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



[issue35551] Encoding and alias issues

2019-01-06 Thread Ashwin Ramaswami


Ashwin Ramaswami  added the comment:

"iso8859_1" is already an alias for "latin_1", though. 
https://github.com/python/cpython/blob/master/Lib/encodings/aliases.py#L432

--
nosy: +epicfaace

___
Python tracker 

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



[issue30487] DOC: automatically create a venv and install Sphinx when running make

2019-01-06 Thread Ned Deily


Change by Ned Deily :


--
resolution:  -> rejected
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



[issue4696] email module does not unfold headers

2019-01-06 Thread R. David Murray


R. David Murray  added the comment:

The new email API is no longer provisional.  It isn't the *default* yet, but it 
isn't provisional.  So yes, this is resolved.

Cheryl, if you see places in the current docs that still say provisional, 
please open an issue to remove those.

--
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



[issue35625] Comprehension doc doesn't mention buggy class scope behavior

2019-01-06 Thread R. David Murray


Change by R. David Murray :


Removed file: https://bugs.python.org/file48026/keyfile.png

___
Python tracker 

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



[issue35625] Comprehension doc doesn't mention buggy class scope behavior

2019-01-06 Thread R. David Murray


Change by R. David Murray :


--
components:  -email
nosy:  -barry, r.david.murray
type: security -> behavior

___
Python tracker 

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



[issue35668] Improve test coverage for idlelib

2019-01-06 Thread Cheryl Sabella


Cheryl Sabella  added the comment:

Welcome Anthony!

Please ask me any questions you may have.  My only suggestion at this point 
would be for you to feel free to add any docstrings/comments to the module as 
you go.  Having the docstrings really helps in understanding the tests and vice 
versa.

--

___
Python tracker 

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



[issue35672] Error on divide

2019-01-06 Thread Steven D'Aprano


Steven D'Aprano  added the comment:

There is no need to call int() on a literal int: 103 is already an int, 
calling int() on it is just wasting time and making confusing code.

print (int(y1y2y3y4))

gives a NameError, since you don't have a variable "y1y2y3y4" defined. Please 
don't retype your example code from memory, make sure it works and then copy 
and paste code we can actually run.

I think we can simplify your example to this:

x = 1000112004278059472142857
y = 103
print(x/y)
print(int(x/y))


which correctly prints 

1.0001090039510477e+18
1000109003951047619

as the division operator uses floating point division in Python 3. Use the 
floor-division operator // to duplicate the Python 2 behaviour for ints.

Closing this as not a bug.

--
nosy: +steven.daprano
resolution:  -> not a bug
stage:  -> 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



[issue35673] Loader for namespace packages

2019-01-06 Thread Ronald Oussoren


New submission from Ronald Oussoren :

The documentation for import lib.machinery.ModuleSpec says that the attribute 
"loader" should be None for namespace packages (see 
)

In reality the loader for namespace packages is an instance of a private class, 
and that class does not conform to the importlib.abc.Loader ABC.

To reproduce:

* Create and empty directory "namespace"
* (Optionally) create an empty "module.py" in that directory
* Start a python shell and follow along:

Python 3.7.2 (v3.7.2:9a3ffc0492, Dec 24 2018, 02:44:43) 
[Clang 6.0 (clang-600.0.57)] on darwin
Type "help", "copyright", "credits" or "license" for more information.
>>> import namespace
>>> namespace.__loader__
<_frozen_importlib_external._NamespaceLoader object at 0x104c7bdd8>
>>> import importlib.abc
>>> isinstance(namespace.__loader__, importlib.abc.Loader)
False
>>> import importlib.util
>>> importlib.util.find_spec('namespace')
ModuleSpec(name='namespace', 
loader=<_frozen_importlib_external._NamespaceLoader object at 0x104c7bdd8>, 
submodule_search_locations=_NamespacePath(['/Users/ronald/Projects/pyobjc-hg/modulegraph2/namespace']))

Note how "namespace" has an attribute named "__loader__" that is not None, and 
the same is true for the ModuleSpec found using importlib.util.find_spec.  The 
loader does not claim to conform to any Loader ABC (but provides all methods 
required for conformance to the InspectLoader ABC)

I'm not sure if this should be two issues:

1) Documentation doesn't match behaviour

2) The loader for namespace packages isn't registered with the relevant ABCs

P.S. the latter is also true for zipimport.zipimporter.

--
components: Library (Lib)
messages: 333111
nosy: brett.cannon, ronaldoussoren
priority: normal
severity: normal
status: open
title: Loader for namespace packages
type: behavior
versions: 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



[issue35672] Error on divide

2019-01-06 Thread Jorge Teran

Jorge Teran  added the comment:

Thanks

El dom., 6 de ene. de 2019 08:53, Yash Aggarwal 
escribió:

>
> Yash Aggarwal  added the comment:
>
> @Jorge Teran
> The division operator was changed in python 3. Now, if you use '/' for
> division between ints, the result would still be float. To get the same
> effect as python 2.x, you will have to use '//', i.e. floor division
>
> --
> nosy: +FR4NKESTI3N
>
> ___
> Python tracker 
> 
> ___
>

--

___
Python tracker 

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



[issue35672] Error on divide

2019-01-06 Thread Yash Aggarwal


Yash Aggarwal  added the comment:

@Jorge Teran
The division operator was changed in python 3. Now, if you use '/' for division 
between ints, the result would still be float. To get the same effect as python 
2.x, you will have to use '//', i.e. floor division

--
nosy: +FR4NKESTI3N

___
Python tracker 

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



[issue35672] Error on divide

2019-01-06 Thread Serhiy Storchaka


Serhiy Storchaka  added the comment:

I got:

NameError: name 'y1y2y3y4' is not defined.

--
nosy: +serhiy.storchaka

___
Python tracker 

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



[issue35672] Error on divide

2019-01-06 Thread Jorge Teran


New submission from Jorge Teran :

The following code produces an error in the diivision in python 3.5, 3.7 works 
in python 2.7

import math
import sys

x=int(1000112004278059472142857)
y1=int(103)
y2=int(133)
y3=int(137)
y4=int(139)
print (int(y1y2y3y4))
print (x)
#this product equals x Correct
print (int(y2y3*y4))
n=int(x / y1)
print (n)
#n is an incorrect answer
#works in pythoin 2.7
#Gives an incorrect answe in python 3.6.7, 3.7.1

--
components: Interpreter Core
messages: 333107
nosy: Jorge Teran
priority: normal
severity: normal
status: open
title: Error on divide
versions: Python 3.6, Python 3.7

___
Python tracker 

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



[issue35670] os functions return '??' for unicode characters in paths on windows

2019-01-06 Thread Serhiy Storchaka


Serhiy Storchaka  added the comment:

This is a known issue. See for example issue13247 and issue16656. It cannot be 
fixed in Python 2. The only thing that can be done is to document it (see 
issue16700).

--
nosy: +serhiy.storchaka
resolution:  -> wont fix
stage:  -> 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



[issue35671] reserved identifier violation

2019-01-06 Thread Markus Elfring

New submission from Markus Elfring :

I would like to point out that identifiers like “__DYNAMIC_ANNOTATIONS_H__” and 
“_Py_memory_order” do not fit to the expected naming convention of the C++ 
language standard.
https://www.securecoding.cert.org/confluence/display/cplusplus/DCL51-CPP.+Do+not+declare+or+define+a+reserved+identifier

Would you like to adjust your selection for unique names?
* 
https://github.com/python/cpython/blob/e42b705188271da108de42b55d9344642170aa2b/Include/dynamic_annotations.h#L56
* 
https://github.com/python/cpython/blob/130893debfd97c70e3a89d9ba49892f53e6b9d79/Include/internal/pycore_atomic.h#L36

--
components: Interpreter Core
messages: 333105
nosy: elfring
priority: normal
severity: normal
status: open
title: reserved identifier violation
type: security
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



[issue19974] tarfile doesn't overwrite symlink by directory

2019-01-06 Thread Vajrasky Kok


Vajrasky Kok  added the comment:

Correction:
1. broken symlink overwrites valid symlink,
2. ordinary file overwrites broken symlink.

--

___
Python tracker 

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



[issue19974] tarfile doesn't overwrite symlink by directory

2019-01-06 Thread Vajrasky Kok


Vajrasky Kok  added the comment:

Martin, thank you for your advice. I have added additional two test cases for 
broken symlink case.
1. broken symlink overwrites ordinary file,
2. ordinary file overwrites broken symlink.

I hope that is enough. Let me know if you have another concern.

--

___
Python tracker 

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



[issue19974] tarfile doesn't overwrite symlink by directory

2019-01-06 Thread Vajrasky Kok


Vajrasky Kok  added the comment:

I have added test case for broken symlinks. I am not sure whether this is 
necessary or not. But anyway I have added it.

--

___
Python tracker 

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



[issue35669] tar symlink

2019-01-06 Thread Yigit Can


Yigit Can  added the comment:

Similar but not same.

--

___
Python tracker 

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



[issue35670] os functions return '??' for unicode characters in paths on windows

2019-01-06 Thread Creation Elemental

New submission from Creation Elemental :

I have a few files that contain emojis in their names, and also a folder that 
has such. Commands like `os.getcwd`, `os.listdir`, `os.path.realpath`, etc. 
will cause this to happen. However, this is only, as far as I can tell, 
happening on pure windows distributions. This does not happen in the cygwin64 
version I have, nor does it happen in python3.

For example, say you have a folder simply called ''. If you run python inside 
of it and run `os.getcwd()` you will simply get `'??'` as the result. This 
breaks MANY of my programs that depend on knowing exactly where they are, and 
knowing the contents of a directory to pass to other functions.

--
components: Windows
messages: 333100
nosy: Creation Elemental, paul.moore, steve.dower, tim.golden, zach.ware
priority: normal
severity: normal
status: open
title: os functions return '??' for unicode characters in paths on windows
type: behavior
versions: Python 2.7

___
Python tracker 

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



[issue35483] tarfile.extractall on existing symlink in Ubuntu overwrites target file, not symlink, unlinke GNU tar

2019-01-06 Thread Martin Panter


Change by Martin Panter :


--
resolution:  -> duplicate
stage:  -> 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



[issue19974] tarfile doesn't overwrite symlink by directory

2019-01-06 Thread Vajrasky Kok


Vajrasky Kok  added the comment:

After experimenting with lexists, I don't think I can simplify it with lexists.

--

___
Python tracker 

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



[issue19974] tarfile doesn't overwrite symlink by directory

2019-01-06 Thread Martin Panter

Martin Panter  added the comment:

About “lexists”, I meant using it instead of “os.path.exits” (not “islink”). On 
Linux:

>>> targetpath = 'target'
>>> os.symlink('nonexistant', dst=targetpath)  # Make a broken symlink
>>> os.system('ls -l')
total 0
lrwxrwxrwx 1 vadmium vadmium 11 Jan  6 09:28 target -> nonexistant
0
>>> os.path.exists(targetpath)  # Doesn't register broken symlinks
False
>>> os.path.lexists(targetpath)  # Does register it
True

Did you try extracting a tar file over a broken link? (I haven’t tried your 
code; I’m just going on theory.)

--

___
Python tracker 

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



[issue35669] tar symlink

2019-01-06 Thread Karthikeyan Singaravelan


Karthikeyan Singaravelan  added the comment:

Thanks for the report. Is this similar to issue21109?

--
nosy: +xtreak

___
Python tracker 

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



[issue19974] tarfile doesn't overwrite symlink by directory

2019-01-06 Thread Vajrasky Kok


Vajrasky Kok  added the comment:

Sorry, Martin. I just understood what you suggested. I thought you were saying 
lexists to replace islink, but it is to replace the complex if condition. Let 
me work on it.

--

___
Python tracker 

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



[issue19974] tarfile doesn't overwrite symlink by directory

2019-01-06 Thread Vajrasky Kok


Vajrasky Kok  added the comment:

"I could not find a case where these methods return different result." -> This 
is wrong. My mistake. os.lexists returns True for non symbolic link file while 
os.islink returns False.

--

___
Python tracker 

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



[issue19974] tarfile doesn't overwrite symlink by directory

2019-01-06 Thread Vajrasky Kok


Vajrasky Kok  added the comment:

Martin Panter,

I have modernized the patch.

About your suggestion:
1. "import errno" -> Yes, this is unnecessary. I have removed it.
2. Use os.path.lexists instead of os.path.islink for broken symlink -> The 
thing is os.path.islink returns True also for broken symlink. I could not find 
a case where these methods return different result.

--

___
Python tracker 

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



[issue19974] tarfile doesn't overwrite symlink by directory

2019-01-06 Thread Vajrasky Kok


Change by Vajrasky Kok :


--
pull_requests: +10895, 10896, 10897, 10898
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



[issue19974] tarfile doesn't overwrite symlink by directory

2019-01-06 Thread Vajrasky Kok


Change by Vajrasky Kok :


--
pull_requests: +10895, 10896, 10898
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



[issue19974] tarfile doesn't overwrite symlink by directory

2019-01-06 Thread Vajrasky Kok


Change by Vajrasky Kok :


--
pull_requests: +10895, 10896
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



[issue19974] tarfile doesn't overwrite symlink by directory

2019-01-06 Thread Vajrasky Kok


Change by Vajrasky Kok :


--
pull_requests: +10895
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



[issue35306] OSError [WinError 123] when testing if pathlib.Path('*') (asterisks) exists

2019-01-06 Thread jimbo1qaz_ via Gmail


jimbo1qaz_ via Gmail  added the comment:

Should Path.resolve() also avoid raising OSError?

Path('*').resolve()

Traceback (most recent call last):
...truncated
  File "", line 1, in 
Path('*').resolve()
  File 
"C:\Users\jimbo1qaz\AppData\Local\Programs\Python\Python37\lib\pathlib.py", 
line 1134, in resolve
s = self._flavour.resolve(self, strict=strict)
  File 
"C:\Users\jimbo1qaz\AppData\Local\Programs\Python\Python37\lib\pathlib.py", 
line 192, in resolve
s = self._ext_to_normal(_getfinalpathname(s))
OSError: [WinError 123] The filename, directory name, or volume label syntax is 
incorrect: '*'


os.path.realpath('"*')
Out[8]: 'C:\\Users\\jimbo1qaz\\Dropbox\\encrypted\\code\\corrscope\\"*'
os.path.abspath('*"')
Out[13]: 'C:\\Users\\jimbo1qaz\\Dropbox\\encrypted\\code\\corrscope\\*"'

(sidenote: what os.path operation does Path.resolve() match? 
Path('nonexistent').resolve() returns a relative path on Python 3.7.1, whereas 
Path().resolve() returns an absolute path.)

--

___
Python tracker 

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