[issue37531] Fix regrtest timeout for subprocesses: regrtest -jN --timeout=SECONDS

2019-08-22 Thread Eryk Sun
Eryk Sun added the comment: > Is there a way to workaround that? For Windows, subprocess could have a _read_all(file) method that special cases a pipe. The read loop for a pipe would check whether the child has exited. Then call _winapi.PeekNamedPipe on the handle (from get_osfhandle),

[issue37549] os.dup() fails for standard streams on Windows 7

2019-08-23 Thread Eryk Sun
Eryk Sun added the comment: > Should we add a version check as well [1]? I'm not totally comfortable > with bitmasking a handle here, but if we only do this additional > check on Win7 then I'm okay with it. A version check should not be necessary. For file objects, setti

[issue37531] Fix regrtest timeout for subprocesses: regrtest -jN --timeout=SECONDS

2019-08-23 Thread Eryk Sun
Eryk Sun added the comment: Alternatively, instead of special casing the file type and spinning on PeekNamedPipe, the workaround could be based on a multiple-object wait that includes the child process handle. In this case, communicate() would always call _communicate in Windows, regardless

[issue37939] os.path.normpath change some characters of a path into kinda 'hex number'

2019-08-24 Thread Eryk Sun
Eryk Sun added the comment: As Karthikeyan noted, in a regular string literal, backslash is an escape character that's used in the following escape sequences: \N{name} : named character \U : 32-bit hexadecimal ordinal (e.g. \U0010) \u : 16-bit hexade

[issue37939] os.path.normpath change some characters of a path into kinda 'hex number'

2019-08-24 Thread Eryk Sun
Eryk Sun added the comment: >\N{name} : named character >\U : 32-bit hexadecimal ordinal (e.g. \U0010) >\u : 16-bit hexadecimal ordinal (e.g. \u) >\xXX : 8-bit hexadecimal ordinal (e.g. \xff) >\OOO : 9-bit octal ord

[issue20806] os.times document points to wrong section of non-Linux manual

2019-08-25 Thread Eryk Sun
Eryk Sun added the comment: The function's doc string also needs to be updated to use the correct field names: "user", "system", "children_user", "children_system", and "elapsed". > And we can also add a link to MSDN. os.times calls

[issue37945] test_locale failing

2019-08-25 Thread Eryk Sun
Eryk Sun added the comment: local.normalize is generally wrong in Windows. It's meant for POSIX systems. Currently "tr_TR" is parsed as follows: >>> locale._parse_localename('tr_TR') ('tr_TR', 'ISO8859-9') The encoding "I

[issue37945] test_locale failing

2019-08-26 Thread Eryk Sun
Eryk Sun added the comment: > But my question is, then: why is my machine failing this test [the > only one which uses this two-part locale] and not the buildbots or > (presumably) any other Windows developer? test_getsetlocale_issue1813 fails for me as well. I can't imagine

[issue37945] test_locale failing

2019-08-26 Thread Eryk Sun
Eryk Sun added the comment: We get into trouble with test_getsetlocale_issue1813 because normalize() maps "tr_TR" (supported) to "tr_TR.ISO8859-9" (not supported). >>> locale.normalize('tr_TR') 'tr_TR.ISO8859-9' We should s

[issue37945] test_locale failing

2019-08-26 Thread Eryk Sun
Eryk Sun added the comment: > None of that explains why the test doesn't seem to run at all on the > buildbots though. Are the buildbots using an older version of UCRT? BCP 47 locales used to strictly require a hyphen as the delimiter (e.g. 'tr-TR') instead of und

[issue37705] winerror_to_errno implementation

2019-08-26 Thread Eryk Sun
Eryk Sun added the comment: > It also seems like at least some of the WSA* constants (e.g. > WSAEBADF==10009) are the equivalent errno plus 1 > (e.g.EBADF==9). Should we be mapping those back to the > errno value? Mapping WSAEINTR (10004) -> EINTR (4) and WSAEACCES (1

[issue32847] Add DirectoryNotEmptyError subclass of OSError

2019-08-29 Thread Eryk Sun
Eryk Sun added the comment: > I have no opinion about "errno 39 (Directory not empty)". > Is it a "common" error? Python's code base never specifically handles ENOTEMPTY. On the other hand, in terms of basic operations on files and directories, I think imple

[issue37945] test_locale failing

2019-08-29 Thread Eryk Sun
Eryk Sun added the comment: Here's some additional background information for work on this issue. A Unix locale identifier has the following form: "language[_territory][.codeset][@modifier]" | "POSIX" | "C" | ""

[issue37945] test_locale failing

2019-08-29 Thread Eryk Sun
Eryk Sun added the comment: If normalize() is implemented for Windows, then the tests should be split out into POSIX and Windows versions. Currently, most of the tests in NormalizeTest are not checking a result that's properly normalized for ucrt. A useful implementation of locale.norm

[issue37993] os.path.realpath on Windows resolves mapped network drives

2019-08-31 Thread Eryk Sun
Eryk Sun added the comment: >>>> sys.executable >'X:\\Python38\\python.exe' >>>> os.path.realpath(sys.executable) >'SERVER\\Programs\\Python38\\python.exe' Unix Python resolves the executable path with repeated _Py_wr

[issue37993] os.path.realpath on Windows resolves mapped network drives

2019-09-01 Thread Eryk Sun
Eryk Sun added the comment: >> Unix Python resolves the executable path with repeated _Py_wreadlink >> calls. Windows Python should do something similar to ensure the >> consistency of sys.executable with realpath(sys.executable). > > I don't think this necessa

[issue38030] os.stat fails for block devices such as //./PhysicalDrive0

2019-09-04 Thread Eryk Sun
New submission from Eryk Sun : In issue 37834, I posted a suggest implementation of win32_xstat_impl that included the following snippet of code: if (!GetFileInformationByHandle(hFile, &fileInfo)) { error = GetLastError(); if (error != ERROR_INVALID_PARAM

[issue37380] subprocess.Popen._cleanup() "The handle is invalid" error when some old process is gone

2019-09-06 Thread Eryk Sun
Eryk Sun added the comment: > When a Popen instance is finalized by the garbage collector, the > internal handle is also finalized and closed despite the instance > being put on the active list. This results in _cleanup throwing > because the handle can no longer be used. Than

[issue37993] os.path.realpath on Windows resolves mapped network drives

2019-09-11 Thread Eryk Sun
Eryk Sun added the comment: > It's a few steps deep, but DefineDosDeviceW() [1] specifies that it > creates junctions, and while it's not necessarily obvious how to get > from SUBST to that page, Wikipedia managed it [2]. Take care to not conflate device junctions w

[issue38081] Different behavior of os.path.realpath('nul') in 3.7 and 3.8

2019-09-11 Thread Eryk Sun
Eryk Sun added the comment: We should allow ERROR_INVALID_FUNCTION (1), ERROR_INVALID_PARAMETER (87), and ERROR_NOT_SUPPORTED (50) for readlink and _getfinalpathname, which can indicate a device that does not implement or is not mounted by a file system. We should also allow

[issue38081] Different behavior of os.path.realpath('nul') in 3.7 and 3.8

2019-09-11 Thread Eryk Sun
Change by Eryk Sun : -- status: closed -> open ___ Python tracker <https://bugs.python.org/issue38081> ___ ___ Python-bugs-list mailing list Unsubscrib

[issue38081] Different behavior of os.path.realpath('nul') in 3.7 and 3.8

2019-09-11 Thread Eryk Sun
Eryk Sun added the comment: In addition to ERROR_INVALID_FUNCTION (1), ERROR_INVALID_PARAMETER (87), and ERROR_NOT_SUPPORTED (50) for an unsupported device, and ERROR_BAD_NET_NAME (67) for a missing server or share, it should also allow common permission errors: ERROR_ACCESS_DENIED (5

[issue38133] py.exe cannot locate Store package

2019-09-12 Thread Eryk Sun
Eryk Sun added the comment: > -3.7-32-32 C:\Python37_x86\python.exe > -3.6-32-32 C:\Python36_x86\python.exe > -3.5-32-32 C:\Python35_x86\python.exe MAX_VERSION_SIZE was increased, so the INSTALLED_PYTHON version string is now the full registry key name with the "-

[issue37609] support "UNC" device paths in ntpath.splitdrive

2019-09-13 Thread Eryk Sun
Eryk Sun added the comment: Please consult the attached file "splitdrive.py". I redesigned splitdrive() to support "UNC" and "GLOBAL" junctions in device paths. I relaxed the design to allow repeated separators everywhere except for the UNC root. IIRC, Window

[issue38098] Special Characters Don't Work When Using Virtual Environment

2019-09-13 Thread Eryk Sun
Eryk Sun added the comment: > pyreadline (2.1) The problem is pyreadline. It uses a low-level console read, but it fails to account for the Alt+Numpad sequence of input records that the console uses for non-OEM characters. IIRC, the Unicode character is only sent in the final input rec

[issue32592] Drop support of Windows Vista and 7 in Python 3.9

2019-09-15 Thread Eryk Sun
Eryk Sun added the comment: 3.9 can drop support for console pseudohandles in set_inheritable in Python/fileutils.c and Popen._filter_handle_list in Lib/subprocess.py. Also, _Py_write_impl in Python/fileutils.c can remove the 32767 byte limit for console files (and other character devices

[issue32592] Drop support of Windows Vista and 7 in Python 3.9

2019-09-15 Thread Eryk Sun
Eryk Sun added the comment: Here are a couple more: * WSA_FLAG_NO_HANDLE_INHERIT is supported. Code related to `support_wsa_no_inherit` in Modules/socketmodule.c can be removed. * AddDllDirectory and RemoveDllDirectory are supported. os__add_dll_directory_impl and

[issue38188] Incorrect Argument Order for Calls to _winapi.DuplicateHandle() in multiprocessing.reduction.DupHandle

2019-09-16 Thread Eryk Sun
Eryk Sun added the comment: As far as I can tell, reduction.send_handle isn't used internally in the Windows implementation, and it's also not a documented API function. However, it is tested on Windows in test_fd_transfer in Lib/test/_test_multiprocessing.py. As it turns out, th

[issue38188] Incorrect Argument Order for Calls to _winapi.DuplicateHandle() in multiprocessing.reduction.DupHandle

2019-09-17 Thread Eryk Sun
Eryk Sun added the comment: Let's make test_fd_transfer_windows a bit less hangy by polling for up to 60 seconds instead of simply trying to recv() and by terminating before trying to join(). @unittest.skipUnless(HAS_REDUCTION, "test needs multiprocessing

[issue38081] Different behavior of os.path.realpath('nul') in 3.7 and 3.8

2019-09-17 Thread Eryk Sun
Eryk Sun added the comment: Sorry, I mistakenly left out ERROR_BAD_NETPATH (53). It's at least used with mapped drives. For example, I have drive "M:" mapped to WebDAV "//live.sysinternals.com/tools", and I see this error if I disconnect the network: >>

[issue38220] Wrong values for %b and %B in ca_ES and ca_AD locales

2019-09-18 Thread Eryk Sun
Eryk Sun added the comment: The result from strftime is platform dependent. In Windows, the result has a trailing "." for the abbreviated names that are less than four characters, but no "de" in either form: >>> months = [(2019, m) + (0,)*7 for m in range(1,

[issue38228] Missing documentation on strftime modifier O

2019-09-19 Thread Eryk Sun
Eryk Sun added the comment: > Have you tried this on Windows or macOS? 3.5+ in Windows uses ucrt, which quietly ignores 'E' and 'O' strftime modifiers. From ucrt\time\wcsftime.cpp: // Skip ISO E and O alternative representation format modifiers. We

[issue38246] pathlib.resolve and .absolute leave trailing tilde in home expansion

2019-09-21 Thread Eryk Sun
Eryk Sun added the comment: Only Path.expanduser() special cases tilde as a POSIX shell would. Otherwise "~" is not a reserved filename character in POSIX. Path('~') is a file named "~" that's relative to the current working directory. By coincidence the w

[issue38258] ctypes ignores when a DLL function is called with too many arguments

2019-09-23 Thread Eryk Sun
Eryk Sun added the comment: According to the docs, raising ValueError in this case has been a deprecated feature since 3.6.2, and the ability to do so no longer exists in 3.8. The documentation needs to be updated to reflect the new behavior. https://docs.python.org/3.8/library/ctypes.html

[issue38258] ctypes ignores when a DLL function is called with too many arguments

2019-09-24 Thread Eryk Sun
Eryk Sun added the comment: > Just out of curiosity, where is this data coming from? In general it's just random data on the stack. It's not worth investigating where this particular value comes from. It could be the low word of the address of a stack-allocated buffer, such

[issue32592] Drop support of Windows Vista and 7 in Python 3.9

2019-09-26 Thread Eryk Sun
Eryk Sun added the comment: Steve, in PR 15951 you updated Py_WINVER to 0x0602. I think it should be 0x0603 (_WIN32_WINNT_WINBLUE) and Py_NTDDI should be NTDDI_WINBLUE. Windows 8 hasn't been supported since 2016. Windows 8.1 is supported until

[issue32592] Drop support of Windows Vista and 7 in Python 3.9

2019-09-26 Thread Eryk Sun
Eryk Sun added the comment: > I'm not sure that there is a big benefit for us to drop Windows 8 > support (only Windows 8 but continue to support Windows 8.1), > compared to the annoyance for users. According to statcounter.com and netmarketshare.com, Windows 8 still has 1% o

[issue38325] [Windows] test_winconsoleio failures

2019-09-30 Thread Eryk Sun
Eryk Sun added the comment: Apparently handling non-BMP codes is broken in recent builds of the new console in Windows 10. I see this problem in build 18362 as well. It seems there have been updates that have changed the naive way the console used to handle surrogate codes as just regular

[issue38325] [Windows] test_winconsoleio failures

2019-09-30 Thread Eryk Sun
Eryk Sun added the comment: Does test_partial_reads fail for you when run separately? If so, it's for a different reason. Otherwise, there may have been text left in the input buffer from test_input that led to the failure, which is a separate problem that needs to be addresse

[issue38324] [Windows] test_locale and test__locale failures on Windows

2019-10-05 Thread Eryk Sun
Eryk Sun added the comment: Terry, the test_winconsoleio problem is issue 38325. Test cases with surrogate pairs that are known to fail in recent builds of Windows 10 have to be split out. For the "ps_AF" locale failure that you noted, in my case with Windows 10 18362, I hav

[issue38428] Can't gracefully ctrl+C multiprocessing pool on Python3 & Windows

2019-10-10 Thread Eryk Sun
Eryk Sun added the comment: > Python 2.7 had totally different code, IIRC. In 2.7 the wait() method of threading._Condition implements the timeout with a loop the calls time.sleep() with an increasing delay from 500 microseconds up to 50 ms, and no more than the remaining time. > B

[issue38445] os.path.exists() takes bool as argument and returns True

2019-10-11 Thread Eryk Sun
Eryk Sun added the comment: Note that the underlying stat call supports file descriptors, which are non-negative integers. This is a supported and tested capability for genericpath.exists (see GenericTest.test_exists_fd in Lib/test/test_genericpath.py). False and True are integers with the

[issue38445] os.path.exists() takes bool as argument and returns True

2019-10-11 Thread Eryk Sun
Eryk Sun added the comment: > Maybe os.fspath() can be used I think that would already be the case if genericpath.exists didn't have to support file descriptors. It's documented that the path argument "refers to an existing path or an open file descriptor". Modify

[issue38454] test_listdir is failing on ubuntu with WSL

2019-10-12 Thread Eryk Sun
Eryk Sun added the comment: The test assumes that Unix filesystems store names as arbitrary sequences of bytes, with only ASCII slash and null reserved. Windows NTFS stores names as arbitrary sequences of 16-bit words, with many reserved ASCII characters including \/:*?<>"|

[issue38470] test_compileall fails in AMD64 Windows7 SP1 3.x

2019-10-14 Thread Eryk Sun
Eryk Sun added the comment: I tested in Windows 10 with long paths disabled, and the FileNotFoundError exception showed that the failing .pyc had a numeric suffix appended to the name. create_long_path isn't taking into account _write_atomic in Lib/importlib/_bootstrap_external.py.

[issue38533] v3.7.5 py script run ok with python.exe but not pythonw.exe (python silent console not working)

2019-10-20 Thread Eryk Sun
Eryk Sun added the comment: > Let me know if you are unable to reproduce it. x64 pythonw.exe and pyw.exe (3.7.5, 2019-10-14) work for me in Windows 10.0.18362. I have them installed for all users, respectively in "C:\Program Files\Python37" and "C:\Windows". Try

[issue38533] v3.7.5 py script run ok with python.exe but not pythonw.exe (python silent console not working)

2019-10-21 Thread Eryk Sun
Eryk Sun added the comment: > At least one package in 3.8 still contained a dependency on the C++ > runtime FWIW, the very first thing that I checked was the dependencies of pythonw.exe, in case maybe I had a dependent DLL that's not distributed with Windows. There's no

[issue38483] [venv] Add ~/.venvrc to change module defaults

2019-10-21 Thread Eryk Sun
Eryk Sun added the comment: In Windows, dot files cannot be hidden (i.e. set the hidden file attribute), unlike how they're conventionally hidden in Unix. Doing so breaks normal access. A directory such as ".venv" can be hidden, but that's still going against conven

[issue38092] environment variables not passed correctly using new virtualenv launching in windows and python3.7+

2019-10-23 Thread Eryk Sun
Eryk Sun added the comment: This should revert to setting `_python_exe = sys.executable` in Lib/multiprocessing/spawn.py. Then the code in Lib/multiprocessing/popen_spawn_win32.py will set __PYVENV_LAUNCHER__ in the spawned process to the virtual environment's sys.executable. Otherwis

[issue2528] Change os.access to check ACLs under Windows

2021-03-11 Thread Eryk Sun
Eryk Sun added the comment: With increasing use of os.access() in shutil and tempfile, it would be nice to have a real implementation of os.access() for Windows. Instead of manually evaluating the security of the file/directory, as issue2528.2.patch attempts to do, I'd rather just ope

[issue25481] PermissionError in subprocess.check_output() when an inaccessible directory on the path

2021-03-11 Thread Eryk Sun
Eryk Sun added the comment: > So, two interesting questions: does this in fact match the behavior of > os._execvpe, and does it match the behavior of the shell? I think it's fine. child_exec() tries all paths. It saves the first error that's not ENOENT or ENOTDIR. The

[issue31427] Add an answer to the Windows FAQ about installing the Universal C Runtime

2021-03-12 Thread Eryk Sun
Change by Eryk Sun : -- title: Proposed addition to Windows FAQ -> Add an answer to the Windows FAQ about installing the Universal C Runtime versions: +Python 3.10, Python 3.8, Python 3.9 -Python 3.5, Python 3.6, Python 3.7 ___ Python trac

[issue21518] Expose RegUnLoadKey in winreg

2021-03-12 Thread Eryk Sun
Eryk Sun added the comment: I added an updated implementation of windows_helper.py to the dependency bpo-22080. -- components: +Windows nosy: +paul.moore versions: +Python 3.10, Python 3.8, Python 3.9 -Python 3.5 ___ Python tracker <ht

[issue24052] sys.exit(code) returns "success" to the OS for some nonzero values of code

2021-03-12 Thread Eryk Sun
Change by Eryk Sun : -- versions: +Python 3.10, Python 3.8, Python 3.9 -Python 3.5 ___ Python tracker <https://bugs.python.org/issue24052> ___ ___ Python-bug

[issue25741] Usual Installation Directory

2021-03-12 Thread Eryk Sun
Eryk Sun added the comment: I'm closing this issue as out of date. The tutorial now refers to the py command and also the python3.9 command from the app distribution. The patch's addition of "followed by Enter" after "Control-Z" is still needed, but i

[issue26882] The Python process stops responding immediately after starting

2021-03-12 Thread Eryk Sun
Eryk Sun added the comment: Hanging on a synchronous console file during startup shouldn't be an issue in 3.6+, since io._WindowsConsoleIO doesn't support seeking, but it could still be an issue with legacy mode, which uses io.FileIO. I'm marking this as a duplicate of bpo-3

[issue34780] [Windows] Hang on startup if stdin refers to a pipe with an outstanding concurrent operation on Windows

2021-03-12 Thread Eryk Sun
Eryk Sun added the comment: Console input handles pose the same risk of hanging indefinitely when io.FileIO is used in legacy standard I/O mode (i.e. PYTHONLEGACYWINDOWSSTDIO). Seeking could simply be disallowed on all files that aren't FILE_TYPE_DISK. For example, change portable_

[issue40540] inconstent stdin buffering/seeking behaviour

2021-03-12 Thread Eryk Sun
Change by Eryk Sun : -- resolution: -> duplicate stage: -> resolved status: open -> closed superseder: -> seekable() returns True on pipe objects in Windows ___ Python tracker <https://bugs.python

[issue34780] [Windows] Hang on startup if stdin refers to a pipe with an outstanding concurrent operation on Windows

2021-03-12 Thread Eryk Sun
Eryk Sun added the comment: If non-disk files are made non-seekable in Windows, this will also resolve bpo-42602. -- ___ Python tracker <https://bugs.python.org/issue34

[issue11429] ctypes is highly eclectic in its raw-memory support

2021-03-12 Thread Eryk Sun
Change by Eryk Sun : -- versions: +Python 3.10, Python 3.8, Python 3.9 -Python 3.5 ___ Python tracker <https://bugs.python.org/issue11429> ___ ___ Python-bug

[issue29844] Windows Python installers not installing DLL to System32/SysWOW64

2021-03-12 Thread Eryk Sun
Eryk Sun added the comment: "Tools/msi/README.txt" still references "%SystemRoot%\System32" and "%SystemRoot%\SysWOW64" as the location of "python3[x].dll" for all-users installs. The containing paragraph can be removed. Move the lines

[issue22781] ctypes: Differing results between Python and C.

2021-03-12 Thread Eryk Sun
Change by Eryk Sun : -- stage: -> resolved status: open -> closed ___ Python tracker <https://bugs.python.org/issue22781> ___ ___ Python-bugs-list

[issue15453] ctype with packed bitfields does not match native compiler

2021-03-12 Thread Eryk Sun
Change by Eryk Sun : -- resolution: -> duplicate stage: -> resolved status: open -> closed superseder: -> Ctypes Packing Bitfields Incorrectly - Linux ___ Python tracker <https://bugs.python

[issue29657] os.symlink: FileExistsError shows wrong message

2021-03-12 Thread Eryk Sun
Change by Eryk Sun : -- components: +Extension Modules, Interpreter Core -Library (Lib) stage: patch review -> versions: +Python 3.10, Python 3.8, Python 3.9 -Python 3.5, Python 3.6, Python 3.7 ___ Python tracker <https://bugs.pyth

[issue29256] Windows select() errors out when given no fds to select on, which breaks SelectSelector

2021-03-12 Thread Eryk Sun
Change by Eryk Sun : -- versions: +Python 3.10, Python 3.8, Python 3.9 -Python 3.5, Python 3.6, Python 3.7 ___ Python tracker <https://bugs.python.org/issue29

[issue15244] Support for opening files with FILE_SHARE_DELETE on Windows

2021-03-12 Thread Eryk Sun
Eryk Sun added the comment: Deleting a file in Windows 10 has been updated to try a POSIX-style delete. For a POSIX delete, the filesystem unlinks the file even it's open, whereas a classic delete only unlinks a 'deleted' file when it's closed. The filesystem has to s

[issue27827] pathlib is_reserved fails for some reserved paths on Windows

2021-03-12 Thread Eryk Sun
Change by Eryk Sun : -- stage: needs patch -> versions: +Python 3.10, Python 3.8, Python 3.9 -Python 3.5, Python 3.6 ___ Python tracker <https://bugs.python.org/issu

[issue37612] os.link(..., follow_symlinks=True) broken on Linux

2021-03-12 Thread Eryk Sun
Change by Eryk Sun : -- components: +Extension Modules -Library (Lib) versions: +Python 3.10 -Python 3.5, Python 3.6, Python 3.7 ___ Python tracker <https://bugs.python.org/issue37

[issue35883] Change invalid unicode characters to replacement characters in argv

2021-03-12 Thread Eryk Sun
Change by Eryk Sun : -- components: +Unicode nosy: +ezio.melotti, vstinner versions: -Python 3.5, Python 3.6, Python 3.7 ___ Python tracker <https://bugs.python.org/issue35

[issue27886] Docs: the difference between rename and replace is not obvious

2021-03-12 Thread Eryk Sun
Change by Eryk Sun : -- Removed message: https://bugs.python.org/msg273845 ___ Python tracker <https://bugs.python.org/issue27886> ___ ___ Python-bugs-list mailin

[issue27886] Docs: the difference between Path.rename() and Path.replace() is not obvious

2021-03-12 Thread Eryk Sun
Eryk Sun added the comment: The pathlib documentation of Path.rename() says "[o]n Unix, if target exists and is a file, it will be replaced silently if the user has permission". This leaves the behavior on Windows in question. The reader has to scroll down to the correspondenc

[issue26362] Approved API for creating a temporary file path

2021-03-12 Thread Eryk Sun
Eryk Sun added the comment: > The proposal in this issue is to have a public standard library API, > which I'm calling ‘tempfile.makepath’, It's a few years later, and tempfile.mktemp() still exists and works without raising a deprecation warning. Of course it's still ma

[issue29688] Add support for Path.absolute()

2021-03-12 Thread Eryk Sun
Change by Eryk Sun : -- assignee: -> docs@python components: +Library (Lib) type: -> enhancement versions: +Python 3.10, Python 3.8, Python 3.9 -Python 3.5, Python 3.6, Python 3.7 ___ Python tracker <https://bugs.python.org/i

[issue18017] ctypes.PyDLL documentation

2021-03-12 Thread Eryk Sun
Eryk Sun added the comment: I think the documentation of ctypes.PyDLL and ctypes.pythonapi is good enough as is. -- resolution: -> rejected stage: -> resolved status: open -> closed ___ Python tracker <https://bugs.python.or

[issue30435] Documentation either unclear or incorrect on comparisons between bytes and strings in Python 3

2021-03-12 Thread Eryk Sun
Change by Eryk Sun : -- type: behavior -> enhancement versions: +Python 3.10, Python 3.8, Python 3.9 -Python 3.5, Python 3.6, Python 3.7 ___ Python tracker <https://bugs.python.org/issu

[issue34840] dlopen() error with no error message from dlerror()

2021-03-12 Thread Eryk Sun
Change by Eryk Sun : -- resolution: -> not a bug stage: -> resolved status: open -> closed ___ Python tracker <https://bugs.python.org/issue34840> ___

[issue26362] Approved API for creating a temporary file path

2021-03-12 Thread Eryk Sun
Eryk Sun added the comment: > So no, while unresolved, this bug report should not be closed. The implied question was whether you or the core devs on the nosy list, upon further consideration, wanted to resolve the issue by rejecting the request, but it had simply been forgotten about fo

[issue36880] Returning None from a callback with restype py_object decrements None's refcount too much

2021-03-12 Thread Eryk Sun
Change by Eryk Sun : -- versions: +Python 3.10, Python 3.9 -Python 3.5, Python 3.6, Python 3.7 ___ Python tracker <https://bugs.python.org/issue36880> ___ ___

[issue23633] Improve py launcher help, index, and doc

2021-03-12 Thread Eryk Sun
Eryk Sun added the comment: The current help text attempts to explain point 2, in terms of an active virtual environment, shebangs, the PY_PYTHON[2|3] environment variables, and the py.ini [defaults]. It's a lot to say succinctly in a few lines of text. A shortened URL that links t

[issue25117] Windows installer: precompiling stdlib fails with missing DLL errors

2021-03-13 Thread Eryk Sun
Eryk Sun added the comment: Maybe it's worth adding a recommendation in the docs to reboot and try to repair an installation that fails in the final stage due to ucrt not being fully installed yet, i.e. missing api-ms-win-crt-*.dll. Or maybe this case can be detected and display a me

[issue25166] Windows AllUsers installation places uninstaller in user profile

2021-03-13 Thread Eryk Sun
Change by Eryk Sun : -- versions: +Python 3.10, Python 3.9 -Python 3.6, Python 3.7 ___ Python tracker <https://bugs.python.org/issue25166> ___ ___ Python-bug

[issue28344] Python 3.5.2 installer hangs when run in session 0

2021-03-13 Thread Eryk Sun
Eryk Sun added the comment: I tested installing 3.10 in session 0 for the current user, as a user with the batch logon right. The installation succeeded. If you're running as SYSTEM, then installing for the current user doesn't see reasonable to me. I won't test that c

[issue29124] Freeze fails to compile on windows

2021-03-13 Thread Eryk Sun
Change by Eryk Sun : -- versions: +Python 3.10, Python 3.8, Python 3.9 -Python 3.5, Python 3.6, Python 3.7 ___ Python tracker <https://bugs.python.org/issue29

[issue29586] Cannot run pip in fresh install of py 3.5.3

2021-03-13 Thread Eryk Sun
Eryk Sun added the comment: This issue is similar to bpo-25117 in terms of the installer failing to run Python for post-installation tasks. The complication in this case is that a subsequent repair doesn't install pip. -- versions: +Python 3.10, Python 3.8, Python 3.9 -Pytho

[issue27749] multiprocessing Manager error: send() called for a closed connection

2021-03-13 Thread Eryk Sun
Change by Eryk Sun : -- title: multprocessing errors on Windows: WriteFile() argument 1 must be int, not None; OSError: handle is closed -> multiprocessing Manager error: send() called for a closed connection type: crash -> behavior versions: +Python 3.10, Python 3.8, Pyth

[issue43491] Windows filepath bug

2021-03-14 Thread Eryk Sun
Eryk Sun added the comment: "C:\some\path/some/file.txt" is a valid file path. The Windows file API normalizes most paths, except for verbatim paths that start with exactly "\\?\". Path normalization includes replacing forward slashes with backslashes. If you provide th

[issue32592] Drop support of Windows Vista and 7 in Python 3.9

2021-03-14 Thread Eryk Sun
Eryk Sun added the comment: PEP 11 says that "[a] new feature release X.Y.0 will support all Windows releases whose extended support phase is not yet expired". There was no such thing as Extended Security Updates (ESU) when that provision was accepted. As defined by PEP 11, extend

[issue12777] Inconsistent use of VOLUME_NAME_* with GetFinalPathNameByHandle

2021-03-15 Thread Eryk Sun
Eryk Sun added the comment: bpo-33016 fixed the problem with the inconsistent dwFlags argument passed to GetFinalPathNameByHandleW(). We do need the ability to get the NT name in order to implement samefile() and sameopenfile() reliably in all cases -- i.e. when the volume serial number

[issue17620] Python interactive console doesn't use sys.stdin for input

2021-03-15 Thread Eryk Sun
Change by Eryk Sun : -- versions: +Python 3.10, Python 3.8, Python 3.9 -Python 3.6 ___ Python tracker <https://bugs.python.org/issue17620> ___ ___ Python-bug

[issue24829] Use interactive input even if stdout is redirected

2021-03-15 Thread Eryk Sun
Change by Eryk Sun : -- dependencies: +Python interactive console doesn't use sys.stdin for input versions: +Python 3.10, Python 3.8, Python 3.9 -Python 3.6 ___ Python tracker <https://bugs.python.org/is

[issue29805] Support moving across filesystems in pathlib.Path, as shutil.move() does

2021-03-15 Thread Eryk Sun
Change by Eryk Sun : -- components: -Windows title: Pathlib.replace cannot move file to a different drive on Windows if filename different -> Support moving across filesystems in pathlib.Path, as shutil.move() does versions: +Python 3.10, Python 3.8, Python 3.9 -Python

[issue27346] Implement os.readv() / os.writev() in Windows port

2021-03-15 Thread Eryk Sun
Eryk Sun added the comment: The need for asynchronous I/O (i.e. FILE_FLAG_OVERLAPPED) with ReadFileScatter() and WriteFileGather() makes them a poor fit for POSIX os.readv() and os.writev(), since we can't open the file with open() or os.open(). Python's socket module opens

[issue30555] _io._WindowsConsoleIO breaks in the face of fd redirection

2021-03-15 Thread Eryk Sun
Eryk Sun added the comment: PR 1927 is a definite improvement. By using _get_osfhandle() instead of caching the handle value, it guarantees that access to the original console file can be saved and restored via `fd_save = dup(fd)` and `dup2(fd_save, fd)`. It also allows duping a new open of

[issue31665] Edit "Setting [windows] environmental variables"

2021-03-15 Thread Eryk Sun
Change by Eryk Sun : -- versions: +Python 3.10, Python 3.8, Python 3.9 -Python 3.6, Python 3.7 ___ Python tracker <https://bugs.python.org/issue31665> ___ ___

[issue32434] pathlib.WindowsPath.reslove(strict=False) returns absoulte path only if at least one component exists

2021-03-15 Thread Eryk Sun
Eryk Sun added the comment: bpo-38671 has PR 17716 pending approval, which addresses the problem in msg309102 by ensuring that a non-strict resolve begins by getting the absolute path via nt._getfullpathname(). -- resolution: -> duplicate stage: needs patch -> resolved status

[issue27346] Implement os.readv() / os.writev() in Windows port

2021-03-15 Thread Eryk Sun
Change by Eryk Sun : -- status: open -> pending ___ Python tracker <https://bugs.python.org/issue27346> ___ ___ Python-bugs-list mailing list Unsubscrib

[issue33603] Subprocess Thread handles grow with each call and aren't released [Windows]

2021-03-15 Thread Eryk Sun
Change by Eryk Sun : -- resolution: -> third party stage: -> resolved status: open -> closed ___ Python tracker <https://bugs.python.org/issue33603> ___ ___

[issue33780] [subprocess] Better Unicode support for shell=True on Windows

2021-03-15 Thread Eryk Sun
Eryk Sun added the comment: The complexity of mixing standard I/O from the shell and external programs is a limitation of the Windows command line. Each program could choose to use the system (or process) ANSI or OEM code page, the console session's input or output code page, UTF-8, o

[issue36646] os.listdir() got permission error in Python3.6 but it's fine in Python2.7

2021-03-15 Thread Eryk Sun
Eryk Sun added the comment: I'm certain this is a third-party problem -- something like AppLocker or an anti-malware program that's limiting filesystem access. It's not a bug in Python, which simply uses FindFirstFileW() and FindNextFileW() in the normal way. --

[issue36213] subprocess.check_output() fails with OSError: [WinError 87] when current directory name is too long

2021-03-15 Thread Eryk Sun
Eryk Sun added the comment: As discussed in msg337357, the Windows API does not support setting the current working directory to a path that starts with \\?\ or \\.\. It's dysfunctional in many cases. Anyway, using a \\?\ path does not remove the length limit on the working directory,

<    1   2   3   4   5   6   7   8   9   10   >