[issue40777] _datetimemodule.c:3328:16: error: initializer element is not constant

2020-05-28 Thread miss-islington
miss-islington added the comment: New changeset 459acc551656785bc4a3363d65c7a60f822da8e3 by Petr Viktorin in branch 'master': bpo-40777: Initialize PyDateTime_IsoCalendarDateType.tp_base at run-time (GH-20493) https://github.com/python/cpython/commit/459acc551656785bc4a3363d65c7a60f822da8e3

[issue37878] Sub-Interpreters : Document PyThreadState_DeleteCurrent()

2020-05-28 Thread miss-islington
Change by miss-islington : -- nosy: +miss-islington nosy_count: 6.0 -> 7.0 pull_requests: +19745 pull_request: https://github.com/python/cpython/pull/20496 ___ Python tracker _

[issue37878] Sub-Interpreters : Document PyThreadState_DeleteCurrent()

2020-05-28 Thread STINNER Victor
STINNER Victor added the comment: New changeset fda7f6d61b13c68f59806db674e892fda4013348 by Victor Stinner in branch 'master': bpo-37878: PyThreadState_DeleteCurrent() was not removed (GH-20489) https://github.com/python/cpython/commit/fda7f6d61b13c68f59806db674e892fda4013348 -- __

[issue37878] Sub-Interpreters : Document PyThreadState_DeleteCurrent()

2020-05-28 Thread STINNER Victor
STINNER Victor added the comment: I was very confused by the history of this issue. To be clear, PyThreadState_DeleteCurrent() is now documented in Python 3.9: https://docs.python.org/dev/c-api/init.html#c.PyThreadState_DeleteCurrent -- ___ Python

[issue1294959] Add sys.platlibdir and configure --with-platlibdir to use /usr/lib64 on Fedora and SuSE

2020-05-28 Thread miss-islington
Change by miss-islington : -- pull_requests: +19746 pull_request: https://github.com/python/cpython/pull/20497 ___ Python tracker ___

[issue1294959] Add sys.platlibdir and configure --with-platlibdir to use /usr/lib64 on Fedora and SuSE

2020-05-28 Thread STINNER Victor
STINNER Victor added the comment: New changeset 242d95659b6b4ff4fb54b58a30454dafa311d4e9 by Michał Górny in branch 'master': bpo-1294959: Try to clarify the meaning of platlibdir (GH-20332) https://github.com/python/cpython/commit/242d95659b6b4ff4fb54b58a30454dafa311d4e9 --

[issue40809] list.Count() isn't working as expected for the series of same numbers in a list

2020-05-28 Thread chirag maliwal
New submission from chirag maliwal : a = [1,1,1,1] for i in a: if a.count(i) > 1: a.remove(i) print(a) """ Output: [1,1] expected: [1] """ -- files: test.py messages: 370239 nosy: cmaliwal priority: normal severity: normal status: open title: list.Count() isn't workin

[issue37878] Sub-Interpreters : Document PyThreadState_DeleteCurrent()

2020-05-28 Thread miss-islington
miss-islington added the comment: New changeset 6a478641c00e5a52be9d595ad804bf848a498d96 by Miss Islington (bot) in branch '3.9': bpo-37878: PyThreadState_DeleteCurrent() was not removed (GH-20489) https://github.com/python/cpython/commit/6a478641c00e5a52be9d595ad804bf848a498d96 --

[issue40809] list.count() isn't working as expected for the series of same numbers in a list

2020-05-28 Thread chirag maliwal
Change by chirag maliwal : -- title: list.Count() isn't working as expected for the series of same numbers in a list -> list.count() isn't working as expected for the series of same numbers in a list ___ Python tracker

[issue40809] list.Count() isn't working as expected for the series of same numbers in a list

2020-05-28 Thread Rémi Lapeyre
Rémi Lapeyre added the comment: Hi cmaliwal! You are mutating the list while iterating over it which can lead to all sorts of issues, to keep the unique elements of a list you can do >>> a = [1, 1, 1, 1] >>> list(set(a)) [1] If you think you found a bug in Python please check in the python

[issue1294959] Add sys.platlibdir and configure --with-platlibdir to use /usr/lib64 on Fedora and SuSE

2020-05-28 Thread miss-islington
miss-islington added the comment: New changeset a5936ad6323b2cda712726a25d9301f766146cff by Miss Islington (bot) in branch '3.9': bpo-1294959: Try to clarify the meaning of platlibdir (GH-20332) https://github.com/python/cpython/commit/a5936ad6323b2cda712726a25d9301f766146cff -- __

[issue40777] _datetimemodule.c:3328:16: error: initializer element is not constant

2020-05-28 Thread miss-islington
miss-islington added the comment: New changeset eceee544de4b0f885729022c135c53291b6bbb23 by Miss Islington (bot) in branch '3.9': [3.9] bpo-40777: Initialize PyDateTime_IsoCalendarDateType.tp_base at run-time (GH-20493) (GH-20495) https://github.com/python/cpython/commit/eceee544de4b0f885729

[issue40801] Expose PyFloat_ToDouble at Python level: operator.as_float?

2020-05-28 Thread Mark Dickinson
Mark Dickinson added the comment: > `operator` seems a slightly odd place for this. Yes, it's not ideal. It's by analogy with operator.index, which provides the equivalent duck-typing for integers, and calls __index__. Similarly, operator.as_float is primarily there to call __float__, excep

[issue40809] list.Count() isn't working as expected for the series of same numbers in a list

2020-05-28 Thread chirag maliwal
chirag maliwal added the comment: a = [0, 1, 2, 3, 4, 1, 2, 3, 5] for i in a: if a.count(i) > 1: a.remove(i) print(a) """ Output [0, 4, 1, 2, 3, 5] """ It's working fine for the above code. Yes I can use set for this but I tried with count and remove. -- _

[issue40806] itertools.product not lazy

2020-05-28 Thread miss-islington
Change by miss-islington : -- nosy: +miss-islington nosy_count: 4.0 -> 5.0 pull_requests: +19747 pull_request: https://github.com/python/cpython/pull/20498 ___ Python tracker _

[issue40801] Expose PyFloat_ToDouble at Python level: operator.as_float?

2020-05-28 Thread Mark Dickinson
Mark Dickinson added the comment: On naming, maybe float.from_number or float.from_numeric? -- ___ Python tracker ___ ___ Python-bu

[issue1294959] Add sys.platlibdir and configure --with-platlibdir to use /usr/lib64 on Fedora and SuSE

2020-05-28 Thread Michał Górny
Michał Górny added the comment: Thank you! -- ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.

[issue40806] itertools.product not lazy

2020-05-28 Thread Raymond Hettinger
Raymond Hettinger added the comment: New changeset cfc6ce4d40f2f01314b7e283fb972a7bb3ed3faa by Ramil Nugmanov in branch 'master': bpo-40806: Clarify that itertools.product immediately consumes its inpt (GH-20492) https://github.com/python/cpython/commit/cfc6ce4d40f2f01314b7e283fb972a7bb3ed3f

[issue40806] itertools.product not lazy

2020-05-28 Thread Raymond Hettinger
Raymond Hettinger added the comment: Updated the docs to note that inputs are fully consumed before the iterator is run. FYI, notes on infinite iterable inputs likely belong the FAQs because they aren't specific to product(). Similar effects would be seen with list(x(1)), sorted(x(1)), set

[issue40806] itertools.product not lazy

2020-05-28 Thread Raymond Hettinger
Raymond Hettinger added the comment: New changeset e4cc3a7c1f5ba9ea2c3015a5bf09cb5b93db5d47 by Miss Islington (bot) in branch '3.9': bpo-40806: itertools.product immediately consumes its inputs (GH-20492) (GH-20498) https://github.com/python/cpython/commit/e4cc3a7c1f5ba9ea2c3015a5bf09cb5b93d

[issue40809] list.Count() isn't working as expected for the series of same numbers in a list

2020-05-28 Thread Steven D'Aprano
Steven D'Aprano added the comment: Rémi is correct, this is not a bug. The problem isn't with list.count. If you print list.count each time through the loop, you will see that it is working perfectly. The problem is that you are modifying the list as you are iterating over it. That means th

[issue40809] list.Count() isn't working as expected for the series of same numbers in a list

2020-05-28 Thread Steven D'Aprano
Steven D'Aprano added the comment: Typo: "on each step, you delete one item from the from and step forward" Should be, you delete one item from the FRONT and step forward. -- ___ Python tracker ___

[issue40801] Expose PyFloat_AsDouble at Python level: operator.as_float?

2020-05-28 Thread Serhiy Storchaka
Change by Serhiy Storchaka : -- title: Expose PyFloat_ToDouble at Python level: operator.as_float? -> Expose PyFloat_AsDouble at Python level: operator.as_float? ___ Python tracker __

[issue40801] Expose PyFloat_ToDouble at Python level: operator.as_float?

2020-05-28 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: I think an alternative constructor is the best option. Some time ago I proposed to add more alternative constructors: https://mail.python.org/archives/list/python-id...@python.org/thread/5JKQMIC6EUVCD7IBWMRHY7DRTTNSBOWG/ -- ___

[issue40358] pathlib's relative_to should behave like os.path.relpath

2020-05-28 Thread Domenico Ragusa
Domenico Ragusa added the comment: I've solved the conflicts with GH-19611 (bpo-23082: Better error message for PurePath.relative_to() from pathlib) that was merged in the mean time and improved the documentation. Everything appears to be in order, can you take a look at it? -- vers

[issue40801] Expose PyFloat_AsDouble at Python level: operator.as_float?

2020-05-28 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: The problem with the roundtrip PyFloat_FromDouble(PyFloat_AsDouble(obj)) is that (in contrary to PyNumber_Index()) it is lossy. Converting Decimal, Fraction, float128 to float before using it in expression can lead to loss of precision. So such conversion

[issue40810] sqlite3 test CheckTraceCallbackContent fails for sqlite v3.7.3 through 3.7.14.1

2020-05-28 Thread Erlend Egeberg Aasland
New submission from Erlend Egeberg Aasland : `CheckTraceCallbackContent()` in `Lib/sqlite3/test/hooks.py` fails for SQLite versions 3.7.3 through 3.7.14.1, apparently because of an SQLite bug that was fixed in 3.7.15 (2012-12-12). Extract from the changelog https://sqlite.org/changes.html: ``

[issue40811] Allow to create new Event Loops on Threads

2020-05-28 Thread Christian Exposito
New submission from Christian Exposito : Right now, Async IO module is not automatically creating a new event loop on threads that are not the main thread (https://github.com/python/cpython/blob/master/Lib/asyncio/events.py#L638), but it should be interesting to do it. For example, WSGI appli

[issue40811] Allow to create new Event Loops on Threads

2020-05-28 Thread Roundup Robot
Change by Roundup Robot : -- keywords: +patch nosy: +python-dev nosy_count: 3.0 -> 4.0 pull_requests: +19748 stage: -> patch review pull_request: https://github.com/python/cpython/pull/20500 ___ Python tracker _

[issue40801] Expose PyFloat_AsDouble at Python level: operator.as_float?

2020-05-28 Thread Mark Dickinson
Mark Dickinson added the comment: > So such conversion looks to me less useful than operator.index(). That may be true, but it's still useful, and currently very hard to write without core Python support. The problem is that duck-typing for something float-like is easy and widespread in the

[issue40801] Expose PyFloat_AsDouble at Python level: operator.as_float?

2020-05-28 Thread Mark Dickinson
Mark Dickinson added the comment: > Converting Decimal, Fraction, float128 to float before using it in expression > can lead to loss of precision. My experience is that this loss of precision is hardly ever a practical problem in the real world of scientific development; in practice floating

[issue40474] Code coverage report not entirely accurate

2020-05-28 Thread Brett Cannon
Brett Cannon added the comment: New changeset d9c1f1991969e99791de75b2bc935e6445bc5dcd by lrjball in branch 'master': bpo-40474: Updated coverage.yml to better report coverage stats (#19851) https://github.com/python/cpython/commit/d9c1f1991969e99791de75b2bc935e6445bc5dcd -- nosy: +

[issue40474] Code coverage report not entirely accurate

2020-05-28 Thread Brett Cannon
Change by Brett Cannon : -- resolution: -> fixed stage: patch review -> resolved status: open -> closed ___ Python tracker ___ ___

[issue40811] Allow to create new Event Loops on Threads

2020-05-28 Thread Christian Heimes
Christian Heimes added the comment: The default policy of asyncio deliberately limits automatic creation of event loops to the main thread. You can't just mix asyncio with a threaded web application and expect it to work correctly. See https://github.com/python/cpython/blob/a487a39dca4c4130

[issue34931] os.path.splitext with more dots

2020-05-28 Thread Malcolm Smith
Malcolm Smith added the comment: > Try for example create/rename .somename.jpg file in Ubuntu. > It is normal image with .jpg extension. You could open it etc. > > You can't use standard python splitext() function to detect extension. Yes you can (Python 3.8.2): >>> splitext(".somename.jpg")

[issue40810] sqlite3 test CheckTraceCallbackContent fails for sqlite v3.7.3 through 3.7.14.1

2020-05-28 Thread Erlend Egeberg Aasland
Change by Erlend Egeberg Aasland : -- nosy: +berker.peksag ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: ht

[issue40744] Explicitly drop support for SQLite version < 3.7.3

2020-05-28 Thread Erlend Egeberg Aasland
Change by Erlend Egeberg Aasland : -- nosy: +berker.peksag ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: ht

[issue40810] sqlite3 test CheckTraceCallbackContent fails for sqlite v3.7.3 through 3.7.14.1

2020-05-28 Thread Erlend Egeberg Aasland
Erlend Egeberg Aasland added the comment: Also related to bpo-26187 -- ___ Python tracker ___ ___ Python-bugs-list mailing list Uns

[issue40810] sqlite3 test CheckTraceCallbackContent fails for sqlite v3.7.3 through 3.7.14.1

2020-05-28 Thread Christian Heimes
Christian Heimes added the comment: Could you please check https://distrowatch.com/ and verify that all major Linux distributions have a sufficient version of sqlite. Please also check LTS like Debian oldstable, Ubuntu, and CentOS. -- nosy: +christian.heimes

[issue9338] argparse optionals with nargs='?', '*' or '+' can't be followed by positionals

2020-05-28 Thread Raymond Hettinger
Raymond Hettinger added the comment: Paul, do you have any thoughts on this one. ISTM that this issue isn't well suited for a newcomer because it's somewhat complex and it isn't clear what if anything should be done. -- nosy: +rhettinger priority: high -> normal

[issue40810] sqlite3 test CheckTraceCallbackContent fails for sqlite v3.7.3 through 3.7.14.1

2020-05-28 Thread Erlend Egeberg Aasland
Erlend Egeberg Aasland added the comment: Debian oldstable (jessie) has sqlite 3.8.7.1 Ubuntu 14.04 LTS (trusty) has sqlite 3.8.2 CentOS 7 and 8 has sqlite versions > 3.7.15 The following distributions include sqlite version _less than_ 3.7.15: • Porteus (release v2.1 and older) • OLPC OS • Har

[issue39685] Python 3.8 regression Socket operation on non-socket

2020-05-28 Thread Brian May
Brian May added the comment: Consensus seems to be that this is a bug in sshuttle, not a bug in python. Thanks for the feedback. I think this bug can be closed now... -- ___ Python tracker

[issue39685] Python 3.8 regression Socket operation on non-socket

2020-05-28 Thread Christian Heimes
Change by Christian Heimes : -- resolution: -> third party stage: -> resolved status: open -> closed type: -> behavior ___ Python tracker ___ ___

[issue30064] BaseSelectorEventLoop.sock_{recv, sendall}() don't remove their callbacks when canceled

2020-05-28 Thread Yury Selivanov
Yury Selivanov added the comment: New changeset dc4eee9e266267498a6b783a0abccc23c06f2b87 by Fantix King in branch 'master': bpo-30064: Properly skip unstable loop.sock_connect() racing test (GH-20494) https://github.com/python/cpython/commit/dc4eee9e266267498a6b783a0abccc23c06f2b87

[issue30064] BaseSelectorEventLoop.sock_{recv, sendall}() don't remove their callbacks when canceled

2020-05-28 Thread miss-islington
Change by miss-islington : -- pull_requests: +19749 pull_request: https://github.com/python/cpython/pull/20503 ___ Python tracker ___ __

[issue30064] BaseSelectorEventLoop.sock_{recv, sendall}() don't remove their callbacks when canceled

2020-05-28 Thread miss-islington
miss-islington added the comment: New changeset 6637bd45163024f2187e40d2cc12c473f78bf5da by Miss Islington (bot) in branch '3.9': bpo-30064: Properly skip unstable loop.sock_connect() racing test (GH-20494) https://github.com/python/cpython/commit/6637bd45163024f2187e40d2cc12c473f78bf5da --

[issue40770] RFE: Run linkchecker on documentation on the CI

2020-05-28 Thread Ned Deily
Change by Ned Deily : -- nosy: +mdk ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/m

[issue40770] RFE: Run linkchecker on documentation on the CI

2020-05-28 Thread Ned Deily
Ned Deily added the comment: I think our CI checks already take too long to run and use possibly more than our fair share of global open source resources (provided by GitHub, Travis, MS Azure) especially considering how infrequently you would expect to find a problem and the low severity of

[issue40810] sqlite3 test CheckTraceCallbackContent fails for sqlite v3.7.3 through 3.7.14.1

2020-05-28 Thread Berker Peksag
Berker Peksag added the comment: +1 for dropping support for < 3.7.15 in master. We should fix or skip tests in maintenance branches. -- stage: -> needs patch type: -> enhancement ___ Python tracker _

[issue40784] test_sqlite: CheckFuncDeterministic() fails with SQLite 3.32

2020-05-28 Thread Berker Peksag
Berker Peksag added the comment: New changeset c610d970f5373b143bf5f5900d4645e6a90fb460 by Erlend Egeberg Aasland in branch 'master': bpo-40784: Fix sqlite3 deterministic test (GH-20448) https://github.com/python/cpython/commit/c610d970f5373b143bf5f5900d4645e6a90fb460 -- nosy: +berk

[issue40784] test_sqlite: CheckFuncDeterministic() fails with SQLite 3.32

2020-05-28 Thread Berker Peksag
Change by Berker Peksag : -- resolution: -> fixed stage: patch review -> resolved status: open -> closed type: -> behavior ___ Python tracker ___

[issue37218] Default hmac.new() digestmod has not been removed from documentation

2020-05-28 Thread Cheryl Sabella
Cheryl Sabella added the comment: The wording for this was fixed with the PR for #33604. -- nosy: +cheryl.sabella resolution: -> duplicate stage: patch review -> resolved status: open -> closed superseder: -> HMAC default to MD5 marked as to be removed in 3.6 ___

[issue25567] shlex.quote doesn't work on bytestrings

2020-05-28 Thread Cheryl Sabella
Cheryl Sabella added the comment: The first pull request has been closed, so this issue is available to be worked on. If the original patch or PR are used, please credit the original authors. Thanks! -- nosy: +cheryl.sabella versions: +Python 3.10 -Python 3.6 _

[issue37198] _parse_localename fail to parse 'en_IL'

2020-05-28 Thread Cheryl Sabella
Change by Cheryl Sabella : -- stage: patch review -> needs patch versions: +Python 3.10 -Python 2.7 ___ Python tracker ___ ___ Pytho

[issue36207] robotsparser deny all with some rules

2020-05-28 Thread mathias44
mathias44 added the comment: I can't display my robot.TXT. I want to ban robots https://ereputation-dereferencement.fr/ -- nosy: +mathias44 ___ Python tracker ___ ___

[issue39040] Wrong attachement filename when mail mime header was too long

2020-05-28 Thread miss-islington
Change by miss-islington : -- nosy: +miss-islington nosy_count: 4.0 -> 5.0 pull_requests: +19750 pull_request: https://github.com/python/cpython/pull/20504 ___ Python tracker _

[issue39040] Wrong attachement filename when mail mime header was too long

2020-05-28 Thread miss-islington
Change by miss-islington : -- pull_requests: +19752 pull_request: https://github.com/python/cpython/pull/20506 ___ Python tracker ___ __

[issue39040] Wrong attachement filename when mail mime header was too long

2020-05-28 Thread miss-islington
Change by miss-islington : -- pull_requests: +19751 pull_request: https://github.com/python/cpython/pull/20505 ___ Python tracker ___ __

[issue39040] Wrong attachement filename when mail mime header was too long

2020-05-28 Thread R. David Murray
R. David Murray added the comment: New changeset 21017ed904f734be9f195ae1274eb81426a9e776 by Abhilash Raj in branch 'master': bpo-39040: Fix parsing of email mime headers with whitespace between encoded-words. (gh-17620) https://github.com/python/cpython/commit/21017ed904f734be9f195ae1274eb8

[issue39189] Use io.DEFAULT_BUFFER_SIZE for filecmp BUFSIZE variable

2020-05-28 Thread Benjamin Peterson
Benjamin Peterson added the comment: Is there some reason a priori that these constants should be defined to be the same rather than being the same coincidentally? -- nosy: +benjamin.peterson ___ Python tracker

[issue40810] sqlite3 test CheckTraceCallbackContent fails for sqlite v3.7.3 through 3.7.14.1

2020-05-28 Thread Erlend Egeberg Aasland
Erlend Egeberg Aasland added the comment: All right, will do, Berker Persag. -- ___ Python tracker ___ ___ Python-bugs-list mailing

[issue40810] sqlite3 test CheckTraceCallbackContent fails for sqlite v3.7.3 through 3.7.14.1

2020-05-28 Thread Erlend Egeberg Aasland
Change by Erlend Egeberg Aasland : -- keywords: +patch pull_requests: +19753 stage: needs patch -> patch review pull_request: https://github.com/python/cpython/pull/20330 ___ Python tracker __

<    1   2