[issue33074] dbm corrupts index on macOS (_dbm module)

2018-03-14 Thread Robert Xiao
New submission from Robert Xiao <nneon...@gmail.com>: Environment: Python 3.6.4, macOS 10.12.6 Python 3's dbm appears to corrupt the key index on macOS if objects >4KB are inserted. Code: <<<<<<<<<<< import dbm import contextlib with conte

[issue33074] dbm corrupts index on macOS (_dbm module)

2018-03-14 Thread Robert Xiao
Robert Xiao <nneon...@gmail.com> added the comment: (Note: the contextlib stuff is just for Python 2 compatibility, it's not necessary on Python 3). -- ___ Python tracker <rep...@bugs.python.org> <https://bugs.python

[issue26680] Incorporating float.is_integer into the numeric tower and Decimal

2018-03-10 Thread Robert Smallshire
Robert Smallshire <r...@sixty-north.com> added the comment: I've recently run into this issue impeding duck-typing between int and float again, when used in conjunction the int.__pow__, which may variously return an int or float depending on the value - not the type - of the arg

[issue26680] Incorporating float.is_integer into the numeric tower and Decimal

2018-03-15 Thread Robert Smallshire
Change by Robert Smallshire <r...@sixty-north.com>: -- pull_requests: +5885 stage: needs patch -> patch review ___ Python tracker <rep...@bugs.python.org> <https://bugs.pyt

[issue26680] Incorporating float.is_integer into the numeric tower and Decimal

2018-03-15 Thread Robert Smallshire
Robert Smallshire <r...@sixty-north.com> added the comment: Python in effect contains an example itself. The math.factorial(x) function contains what is in-effect an is_integer() check as a guard. -- ___ Python tracker <rep...@bugs.p

[issue26680] Incorporating float.is_integer into the numeric tower and Decimal

2018-03-15 Thread Robert Smallshire
Robert Smallshire <r...@sixty-north.com> added the comment: Serhiy, you asked for use cases, not uses. The former can exist without the latter. Use cases for is_integer() include all existing uses of x == int(x), or other less obvious means of detecting integer values. Folks try

[issue32419] Add unittest support for pyc projects

2018-03-31 Thread Robert Collins
Robert Collins <robe...@robertcollins.net> added the comment: Oh, and why look for __init__ - in part, because it predates namespace packages, but also because unlike regular imports unittest will do negative things like reading the entire filesystem oth

[issue32419] Add unittest support for pyc projects

2018-03-31 Thread Robert Collins
Robert Collins <robe...@robertcollins.net> added the comment: Whats the use for *unittest* - a tool to help folk develop - to run a test which is only present in sourceless form? -- ___ Python tracker <rep...@bugs.python.or

[issue33074] dbm corrupts index on macOS (_dbm module)

2018-03-29 Thread Robert Xiao
Robert Xiao <nneon...@gmail.com> added the comment: So we have some other problems then: (1) It should be documented in dbm, and ideally in shelve, that keys/values over a certain limit might not work. Presently there is no hint that such a limit exists, and until you mentione

[issue33090] race condition between send and recv in _ssl with non-zero timeout

2018-03-16 Thread Robert Xiao
New submission from Robert Xiao <nneon...@gmail.com>: Environment: Several versions of Python (see below), macOS 10.12.6 The attached script creates an SSL echo server (fairly standard), connects to the server, and spawns a read and write thread. The write thread repeatedly shovel

[issue33021] Some fstat() calls do not release the GIL, possibly hanging all threads

2018-03-19 Thread Robert Collins
Robert Collins <robe...@robertcollins.net> added the comment: Re: backporting this. I think backporting to 3.6/3.7 makes a lot of sense - bugfix and prerelease respectively. For 2.7, this bug has been around for ages, the patch is small, and I have no objection - but the RM has alread

[issue34932] Add macOS TCP_KEEPALIVE to available socket options

2018-10-15 Thread Robert Wall
Robert Wall added the comment: I saw that article too but reading man tcp(4) [1], it says that this value is in seconds for macOS and testing appears to confirm this. Where the unit of time is different, however, is with the old and new Windows keepalive options discussed in #32394

[issue35005] argparse should accept json and yaml argument types

2018-10-16 Thread Robert Benson
Change by Robert Benson : -- versions: -Python 2.7 ___ Python tracker <https://bugs.python.org/issue35005> ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue35005] argparse should accept json and yaml argument types

2018-10-16 Thread Robert Benson
New submission from Robert Benson : Using `argparse`, I wanted to create an argument that was a JSON dictionary. I found that using this in combination with the `fromfile_prefix_args` keyword argument, that the parser assumes that each argument provided in the file must be on a single line

[issue35005] argparse should accept json and yaml argument types

2018-10-16 Thread Robert Benson
Change by Robert Benson : -- versions: +Python 2.7 ___ Python tracker <https://bugs.python.org/issue35005> ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue35005] argparse should accept json and yaml argument types

2018-10-16 Thread Robert Benson
Change by Robert Benson : -- components: Library (Lib) nosy: derelbenkoenig priority: normal severity: normal status: open title: argparse should accept json and yaml argument types type: enhancement ___ Python tracker <https://bugs.python.

[issue35005] argparse should accept json and yaml argument types

2018-10-17 Thread Robert Benson
Robert Benson added the comment: What I'm talking about is reading a single arg (of a dictionary or collection type) that can be split across multiple lines, rather than a single line containing multiple args My motivation was that reading args from a file should behave in a manner similar

[issue35123] Add style guide for sentinel usage

2018-10-31 Thread Robert Wright
New submission from Robert Wright : Sentinel values are used inconsistently in the Python code base. It would be helpful to have a style guide (about eg. casing, placement, and sentinel reuse) to prevent arguments about their use in future code. -- messages: 328984 nosy: madman bob

[issue35124] Add style guide for unit tests

2018-10-31 Thread Robert Wright
New submission from Robert Wright : There should be a style guide for tests, to prevent arguments about their use in future code. -- messages: 328986 nosy: madman bob priority: normal severity: normal status: open title: Add style guide for unit tests

[issue35123] Add style guide for sentinel usage

2018-10-31 Thread Robert Wright
Robert Wright added the comment: Just the classic problems caused by inconsistency in code - confusion when reading, and disagreements when writing. For reading: Where should I look in a file for the sentinels? Is this value a sentinel, or is it some other type of variable? For writing

[issue35145] sqlite3: "select *" should autoconvert datetime fields

2018-11-03 Thread Robert Pollak
Robert Pollak added the comment: Thank you, Paul, for your hints on sniffing. I have now asked at SqliteStudio for confirmation that they also do content sniffing to detect datetime text fields: https://github.com/pawelsalawa/sqlitestudio/issues/3449 . So in this issue I am suggesting

[issue35145] sqlite3: "select *" should optionally autoconvert TEXT datetime fields

2018-11-03 Thread Robert Pollak
Change by Robert Pollak : -- title: sqlite3: "select *" should autoconvert datetime fields -> sqlite3: "select *" should optionally autoconvert TEXT datetime fields ___ Python tracker <https://

[issue35145] sqlite3: "select *" should optionally sniff and autoconvert TEXT datetime fields

2018-11-05 Thread Robert Pollak
Robert Pollak added the comment: I have created the attached sqlite database file (with SQLiteStudio) for testing. I contains a table `t` with a TEXT column `x` and a DATETIME (according to SQLiteStudio) column `y`. The table contains a single row with the value `2018-11-05 12:20:30

[issue35145] sqlite3: "select *" should optionally sniff and autoconvert TEXT datetime fields

2018-11-04 Thread Robert Pollak
Robert Pollak added the comment: Stéphane, your example does not match my use case with unknown table structure. Does everyone agree that such a sniffing is out of scope for sqlite3? That's not what I'd call "batteries included" :-( -- title: sqlite3: "select *&quo

[issue35145] sqlite3: "select *" should autoconvert datetime fields

2018-11-02 Thread Robert Pollak
New submission from Robert Pollak : Currently, fields are converted to datetime as described in https://docs.python.org/3/library/sqlite3.html#sqlite3.PARSE_COLNAMES : 'select x as "x [datetime]" from table' In my use case I don't know the names and locations of the datet

[issue35145] sqlite3: "select *" should autoconvert datetime fields

2018-11-02 Thread Robert Pollak
Robert Pollak added the comment: (In fact, I am currently taking the first non-missing entry of each text column and trying to dateutil.parser.parse it. If that works, I use pandas.to_datetime on the column.) -- ___ Python tracker <ht

[issue35150] Misc/README.valgrind out-of-date

2018-11-02 Thread Robert Henry
New submission from Robert Henry : File Misc/README.valgrind is out of date with respect to python3.8. There are important sections of this file that are 15 years old! Example: the README.valgrind refers to "Uncomment Py_USING_MEMORY_DEBUGGER in Objects/obmalloc.c" b

[issue33074] dbm corrupts index on macOS (_dbm module)

2018-10-29 Thread Robert Xiao
Robert Xiao added the comment: I just started a new project, thoughtlessly decided to use `shelve` to store data, and lost it all again thanks to this bug. To reiterate: Although `gdbm` might fix this issue, it's not installed by default. But the issue is with `dbm`: Python is allowing me

[issue35145] sqlite3: "select *" should optionally sniff and autoconvert TEXT datetime fields

2018-11-05 Thread Robert Pollak
Robert Pollak added the comment: Paul, the sniffing would be only active for people who explicitly add a connect() argument like detect_types=DETECT_DATETIME, which can have the appropriate warning in the docs. You can also extend the sniffing to all values, not just the first non-missing

[issue35123] Add style guide for sentinel usage

2018-11-07 Thread Robert Wright
Robert Wright added the comment: Perhaps there's confusion over what I mean by "style guide". I'd happily take Steven's message *as* the style guide. Or, at the very least, the clarification that sentinels are to be thought of as constants. It's one of those things that's ob

[issue35145] sqlite3: "select *" should optionally sniff and autoconvert TEXT datetime fields

2018-11-06 Thread Robert Pollak
Robert Pollak added the comment: Here is now a reduced version of my real use case: 2017v2-reduced.db. The file was originally created with "Oracle DBConvert". This file contains a table without rows. I was wrong in my last comment: There's also no sniffing needed here, s

[issue24412] setUpClass equivalent for addCleanup

2018-09-27 Thread Robert Collins
Robert Collins added the comment: Serhiy, thats not a design flaw, its a feature. in a class hierarchy, setup and teardown ordering is undefined: implementors can choose whatever order they want to execute in. e.g. class A(TestCase): def setUp(self): super().setUp() acquire1() class B

[issue35145] sqlite3: optionally autoconvert table_info's DATETIME fields

2018-11-18 Thread Robert Pollak
Change by Robert Pollak : -- title: sqlite3: "select *" should optionally sniff and autoconvert TEXT datetime fields -> sqlite3: optionally autoconvert table_info's DATETIME fields ___ Python tracker <https://bugs.pytho

[issue35145] sqlite3: optionally autoconvert table_info's DATETIME fields

2018-11-25 Thread Robert Pollak
Robert Pollak added the comment: So my workaround is of course ``` table = pd.read_sql_query('select * from table', con) column_type = pd.read_sql_query('PRAGMA table_info("table")', con)['type'] datetimes = table.columns[column_type == 'DATETIME'] table.loc[:, datetimes] =

[issue13501] Make libedit support more generic; port readline / libedit to FreeBSD

2019-04-01 Thread Robert Marshall
Robert Marshall added the comment: The pull request is now ready for a review. Apologies for the delay - took me a bit longer to circle back on this than I would have liked. -- ___ Python tracker <https://bugs.python.org/issue13

[issue13501] Make libedit support more generic; port readline / libedit to FreeBSD

2019-02-27 Thread Robert Marshall
Robert Marshall added the comment: I have rebased this to recent master hash 53b9e1a1c1 and submitted a pull request. It built in my CI environment, so seems to be OK as far as compiling. I'll run the test suite against it later this evening when I have time to stand up a quick build

[issue36240] Definitions of time

2019-03-08 Thread Robert Billing
New submission from Robert Billing : https://docs.python.org/3.7/library/time.html contains the text "UTC is Coordinated Universal Time (formerly known as Greenwich Mean Time, or GMT)". This is not strictly true. Referring to https://en.wikipedia.org/wiki/Coordinated_Univ

[issue35970] no help flag in base64 util

2019-02-11 Thread Robert Kuska
New submission from Robert Kuska : I failed today to print help message for base64 utility without an error: $ python3 -m base64 -help option -h not recognized usage: /usr/local/Cellar/python/3.7.2_1/Frameworks/Python.framework/Versions/3.7/lib/python3.7/base64.py [-d|-e|-u|-t] [file

[issue36656] Please add race-free os.link and os.symlink wrapper / helper

2019-06-07 Thread Robert Collins
Robert Collins added the comment: Thank you @Eryk -- ___ Python tracker <https://bugs.python.org/issue36656> ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue36656] Please add race-free os.link and os.symlink wrapper / helper

2019-06-03 Thread Robert Collins
Robert Collins added the comment: I'd like to add a few notes; please do consider Windows interactions here - Windows does not have the same model for inode replacement that Posix has. Secondly, I note that the thread model discussed here hasn't been particular well articulated

[issue37262] Make unittest assertions staticmethods/classmethods

2019-06-13 Thread Robert Collins
Robert Collins added the comment: I think this is strictly redundant with that other ticket and I'm going to close it. That said, they need access to self.failureException. https://docs.python.org/3/library/unittest.html#unittest.TestCase.failureException -- stage: -> resol

[issue19645] decouple unittest assertions from the TestCase class

2019-06-13 Thread Robert Collins
Robert Collins added the comment: Right now that attribute could be set by each test separately, or even varied within a test. TBH I'm not sure that the attribute really should be supported; perhaps thinking about breaking the API is worth doing. But - what are we solving for here. The OP

[issue19645] decouple unittest assertions from the TestCase class

2019-06-13 Thread Robert Collins
Robert Collins added the comment: Sorry for the slow reply here; There are API breaks involved in any decoupling that involves the exception raising because of the failureException attribute. Something with signalling that can be adapted by other test suites etc might have merit, but I

[issue24653] Mock.assert_has_calls([]) is surprising for users

2019-05-22 Thread Robert Collins
Robert Collins added the comment: I'm reopening this because I don't agree. I opened the bug because we have evidence that users find the current documentation confusing. Saying that its not confusing to us doesn't fix the confusion. Why should we mention the special case of an empty set

[issue36994] Missing tests for CALL_FUNCTION_EX opcode profiling method_descriptor

2019-05-22 Thread Robert Collins
Robert Collins added the comment: New changeset b892d3ea468101d35e2fb081002fa693bd86eca9 by Robert Collins (Jeroen Demeyer) in branch 'master': bpo-36994: add test for profiling method_descriptor with **kwargs (GH-13461) https://github.com/python/cpython/commit

[issue34125] Profiling depends on whether **kwargs is given

2019-05-22 Thread Robert Collins
Robert Collins added the comment: New changeset b892d3ea468101d35e2fb081002fa693bd86eca9 by Robert Collins (Jeroen Demeyer) in branch 'master': bpo-36994: add test for profiling method_descriptor with **kwargs (GH-13461) https://github.com/python/cpython/commit

[issue36843] AIX build fails with failure to get random numbers

2019-05-08 Thread Robert Boehne
Change by Robert Boehne : Added file: https://bugs.python.org/file48317/config.log.gz ___ Python tracker <https://bugs.python.org/issue36843> ___ ___ Python-bugs-list m

[issue36843] AIX build fails with failure to get random numbers

2019-05-08 Thread Robert Boehne
Robert Boehne added the comment: from pyconfig.h: /* Define to 1 if the getrandom() function is available */ /* #undef HAVE_GETRANDOM */ /* Define to 1 if the Linux getrandom() syscall is available */ /* #undef HAVE_GETRANDOM_SYSCALL */ /* Define to 1 if you have the header file

[issue36843] AIX build fails with failure to get random numbers

2019-05-08 Thread Robert Boehne
Robert Boehne added the comment: Reading a few bytes from /dev/urandom via dd: robb@nepal:/raid/checkouts-raid/robb/nepal/build-py37$ dd if=/dev/urandom bs=256 count=1 ??S?(#L???~]?B?^??8?f&?_|Vi??@??[joG>St??;?$?1?*??24???RD?"

[issue36843] AIX build fails with failure to get random numbers

2019-05-10 Thread Robert Boehne
Robert Boehne added the comment: It doesn't look good: robb@nepal:/raid/checkouts-raid/robb/nepal$ xlc_r -q64 -O0 -g -qlanglvl=extc1x -o urandom urandom.c robb@nepal:/raid/checkouts-raid/robb/nepal$ ./urandom open O_RDONLY failed open O_RDONLY | O_CLOEXEC failed robb@nepal:/raid/checkouts

[issue36843] AIX build fails with failure to get random numbers

2019-05-10 Thread Robert Boehne
Robert Boehne added the comment: I wonder if there's anyone with AIX 7 who can attempt to reproduce this. We have another AIX machine, but it is down for the moment. I would like to eliminate a problem on this machine as the cause

[issue36843] AIX build fails with failure to get random numbers

2019-05-07 Thread Robert Boehne
Robert Boehne added the comment: robb@nepal:/raid/checkouts-raid/robb/nepal/build-py37$ gmake xlc_r -c -DNDEBUG -O -q64 -qlanglvl=extc99 -IObjects -IInclude -IPython -I. -I../../Python-3.7.3/Include -I/raid/checkouts-raid/robb/Python-2.7.15/Modules/zlib -DPy_BUILD_CORE -o Modules

[issue36843] AIX build fails with failure to get random numbers

2019-05-07 Thread Robert Boehne
New submission from Robert Boehne : build fails with: ./python -E ../../Python-3.7.3/setup.py build Fatal Python error: _Py_HashRandomization_Init: failed to get random numbers to initialize Python -- components: Build messages: 341821 nosy: Robert Boehne priority: normal severity

[issue36843] AIX build fails with failure to get random numbers

2019-05-08 Thread Robert Boehne
Robert Boehne added the comment: The call to open("/dev/urandom", flags) is returning -1, and errno is set to 22, EINVAL - Invalid argument. could the flags be set incorrectly? -- ___ Python tracker <https://bugs.python.o

[issue36843] AIX build fails with failure to get random numbers

2019-05-08 Thread Robert Boehne
Robert Boehne added the comment: Opening /dev/urandom seems to return -1 (dbx) print buffer 0x09001000a5f49380 (dbx) print size 24 (dbx) print raise 0 (dbx) step stopped in dev_urandom at line 311 in file "/raid/checkouts-raid/robb/nepal/build-py37/../../Python-3.7.3/P

[issue26903] ProcessPoolExecutor(max_workers=64) crashes on Windows

2019-04-17 Thread Robert Collins
Robert Collins added the comment: This is now showing up in end user tools like black: https://github.com/ambv/black/issues/564 -- nosy: +rbcollins versions: +Python 3.7, Python 3.8, Python 3.9 ___ Python tracker <https://bugs.python.

[issue26680] Incorporating float.is_integer into the numeric tower and Decimal

2019-08-22 Thread Robert Smallshire
Robert Smallshire added the comment: > * no forward movement for a year and half For most of that year and a half my pull-request was sitting in Github <https://github.com/python/cpython/pull/6121> awaiting review by two core devs, of which you Raymond, were one. I don't like

[issue35145] sqlite3: optionally autoconvert table_info's DATETIME fields

2019-07-25 Thread Robert Pollak
Robert Pollak added the comment: Sorry for not providing a pull request yet. By the way, the "DB Browser for SQLite" (https://sqlitebrowser.org/) also interprets DATETIME fields correctly. (Could someone please change the "Stage" of this issue to "needs patc

[issue38345] Add end lines to pyclbr objects

2019-10-02 Thread Robert Kearns
Change by Robert Kearns : -- components: Library (Lib) nosy: RobertKearns priority: normal severity: normal status: open title: Add end lines to pyclbr objects type: enhancement versions: Python 3.9 ___ Python tracker <https://bugs.python.

[issue38345] Add end lines to pyclbr objects

2019-10-02 Thread Robert Kearns
Change by Robert Kearns : -- keywords: +patch pull_requests: +16124 stage: -> patch review pull_request: https://github.com/python/cpython/pull/16534 ___ Python tracker <https://bugs.python.org/issu

[issue19645] decouple unittest assertions from the TestCase class

2019-07-09 Thread Robert Collins
Change by Robert Collins : -- versions: +Python 3.9 -Python 3.5 ___ Python tracker <https://bugs.python.org/issue19645> ___ ___ Python-bugs-list mailin

[issue19645] decouple unittest assertions from the TestCase class

2019-07-09 Thread Robert Collins
Robert Collins added the comment: Ok so design wise - there is state on the TestCase that influences assertions; in potentially two ways. The first way is formatting - the amount of detail shown in long list comparisons etc. The second way I don't think we have at the moment

[issue19645] decouple unittest assertions from the TestCase class

2019-07-09 Thread Robert Collins
Robert Collins added the comment: Oh, I didn't mean to imply that these are the only options I'd support - just that these are the things I've thought through and that I think will all work well... I'm sure there are more options available

[issue39535] multiprocessing.Process file descriptor resource leak

2020-02-03 Thread Robert Pierce
New submission from Robert Pierce : multiprocessing.Process opens a FIFO to the child. This FIFO is not documented the the Process class API and it's purpose is not clear from the documentation. It is a minor documentation bug that the class creates non-transparent resource utilization

[issue39535] multiprocessing.Process file descriptor resource leak

2020-02-03 Thread Robert Pierce
Robert Pierce added the comment: It appears as if the problem is the sentinel FIFO opened by (for example) multiprocessing.popen_fork.Popen._launch(). It registers a finalization class to close the sentinel on garbage collection. Instead, it should be closed in poll() or wait() when

[issue39318] NamedTemporaryFile could cause double-close on an fd if _TemporaryFileWrapper throws

2020-01-12 Thread Robert Xiao
New submission from Robert Xiao : tempfile.NamedTemporaryFile creates its wrapper like so: try: file = _io.open(fd, mode, buffering=buffering, newline=newline, encoding=encoding, errors=errors) return _TemporaryFileWrapper(file, name, delete

[issue39318] NamedTemporaryFile could cause double-close on an fd if _TemporaryFileWrapper throws

2020-01-15 Thread Robert Xiao
Robert Xiao added the comment: Could this be solvable if `closefd` were a writable attribute? Then we could do file = None try: file = io.open(fd, ..., closefd=False) file.closefd = True except: if file and not file.closefd: os.close(fd

[issue40322] struct.pack adding unexpected byte in 'B' format

2020-04-18 Thread Robert Bressan
New submission from Robert Bressan : struct.pack() is adding an unexpected null byte. When I've run this code: ___ import struct d = {'c':b'a', 'b':1, 'B':1, '?':False, 'h':2, 'H':2, 'i':-3, 'I':3, 'l':4, 'L':4, 'q':5, 'Q':5, 'f':100.0, 'd':2.0} for x

[issue40322] struct.pack adding unexpected byte in 'B' format

2020-04-18 Thread Robert Bressan
Robert Bressan added the comment: After placing a standard size instead of a native one, solved. -- resolution: -> not a bug stage: -> resolved status: open -> closed ___ Python tracker <https://bugs.python.or

[issue40417] PyImport_ReloadModule emits deprecation warning

2020-04-28 Thread Robert Rouhani
New submission from Robert Rouhani : It appears as though PyImport_ReloadModule is importing the deprecated "imp" module. I integrated a newer version of Python into Unreal Engine 4, which internally calls this function for some of it's own modules. Normally a stray warning

[issue40417] PyImport_ReloadModule emits deprecation warning

2020-05-05 Thread Robert Rouhani
Change by Robert Rouhani : -- pull_requests: +19249 pull_request: https://github.com/python/cpython/pull/19934 ___ Python tracker <https://bugs.python.org/issue40

[issue40417] PyImport_ReloadModule emits deprecation warning

2020-05-05 Thread Robert Rouhani
Change by Robert Rouhani : -- pull_requests: +19250 pull_request: https://github.com/python/cpython/pull/19935 ___ Python tracker <https://bugs.python.org/issue40

[issue40417] PyImport_ReloadModule emits deprecation warning

2020-05-05 Thread Robert Rouhani
Robert Rouhani added the comment: No problem! Happy to contribute where I can :) -- ___ Python tracker <https://bugs.python.org/issue40417> ___ ___ Python-bug

[issue40417] PyImport_ReloadModule emits deprecation warning

2020-05-01 Thread Robert Rouhani
Robert Rouhani added the comment: We have a fairly straightforward workaround of using the "warnings" module to redirect to stdout, so we personally don't have a need. Unreal, however, follows the VFX Reference Platform ( https://vfxplatform.com/) which is migrating from 2.

[issue26680] Incorporating float.is_integer into the numeric tower and Decimal

2020-10-06 Thread Robert Smallshire
Robert Smallshire added the comment: First, I would like to apologise for the confusion I have inadvertently caused. I didn't see Raymond's question and Guido's clear response here about not modifying the numeric tower, as it came _long_ after activity had moved to GitHub, and code had been

[issue26680] Incorporating float.is_integer into Decimal

2020-10-08 Thread Robert Smallshire
Robert Smallshire added the comment: Yes Raymond, I can prepare a new PR as soon as the faulty PR has been rolled back. -- ___ Python tracker <https://bugs.python.org/issue26

[issue41878] python3 fails to use custom mapping object as symbols in eval()

2020-09-29 Thread Robert Haschke
Robert Haschke added the comment: Thanks, Josh, for this clarification. What is the suggested mitigation? Obviously, I need to pass all symbols from my hierarchical dictionary in a flattend version as a dict to globals. Or do you see another option

[issue41878] python3 fails to use custom dict-like object as symbols in eval()

2020-09-28 Thread Robert Haschke
New submission from Robert Haschke : The attached file implements a custom dict-like class (MyDict) as a minimal example of code I am using in a larger codebase. Before you ask, why I reimplemented a dict-like object: The real code base employs a hierarchical dict, referencing recursively

[issue41878] python3 fails to use custom mapping object as symbols in eval()

2020-09-28 Thread Robert Haschke
Robert Haschke added the comment: Looks like the list generator is considered as a new nested scope, which prohibits access to local variables? This basic expression, passing local symbols only, fails as well: eval('[abc[i]*abc[i] for i in [0, 1, 2]]', {}, dict(abc=[1, 2, 3])) while

[issue8087] Unupdated source file in traceback

2020-05-28 Thread Robert Reynolds
Robert Reynolds added the comment: A pure python demonstration of the problem looks like this (`__file__` stores the path to the executed module): ```python with open(__file__) as f: src = f.read() with open(__file__, 'w') as f: f.write('\n\n\n\n\n# Whoops! Wrong line!\n

[issue8087] Unupdated source file in traceback

2020-05-28 Thread Robert Reynolds
Robert Reynolds added the comment: I second [what was said by Aigars Mahinovs](https://bugs.python.org/issue8087#msg300990) about long-running processes giving confusing tracebacks that make debugging very difficult. I have a Natural Language Processing pipeline extracting features from

[issue42189] copy.deepcopy() no longer works on platform.uname_result objects

2020-10-28 Thread Robert O'Callahan
New submission from Robert O'Callahan : Starting from Python 3.9, copy.deepcopy can't copy a platform.uname_result object. ``` Python 3.9.0 (default, Oct 6 2020, 00:00:00) [GCC 10.2.1 20200826 (Red Hat 10.2.1-3)] on linux Type "help", "copyright", "credits" or

[issue42163] _replace() no longer works on platform.uname_result objects

2020-10-28 Thread Robert O'Callahan
Robert O'Callahan added the comment: I filed issue 42189, which is similar but maybe worse: copy.deepcopy() is broken for platform.uname_result objects. -- nosy: +rocallahan ___ Python tracker <https://bugs.python.org/issue42

[issue42103] DoS (MemError via CPU and RAM exhaustion) when processing malformed Apple Property List files in binary format

2020-10-20 Thread Robert Wessen
New submission from Robert Wessen : In versions of Python from 3.4-3.10, the Python core plistlib library supports Apple's binary plist format. When given malformed input, the implementation can be forced to create an argument to struct.unpack() which consumes all available CPU and memory

[issue43547] support ZIP files with zeroed out fields (e.g. for reproducible builds)

2021-03-20 Thread Robert Pollak
Change by Robert Pollak : -- nosy: +jondo ___ Python tracker <https://bugs.python.org/issue43547> ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue46231] grammar rule definition is missing: invalid_double_starred_kvpairs

2022-01-02 Thread Robert Einhorn
New submission from Robert Einhorn : Definition of invalid_double_starred_kvpairs PEG grammar rule is not found: https://docs.python.org/3.10/reference/grammar.html # PEG grammar rule: dict: | '{' [double_starred_kvpairs] '}' | '{' invalid_double_starred_kvpairs

[issue46230] NEWLINE* is missing in 'file' rule in PEG grammar

2022-01-02 Thread Robert Einhorn
New submission from Robert Einhorn : https://docs.python.org/3.10/reference/grammar.html # original grammar rule: file: [statements] ENDMARKER # suggested grammar rule: file: NEWLINE* [statements] ENDMARKER -- components: Parser messages: 409524 nosy: RobEin, lys.nikolaou

[issue45948] Unexpected instantiation behavior for xml.etree.ElementTree.XMLParser(target=None)

2021-12-01 Thread Robert Steed
New submission from Robert Steed : Expected instantiation of xml.etree.ElementTree.XMLParser(target=None) to create a parser using default TreeBuilder -- components: XML files: XMLParserFail.py messages: 407458 nosy: rdsteed priority: normal severity: normal status: open title

[issue46865] *() Invalid Syntax: iterable unpacking of empty tuple

2022-02-26 Thread Robert Spralja
Robert Spralja added the comment: I understand that it's invalid synatax, but not why. On Sat, 26 Feb 2022 at 10:07, Serhiy Storchaka wrote: > > Serhiy Storchaka added the comment: > > It is an invalid syntax. Write foo(*((stri,) if stri else ())). > > -- > no

[issue46865] *() Invalid Syntax: iterable unpacking of empty tuple

2022-02-26 Thread Robert Spralja
New submission from Robert Spralja : ` >>> def foo(num=1): ... return num ... >>> foo(*(bool,) is bool else *()) File "", line 1 foo(*(bool,) is bool else *()) ^ SyntaxError: invalid syntax >>> foo(*(bool,) if bool else

[issue46548] macOS installers cannot be signed on Monterey

2022-01-27 Thread Robert Xiao
Robert Xiao added the comment: I noticed that the official installer seems to be built using an entirely different process, as it produces a single-file .pkg in xar format with an embedded Distribution file, rather than an .mpkg directory. Is there documentation on how these packages

[issue46548] macOS installers cannot be signed on Monterey

2022-01-27 Thread Robert Xiao
New submission from Robert Xiao : I am building unofficial macOS packages for personal use. My main build machine is running macOS Monterey 12.1 and Xcode 13.2.1. I recently attempted to build Python 3.8.12 as a package using build-installer.py. This worked fine after a bit of dependency

[issue46548] macOS installers cannot be signed on Monterey

2022-01-27 Thread Robert Xiao
Change by Robert Xiao : -- type: -> behavior ___ Python tracker <https://bugs.python.org/issue46548> ___ ___ Python-bugs-list mailing list Unsubscrib

[issue46485] ~ PEG operator in the grammar

2022-01-23 Thread Robert Einhorn
New submission from Robert Einhorn : This is probably not an error and I may misinterpret the PEP 617, but I don't know what the ~ PEG operator means in the next rule if there is no alternative: assignment_expression: | NAME ':=' ~ expression And similarly with this rule

[issue46485] ~ PEG operator in the grammar

2022-01-23 Thread Robert Einhorn
Robert Einhorn added the comment: Thanks -- resolution: not a bug -> status: closed -> open ___ Python tracker <https://bugs.python.org/issue46485> ___ __

[issue1159] os.getenv() not updated after external module uses C putenv()

2007-09-13 Thread Robert Ancell
New submission from Robert Ancell: The Python os.getenv() function accesses an Python dictionary which is mirroring the process environment. This dictionary is populated when the interpreter starts and updated when os.environ.__setitem__() or os.putenv() are called. However if the python program

[issue1159] os.getenv() not updated after external module uses C putenv()

2007-09-13 Thread Robert Ancell
Robert Ancell added the comment: draghuram, unfortunately while os.putenv() can be fixed to be symmetrical any putenv call from a C module cannot, for example: If you make an extension: #include stdlib.h PyObject *putenvC(PyObject *module, PyObject *args) { int result

[issue1159] os.getenv() not updated after external module uses C putenv()

2007-09-13 Thread Robert Ancell
Robert Ancell added the comment: I've attached proof-of-concept showing how os.environ would ideally work. It'll only work in Posix, etc etc. Reading into it more there are a lot of general issues with environments and memory allocation which is why I suspect Python doesn't use putenv... See

[issue10598] curses fails to import on Solaris

2010-12-02 Thread Robert Lehmann
Robert Lehmann lehman...@gmail.com added the comment: I have attached a fix and a regression test. -- keywords: +patch nosy: +lehmannro Added file: http://bugs.python.org/file19903/issue10598.patch ___ Python tracker rep...@bugs.python.org http

[issue10562] Change 'j' for imaginary unit into an 'i'

2010-12-03 Thread Robert Lehmann
Robert Lehmann lehman...@gmail.com added the comment: I wonder whether there are many examples where scientific data is written in a form that Python's complex() constructor couldn't currently read, but would be able to read if it accepted 'i' in place of 'j'. I could not reproduce

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