Re: [Python-Dev] PEP 594: update 1
On Tue, May 21, 2019 at 7:11 PM Christian Heimes wrote: > > On 21/05/2019 17.31, Antoine Pitrou wrote: > > > > As I said, if the main annoyance with nntplib is the sporadic test > > failures, then the relevant tests can be disabled on CI. > > > > NNTP itself is still used, even if less and less. > > I don't like the idea to drop a third of the test cases for nntplib -- and > the 30% that actually test that Python's NNTP library can talk to an actual > NNTP server. IMHO it's more beneficial for core development and for nntplib > to have it maintained by somebody that cares about the library. https://github.com/python/cpython/pull/9461 should fix most of the annoyances with test_nntplib. It uses a local server instead of an external one. --Berker ___ Python-Dev mailing list Python-Dev@python.org https://mail.python.org/mailman/listinfo/python-dev Unsubscribe: https://mail.python.org/mailman/options/python-dev/archive%40mail-archive.com
Re: [Python-Dev] Any core dev event plans for EP19?
On Fri, Apr 26, 2019 at 1:01 AM Stefan Behnel wrote: > there are several core dev events happening at the US PyCon this year, so I > was wondering if we could organise something similar at EuroPython. Does > anyone have any plans or ideas already? And, how many of us are planning to > attend EP19 in Basel this year? Unless there's something already going on > that I missed, I can (try to) set up a poll on dpo to count the interest > and collect ideas. Note that this year's core dev sprint will be held in London. See https://discuss.python.org/t/2019-core-dev-sprint-location-date/489 for the previous discussion. There are only two months between both events, so perhaps we can leave things like discussions on active PEPs to the core dev sprint? (And welcome to the team!) --Berker ___ Python-Dev mailing list Python-Dev@python.org https://mail.python.org/mailman/listinfo/python-dev Unsubscribe: https://mail.python.org/mailman/options/python-dev/archive%40mail-archive.com
Re: [Python-Dev] Workflow blocked on the 3.6 because of AppVeyor; who owns the AppVeyor project?
On Wed, Sep 5, 2018 at 12:55 PM Victor Stinner wrote: > > Hi, > > It's no longer possible to merge any change in the 3.6 branch of > CPython, because the AppVeyor job fails: > https://bugs.python.org/issue34575 > > It seems like AppVeyor has a build cache and this cache is outdated. I > tried to use the REST API but I'm not allowed to invalidate the cache: > even the most basic REST API query (list my own roles) fails with: > > {"message":"You do not have required permissions to perform this action."} > > Who ows the "python" AppVeyor project? Can someone please give me the > administrator permission on this project, so I will be able to invalid > the build cache? > > Moreover, would it be possible to give me the administrator permission > on the CPython GitHub project, so I would be able to mark the AppVeyor > as optional until the issue is solved (to unblock the workflow at > least)? I promise I will not mess up the Python project ;-) I've just made the "continuous-integration/appveyor/pr" status check optional on the 3.6 branch to unblock the development for now. Indeed, AppVeyor's REST API doesn't work: $ curl -H "Authorization: Bearer $APPVEYOR_TOKEN" -H "Content-Type: application/json" -X DELETE https://ci.appveyor.com/api/projects/python/cpython/buildcache {"message":"You do not have required permissions to perform this action."} I'm going to try to make you an admin on python/cpython, but I find GitHub's user/team management UI a bit confusing, so no promise :) --Berker ___ Python-Dev mailing list Python-Dev@python.org https://mail.python.org/mailman/listinfo/python-dev Unsubscribe: https://mail.python.org/mailman/options/python-dev/archive%40mail-archive.com
Re: [Python-Dev] make patchcheck and git path
On Fri, Aug 24, 2018 at 1:22 PM Michael wrote: > > I am trying to be a 'good scout' and run "make patchcheck" more > regularly. However, I generally am not successful because I build and > test in separate directories. There is an open issue about supporting out-of-tree builds: https://bugs.python.org/issue32256 --Berker ___ Python-Dev mailing list Python-Dev@python.org https://mail.python.org/mailman/listinfo/python-dev Unsubscribe: https://mail.python.org/mailman/options/python-dev/archive%40mail-archive.com
Re: [Python-Dev] Using Python on a fork-less POSIX-like OS
On Sun, Jul 29, 2018 at 5:44 PM, Barath Aron wrote: > My question is that the _posixsubprocess.c can be prepared to use > posix_spawn(3) instead of fork(2)? Maybe the UNIX/Linux version can also > benefit from it, see: > https://salsa.debian.org/ruby-team/ruby-posix-spawn There is an open issue to add os.posix_spawn() at https://bugs.python.org/issue20104 --Berker ___ Python-Dev mailing list Python-Dev@python.org https://mail.python.org/mailman/listinfo/python-dev Unsubscribe: https://mail.python.org/mailman/options/python-dev/archive%40mail-archive.com
Re: [Python-Dev] Call for prudence about PEP-572
On Mon, Jul 9, 2018 at 8:54 AM, Tim Peters wrote: > [Eric V. Smith] >> >> > there is at least one place >> >> > where the grammar does forbid you from doing something that would >> > otherwise make be allowable: decorators. > > > [Greg Ewing] >> >> And that was a controversial issue at the time. I don't remember >> >> there being much of an objective argument for the restriction -- >> it was more or less a matter of "Guido wanted it that way". > > > Start here: > > https://mail.python.org/pipermail/python-dev/2004-August/046711.html There is also an open issue about removing that restriction: https://bugs.python.org/issue19660 https://bugs.python.org/file32745/decorator-syntax.patch removes a test that raises SyntaxError for the following snippet: @x[3] def foo(): pass --Berker ___ Python-Dev mailing list Python-Dev@python.org https://mail.python.org/mailman/listinfo/python-dev Unsubscribe: https://mail.python.org/mailman/options/python-dev/archive%40mail-archive.com
Re: [Python-Dev] Timeline for Pull request reviews in 3.8
On Fri, Apr 6, 2018 at 7:32 PM, Anthony Flury via Python-Devwrote: > All, > > The three pull requests are : > > Python 2.7 - doc string fix : https://github.com/python/cpython/pull/6015 > > Python 3.8 - documentation fix : https://github.com/python/cpython/pull/5982 Hi Anthony, I've just reviewed this. > Python 3.8 - Small bug fix on unittest.mock.mock_open : > https://github.com/python/cpython/pull/5974 > > The Py2.7 change does not need to be rolled forward to Python3 documentation > > The two Py3.8 fixes could/should/can ? be backported to earlier versions Yes, PR 5982 will be backported to 3.6 and 3.7. I'm not sure about PR 5974 though (I may be wrong because I don't have the time to triage the issue at the moment) --Berker ___ Python-Dev mailing list Python-Dev@python.org https://mail.python.org/mailman/listinfo/python-dev Unsubscribe: https://mail.python.org/mailman/options/python-dev/archive%40mail-archive.com
Re: [Python-Dev] GH-NNNN vs #NNNN in merge commit
On Fri, Jan 26, 2018 at 12:09 AM, Terry Reedywrote: > On 1/25/2018 1:53 PM, Brett Cannon wrote: > >> I would assume it would just go into miss-islington, but before we get >> ahead of ourselves and design this we need to get consensus that people like >> the overall idea of using a bot to do a main commits as well. > > > I strongly dislike any idea of making me do more error-prone work when > merging. The whole point of writing a bot is to automatize the steps listed at https://devguide.python.org/gitbootcamp/#accepting-and-merging-a-pull-request and https://devguide.python.org/gitbootcamp/#backporting-merged-changes so you won't have to do bunch of manual edits before pressing the "Confirm squash and merge" button. --Berker ___ Python-Dev mailing list Python-Dev@python.org https://mail.python.org/mailman/listinfo/python-dev Unsubscribe: https://mail.python.org/mailman/options/python-dev/archive%40mail-archive.com
Re: [Python-Dev] GH-NNNN vs #NNNN in merge commit
On Thu, Jan 25, 2018 at 11:50 PM, Terry Reedywrote: > On 1/25/2018 1:03 PM, Mariatta Wijaya wrote: > >> One idea is maybe have a bot to do the squash commit, for example by >> commenting on GitHub: >> @merge-bot merge > > >> So core devs can do the above instead of pressing the commit button. Any >> thoughts on this? > > > I can hardly believe that you are seriously proposing that I should replace > a click with a 16 char prefix and then retype the title and message. Did I > misunderstand? If I understand Mariatta correctly, you can just left a "@merge-bot merge" comment if you're happy with the commit message. Then the bot itself can replace # with GH-, clean the body of the commit message from commits like "* fix typo", squash commits, and merge. --Berker ___ Python-Dev mailing list Python-Dev@python.org https://mail.python.org/mailman/listinfo/python-dev Unsubscribe: https://mail.python.org/mailman/options/python-dev/archive%40mail-archive.com
Re: [Python-Dev] GH-NNNN vs #NNNN in merge commit
On Thu, Jan 25, 2018 at 9:38 PM, Mariatta Wijayawrote: >> That would be best solution (I think it would solve >> https://github.com/python/miss-islington/issues/16 too) but it's more >> complicated than the extension idea :) I have some time work on it if >> you'd like to implement the mergebot idea. > > > +1 for the mergebot! :) > > New bot or miss-islington's new job? > > Still +1 either way, as long as other core devs are fine with it too :) I'm not familiar with miss-islington's codebase. Can we reuse some parts of miss-islington in the new bot? If we can, let's implement it in miss-islington (perhaps as a new mode?) --Berker ___ Python-Dev mailing list Python-Dev@python.org https://mail.python.org/mailman/listinfo/python-dev Unsubscribe: https://mail.python.org/mailman/options/python-dev/archive%40mail-archive.com
Re: [Python-Dev] GH-NNNN vs #NNNN in merge commit
On Thu, Jan 25, 2018 at 9:03 PM, Mariatta Wijayawrote: >> Of course, we would still need to convince people to install it :) > > > Right, that's the challenge :) > I personally use Chrome (!) and I've been using your Chrome extension, so > thank you! > However, I don't feel comfortable making this available only for a specific > browser user, feels exclusionary to me. Thanks to Milan Oberkirch, the version in the master branch uses WebExtension API so it should be easy make it run on Firefox (I don't know if it works on other browsers though) > Also, sometimes I merge from my phone where there's no chrome extension, > (maybe I really shouldn't be doing that?). > > I think the solution should be something not webbrowser specific. > > One idea is maybe have a bot to do the squash commit, for example by > commenting on GitHub: > @merge-bot merge > > So core devs can do the above instead of pressing the commit button. Any > thoughts on this? That would be best solution (I think it would solve https://github.com/python/miss-islington/issues/16 too) but it's more complicated than the extension idea :) I have some time work on it if you'd like to implement the mergebot idea. --Berker ___ Python-Dev mailing list Python-Dev@python.org https://mail.python.org/mailman/listinfo/python-dev Unsubscribe: https://mail.python.org/mailman/options/python-dev/archive%40mail-archive.com
Re: [Python-Dev] GH-NNNN vs #NNNN in merge commit
On Thu, Jan 25, 2018 at 4:58 PM, Mariatta Wijayawrote: > It has to be manually edited right before you commit/merge on GitHub. > I don't think it can be automatically changed? Unless we have some kind of > post commit hook to amend the commit message. Perhaps it's possible to edit both title and body fields [1] automatically before merging via a browser extension. I can try to add it to https://github.com/berkerpeksag/cpython-bpo-linkify Of course, we would still need to convince people to install it :) --Berker [1] https://www.dropbox.com/s/tbf7j8jm66t707r/Screenshot%20from%202018-01-25%2018%3A26%3A05.png?dl=0 ___ Python-Dev mailing list Python-Dev@python.org https://mail.python.org/mailman/listinfo/python-dev Unsubscribe: https://mail.python.org/mailman/options/python-dev/archive%40mail-archive.com
Re: [Python-Dev] GH-NNNN vs #NNNN in merge commit
On Thu, Jan 25, 2018 at 1:42 PM, INADA Naokiwrote: > Hi. > > Devguide says: > > """ > Replace the reference to GitHub pull request # with GH-. If > the title is too long, the pull request number can be added to the > message body. > """ > > https://devguide.python.org/gitbootcamp/#accepting-and-merging-a-pull-request > > But there are more # than GH- in commit log. > https://github.com/python/cpython/commits/master > > Where should we go? > Encourage GH-? or abandon it and use default #? I'd personally drop both GH- and # markers. The number of the PR is already linked to the commit on GitHub: https://www.dropbox.com/s/zzm9f56485pbl1v/Screenshot%20from%202018-01-25%2015%3A14%3A28.png?dl=0 You can even see both styles in the same commit (especially in backport PRs) bpo-42: Fix spam eggs (GH-2341) (#2211) --Berker ___ Python-Dev mailing list Python-Dev@python.org https://mail.python.org/mailman/listinfo/python-dev Unsubscribe: https://mail.python.org/mailman/options/python-dev/archive%40mail-archive.com
Re: [Python-Dev] Compiling without multithreading support -- still useful?
On Tue, Sep 5, 2017 at 7:42 PM, Victor Stinnerwrote: > I'm strongly in favor of dropping this option from Python 3.7. It > would remove a lot of code! +1 Do we still have buildbots for testing the --without-threads option? --Berker ___ Python-Dev mailing list Python-Dev@python.org https://mail.python.org/mailman/listinfo/python-dev Unsubscribe: https://mail.python.org/mailman/options/python-dev/archive%40mail-archive.com
Re: [Python-Dev] bugs.python.org - outage 08/09/17 until 8:00pm PST
On Thu, Aug 10, 2017 at 4:44 PM, Berker Peksağ <berker.pek...@gmail.com> wrote: > On Thu, Aug 10, 2017 at 9:19 AM, Terry Reedy <tjre...@udel.edu> wrote: >> Fetching pages came back, but updating issues is spotty. Some work, but for >> others "an error has occurred" even with multiple tries. > > And I can't login to my account. When I tried to login via Google > OpenID, I got "There is already an account for myem...@address.com". I > also tried to reset my password and I got "Invalid login" when I tried > to login with my new password. Just an FYI: I'm now able to login to my account. Thank you everyone who worked on migrating bugs.p.o! --Berker ___ Python-Dev mailing list Python-Dev@python.org https://mail.python.org/mailman/listinfo/python-dev Unsubscribe: https://mail.python.org/mailman/options/python-dev/archive%40mail-archive.com
Re: [Python-Dev] bugs.python.org - outage 08/09/17 until 8:00pm PST
On Thu, Aug 10, 2017 at 9:19 AM, Terry Reedywrote: > Fetching pages came back, but updating issues is spotty. Some work, but for > others "an error has occurred" even with multiple tries. And I can't login to my account. When I tried to login via Google OpenID, I got "There is already an account for myem...@address.com". I also tried to reset my password and I got "Invalid login" when I tried to login with my new password. --Berker ___ Python-Dev mailing list Python-Dev@python.org https://mail.python.org/mailman/listinfo/python-dev Unsubscribe: https://mail.python.org/mailman/options/python-dev/archive%40mail-archive.com
Re: [Python-Dev] Appending a link back to bugs.python.org in GitHub PRs
On Sat, Jul 22, 2017 at 12:28 AM, Brett Cannonwrote: > P.S.: Berker Peksag is working on providing commit emails with diffs in them > which is the other most requested feature since the transition. I forgot to give a status update on this. I deployed it on Heroku last week. You can see an example email at https://mail.python.org/pipermail/python-checkins/2017-July/151296.html --Berker ___ Python-Dev mailing list Python-Dev@python.org https://mail.python.org/mailman/listinfo/python-dev Unsubscribe: https://mail.python.org/mailman/options/python-dev/archive%40mail-archive.com
Re: [Python-Dev] Outdated GitHub clone of the old svn repository
On Fri, May 5, 2017 at 7:31 PM, Victor Stinnerwrote: > Hi, > > Does someone know who owns the following Git clone of the old > Subversion CPython repository? > https://github.com/python-git/python/ > > I would suggest to remove it to avoid confusion. A friend pointed to > me this repository and was surprised to see outdated code... > > Is https://github.com/python-git a real user or an organization? See https://mail.python.org/pipermail/python-dev/2016-February/143224.html for the previous discussion. --Berker ___ Python-Dev mailing list Python-Dev@python.org https://mail.python.org/mailman/listinfo/python-dev Unsubscribe: https://mail.python.org/mailman/options/python-dev/archive%40mail-archive.com
Re: [Python-Dev] Is adding support for os.PathLike an enhancement or bugfix?
On Wed, May 3, 2017 at 9:15 PM, Brett Cannonwrote: > My allergies have hit me hard so I'm not thinking at full capacity, but did > we ever decide if supporting os.PathLike in the stdlib was viewed as an > enhancement or bugfix? Specifically I'm thinking of > https://bugs.python.org/issue30218 for adding support to > shutil.unpack_archive() and whether it should be backported to 3.6. We've already backported a few patches that improves the PEP 519 support in the stdlib with the permission from the release manager of 3.6. I'd ask Ned whether bpo-30218 qualifies for backporting to 3.6. --Berker ___ Python-Dev mailing list Python-Dev@python.org https://mail.python.org/mailman/listinfo/python-dev Unsubscribe: https://mail.python.org/mailman/options/python-dev/archive%40mail-archive.com
Re: [Python-Dev] Can I commit a hack for translation? (Was: Translated Python documentation
On Fri, Feb 24, 2017 at 3:35 PM, Victor Stinnerwrote: > This change has zero impact on docs.python.org, it only help teams > working on translation, so go ahead. This change creates an unnecessary maintenance burden for people who works on Python documentation. --Berker ___ Python-Dev mailing list Python-Dev@python.org https://mail.python.org/mailman/listinfo/python-dev Unsubscribe: https://mail.python.org/mailman/options/python-dev/archive%40mail-archive.com
Re: [Python-Dev] Translated Python documentation
On Thu, Feb 23, 2017 at 12:01 AM, Victor Stinnerwrote: > 2017-02-22 19:04 GMT+01:00 Serhiy Storchaka : >> What percent of lines is changed between bugfix releases? Feature releases? >> >> My largest apprehension is that the documentation can be outdated and >> quickly become degraded if main contributors left it. > > If the original text (english) changes, untranslated text is > displayed, not outdated text. I think that's much worse than showing the outdated text. I don't see any point on showing half English and half French text if the reader can't understand the other half of it. As someone who have spent a lot of time reviewing and committing documentation patches, I'm strongly against on marking documentation translations as official. The Python documentation updates frequently and it's simply not possible to keep them sync with the official documentation. See https://github.com/python/cpython/commits/master/Doc for the commit history of the official documentation. You can easily compare it with the translations by looking their GitHub repositories. Also, there are a lot of better educational materials (e.g. Django Girls Tutorial) for people who don't speak English and have no previous programming experience. Even the tutorial contains several references to different programming concepts and programming languages such as C++. --Berker ___ Python-Dev mailing list Python-Dev@python.org https://mail.python.org/mailman/listinfo/python-dev Unsubscribe: https://mail.python.org/mailman/options/python-dev/archive%40mail-archive.com
Re: [Python-Dev] [Python-checkins] [python/cpython] 4538dd: Fix bpo-29528 Use a secure variable to stop spam (...
--Berker On Mon, Feb 13, 2017 at 8:54 PM, Brett Cannonwrote: > > > On Mon, 13 Feb 2017 at 07:10 Barry Warsaw wrote: >> >> On Feb 11, 2017, at 08:11 PM, Andrew M. Kuchling wrote: >> >> >Are we planning to include the diffs in python-checkins e-mail, or are >> >they gone for good? >> > >> >(While they made the list's messages and digests larger, I liked >> >having the diffs because you could page through them to see what >> >changes were made without having to go through to another site.) >> >> Yep, this was recently discussed and I think the plan is to bring them >> back >> for python-checkins, but that it's not possible to enable them on PRs due >> to >> GH limitations. > > > Serhiy asked about it and I said that the email integration we are using > from GitHub doesn't allow for customizing the email it sends out beyond how > is listed in the From line. If people find a different integration that they > want to use for sending email then that can be set up. I wrote a webhook that includes diffs: An example output can be seen at https://github.com/python/core-workflow/issues/24#issuecomment-279162079 Since it listens all 'push' events, it's possible to catch all commits and send them to python-checkins. --Berker ___ Python-Dev mailing list Python-Dev@python.org https://mail.python.org/mailman/listinfo/python-dev Unsubscribe: https://mail.python.org/mailman/options/python-dev/archive%40mail-archive.com
Re: [Python-Dev] re performance
On Mon, Jan 30, 2017 at 2:56 PM, Antoine Pitrouwrote: > On Sun, 29 Jan 2017 20:30:38 + > Steve Holden wrote: >> Why not declare re deprecated and remove it in Python 4? > > Why deprecate and remove a library that's perfectly usable and > satisfactory for the vast majority of regular expression usage? It's > not like regex presents a radically different API... > > Do we really have to face another wave of stdlib bashing on this > mailing-list? I agree with Antoine. And note that re has an active maintainer who has fixed a bunch of bugs and added some new features in the last few years. --Berker ___ Python-Dev mailing list Python-Dev@python.org https://mail.python.org/mailman/listinfo/python-dev Unsubscribe: https://mail.python.org/mailman/options/python-dev/archive%40mail-archive.com
Re: [Python-Dev] The "humor" section of the website is a bit outdated...
On Wed, Jan 4, 2017 at 10:59 PM, Ryan Gonzalezwrote: > Ok, in advance, my apologies for probably sending this to the wrong mailing > list... Hi, https://github.com/python/pythondotorg/issues is a better place to report content issues on python.org. --Berker ___ Python-Dev mailing list Python-Dev@python.org https://mail.python.org/mailman/listinfo/python-dev Unsubscribe: https://mail.python.org/mailman/options/python-dev/archive%40mail-archive.com
Re: [Python-Dev] IRC logs via BotBot.me
On Thu, Jan 5, 2017 at 2:27 AM, INADA Naokiwrote: > Hi. > > IRC #python-dev channel is nice place to know what happens recently. > But I can't log in always because I use only laptop PC. > > I found BotBot.me seems nice IRC log service and used by some major channels. > https://botbot.me/ > > I wonder if #python-dev is logged by BotBot.me. > > I'm sorry if it had rejected already. I'm using my personal VPS to stay online on Freenode. This looks like a tooling issue on your end and it can be solved without introducing a public logging service. --Berker ___ Python-Dev mailing list Python-Dev@python.org https://mail.python.org/mailman/listinfo/python-dev Unsubscribe: https://mail.python.org/mailman/options/python-dev/archive%40mail-archive.com
Re: [Python-Dev] [Python-checkins] cpython (3.5): remove extra PyErr_Format arguments (closes #28454)
On Mon, Oct 17, 2016 at 12:43 PM, Jeremy Klothwrote: > On Sun, Oct 16, 2016 at 4:42 PM, benjamin.peterson > wrote: >> --- a/Objects/unicodeobject.c >> +++ b/Objects/unicodeobject.c >> @@ -3009,7 +3009,7 @@ >> "'%.400s' decoder returned '%.400s' instead of 'str'; " >> "use codecs.decode() to decode to arbitrary types", >> encoding, >> - Py_TYPE(unicode)->tp_name, Py_TYPE(unicode)->tp_name); >> + Py_TYPE(unicode)->tp_name); >> Py_DECREF(unicode); >> goto onError; >> } > > Um, isn't that now an error? There are 2 format sequences, but only 1 > argument. Hi Jeremy, It doesn't look like an error to me. The first argument is 'encoding' and the second one is 'Py_TYPE(unicode)->tp_name'. --Berker ___ Python-Dev mailing list Python-Dev@python.org https://mail.python.org/mailman/listinfo/python-dev Unsubscribe: https://mail.python.org/mailman/options/python-dev/archive%40mail-archive.com
Re: [Python-Dev] [Python-checkins] cpython: Use HTTP in testPythonOrg
On Sun, Sep 11, 2016 at 3:58 PM, Eric V. Smithwrote: > Hi, Berker. > > Could you add a comment to the test on why this should use http? I can see > this bouncing back and forth between http and https, as people clean an up > all http usages to be https. Hi Eric, Sorry, I missed your email. Victor's analysis is correct. I've changed the test to use pythontest.net and increased the test coverage in http://bugs.python.org/issue28151. Thank you for the review! --Berker ___ Python-Dev mailing list Python-Dev@python.org https://mail.python.org/mailman/listinfo/python-dev Unsubscribe: https://mail.python.org/mailman/options/python-dev/archive%40mail-archive.com
Re: [Python-Dev] [python-committers] [RELEASE] Python 3.6.0b1 is now available
On Thu, Sep 15, 2016 at 9:35 AM, Serhiy Storchakawrote: > On 14.09.16 17:36, Guido van Rossum wrote: >> >> Fortunately that page isn't linked from anywhere on the home page >> AFAIK. If it is, could someone file an issue in the pydotorg tracker? >> The url is at the bottom of every page. > > > This is on of the first results (actually the first besides manually edited > news) of googling "python news". Fixed, it should redirect to https://www.python.org/blogs/ now. Thanks for noticing this! --Berker ___ Python-Dev mailing list Python-Dev@python.org https://mail.python.org/mailman/listinfo/python-dev Unsubscribe: https://mail.python.org/mailman/options/python-dev/archive%40mail-archive.com
Re: [Python-Dev] Patches to distutils for 3.6
On Fri, Aug 19, 2016 at 11:07 AM, Sylvain Corlaywrote: > Hi All, > > There are a couple of related patches that were submitted to distutils a few > months ago that I think would be great to have in before the feature freeze > in 3.6b1 > > A bug fix in CCompiler.has_function > http://bugs.python.org/issue25544 Hi Sylvain, This doesn't look like a new feature to me so it can be committed after feature freeze. However, the patch needs to be tested in Windows. > Adding a has_flag method to CCompiler > http://bugs.python.org/issue26689 > > useful to check if a compiler has certain flags available (such as > -std=c++11) This needs a test case and documentation update to https://docs.python.org/3.5/distutils/apiref.html#distutils.ccompiler.CCompiler NamedTemporaryFile might not work as expected in Windows (we have some open issues about NamedTemporaryFile, but I'm not a Windows user.) ___ Python-Dev mailing list Python-Dev@python.org https://mail.python.org/mailman/listinfo/python-dev Unsubscribe: https://mail.python.org/mailman/options/python-dev/archive%40mail-archive.com
Re: [Python-Dev] PEP 520: Ordered Class Definition Namespace (round 3)
On Sun, Jun 12, 2016 at 5:37 AM, Eric Snowwrote: > The following code demonstrates roughly equivalent semantics for the > default behavior:: > >class Meta(type): >def __prepare__(cls, *args, **kwargs): Shouldn't this be wrapped with a classmethod decorator? +1 from me. --Berker ___ Python-Dev mailing list Python-Dev@python.org https://mail.python.org/mailman/listinfo/python-dev Unsubscribe: https://mail.python.org/mailman/options/python-dev/archive%40mail-archive.com
Re: [Python-Dev] Current Python 3.2 status?
On Sat, Jun 11, 2016 at 8:59 AM, Chi Hsuan Yenwrote: > Hello all, > > Georg said in February that 3.2.7 is going to be released, and now it's > June. Will it ever be released? Hi, It was delayed because of a security issue. See Georg's email at https://mail.python.org/pipermail/python-dev/2016-February/143400.html --Berker ___ Python-Dev mailing list Python-Dev@python.org https://mail.python.org/mailman/listinfo/python-dev Unsubscribe: https://mail.python.org/mailman/options/python-dev/archive%40mail-archive.com
Re: [Python-Dev] Inconsistency of PyModule_AddObject()
On Wed, Apr 27, 2016 at 10:14 AM, Serhiy Storchakawrote: > I think that we can resolve this issue by following steps: > > 1. Add a new function PyModule_AddObject2(), that steals a reference even on > failure. +1 It would be good to document PyModule_AddObject's current behavior in 3.5+ (already attached a patch). > 2. Introduce a special macro like PY_SSIZE_T_CLEAN (any suggestions about a > name?). If it is defined, define PyModule_AddObject as PyModule_AddObject2. > Define this macro before including Python.h in all CPython modules except > _json, _io, and _tkinter. +1 > 3. Make old PyModule_AddObject to emit a warning about possible leak and a > suggestion to define above macro. +0 ___ Python-Dev mailing list Python-Dev@python.org https://mail.python.org/mailman/listinfo/python-dev Unsubscribe: https://mail.python.org/mailman/options/python-dev/archive%40mail-archive.com
Re: [Python-Dev] Web redirect to PyAr
On Mon, Mar 7, 2016 at 3:07 AM, Facundo Batistawrote: > Hello! > > Sending mail here because I really don't know where this is handled :) > > At some point in the past we had a redirect from python.org/ar (note > the slash, not a point) to a PyAr site. > > Now it's not working, it 404s. > > It should be redirected to python.org.ar (note the point). Can you try again? It should be redirected to python.org.ar now. --Berker ___ Python-Dev mailing list Python-Dev@python.org https://mail.python.org/mailman/listinfo/python-dev Unsubscribe: https://mail.python.org/mailman/options/python-dev/archive%40mail-archive.com
Re: [Python-Dev] Devguide: Add a table summarizing status of Python branches
On Fri, Jan 22, 2016 at 6:03 PM, Victor Stinnerwrote: > 2016-01-21 18:18 GMT+01:00 Brett Cannon : >> It's live: https://docs.python.org/devguide/#status-of-python-branches > > There is a very strange bug in this website. > > This URL shows the table: > https://docs.python.org/devguide/ > > This URL doesn't show the table: > https://docs.python.org/devguide/index.html > > Outdated version of the guide? It looks like a cache issue. I purged the cache for /devguide/index.html: $ wget -O- https://docs.python.org/devguide/index.html 2>&1 | grep "Python branches" Status of Python branches¶ Status of Python branches --Berker ___ Python-Dev mailing list Python-Dev@python.org https://mail.python.org/mailman/listinfo/python-dev Unsubscribe: https://mail.python.org/mailman/options/python-dev/archive%40mail-archive.com
Re: [Python-Dev] Choosing an official stance towards module deprecation in Python 3
On Tue, Sep 8, 2015 at 7:59 PM, Brett Cannonwrote: > There are two discussions going on in the issue tracker about deprecating > some modules and it has led to the inevitable discussion of Python 2/3 > compatibility (I'm not even going to bother mentioning the issue #s as this > thread is not about the modules specifically but module deprecation in > general). Because I'm tired of rehashing the same discussion every time a > module deprecation comes up I would like to make an official decision that > we can follow any time we decide to deprecate a module. > > The approaches to module deprecation I have seen are: > 1. Nothing changes to the deprecation process; you deprecate a module and > remove it in one to two releases > 2. Deprecate the module but with no plans for removal until Python 2.7 > reaches its EOL (I have been calling this Python 4) > 3. Document the deprecation but no actual code deprecation > > I'm personally in the #2 camp. I want users to be fully aware that the > module in question is not being updated and possibly not even getting > non-critical bugfixes, but it's still there in Python 3 in order to make > sure that you can have code which straddles Python 2 & 3 more easily. +1 --Berker ___ Python-Dev mailing list Python-Dev@python.org https://mail.python.org/mailman/listinfo/python-dev Unsubscribe: https://mail.python.org/mailman/options/python-dev/archive%40mail-archive.com
Re: [Python-Dev] Burning down the backlog.
On Sun, Jul 26, 2015 at 2:58 PM, Paul Moore p.f.mo...@gmail.com wrote: On 25 July 2015 at 20:28, Robert Collins robe...@robertcollins.net wrote: Those charts doesn't show patches in 'commit-review' - http://bugs.python.org/issue?%40columns=title%40columns=idstage=5%40columns=activity%40sort=activitystatus=1%40columns=status%40pagesize=50%40startwith=0%40sortdir=on%40action=search There are only 45 of those patches. AIUI - and I'm very new to core here - anyone in triagers can get patches up to commit-review status. I think we should set a goal to keep inventory low here - e.g. review and either bounce back to patch review, or commit, in less than a month. Now - a month isn't super low, but we have lots of stuff greater than a month. I'm not actually clear what Commit Review status means. I did do a quick check of the dev guide, and couldn't come up with anything, https://docs.python.org/devguide/triaging.html#stage ___ Python-Dev mailing list Python-Dev@python.org https://mail.python.org/mailman/listinfo/python-dev Unsubscribe: https://mail.python.org/mailman/options/python-dev/archive%40mail-archive.com
Re: [Python-Dev] Where are bugs with the web site reported?
On Thu, Jul 16, 2015 at 10:11 PM, Ryan Gonzalez rym...@gmail.com wrote: I have encountered this weird issue on Chrome for Android where scrolling up just a little causes the page to dart to the top. I was going to report it in the bug tracker, but I didn't see a label for the web site itself. Worst part is, this is stopping me from reading the humor page! Hi, Already reported at https://github.com/python/pythondotorg/issues/531 --Berker ___ Python-Dev mailing list Python-Dev@python.org https://mail.python.org/mailman/listinfo/python-dev Unsubscribe: https://mail.python.org/mailman/options/python-dev/archive%40mail-archive.com
Re: [Python-Dev] How far to go with user-friendliness
On Tue, Jul 14, 2015 at 5:00 PM, Steven D'Aprano st...@pearwood.info wrote: On Tue, Jul 14, 2015 at 11:09:50PM +1000, Nick Coghlan wrote: Dima's right that the main defence against this kind of error is actually linters and IDEs, but detecting this particular one at runtime is harmless, so there's no particular reason *not* to do it when it's possible to construct a reasonable rationale for Why this particular typo? and not all the other possible ways of transposing adjacent letters in assert. I've read this thread and the bug report and I'm not sure about this reasonable rationale. It seems like an utterly arbitrary choice to single out a single typo for special treatment while ignoring other equivalent typos, equally easy to make and equally difficult to spot. You even mentioned people with dyslexia yourself. As I understand it, dyslexics would find assert and assery equally hard to distinguish as assret versus assert, and t and y are next to each other on the same row of QWERTY keyboards. BTW, am I missing something? The issue tracker says that the patch was accepted and a new unsafe keyword argument was added over a year ago, but that doesn't seem to be documented anywhere here: https://docs.python.org/3/library/unittest.mock.html It's new in Python 3.5: https://docs.python.org/3.5/library/unittest.mock.html#unittest.mock.Mock unsafe: By default if any attribute starts with assert or assret will raise an AttributeError. Passing unsafe=True will allow access to these attributes. --Berker ___ Python-Dev mailing list Python-Dev@python.org https://mail.python.org/mailman/listinfo/python-dev Unsubscribe: https://mail.python.org/mailman/options/python-dev/archive%40mail-archive.com
Re: [Python-Dev] How far to go with user-friendliness
On Wed, Jul 15, 2015 at 1:22 AM, Robert Collins robe...@robertcollins.net wrote: On 15 July 2015 at 10:05, Ethan Furman et...@stoneleaf.us wrote: On 07/14/2015 02:53 PM, Robert Collins wrote: ... I don't think unittest can protect its users from such things. It can't, but there is a sliding scale of API usability, and we should try to be up the good end of that :). I hope you're not suggesting that supporting misspellings, and thereby ruling out the proper use of an otherwise fine variable name, is at the good end of that scale? I'm not supporting the misspelling thing - see my suggestion earlier in this thread to move the mock assertions to standalone functions, removing the bug in that area *entirely* and eventually removing the check for method names starting with assert from mock entirely. What I am doing is rejecting the argument that because we can't fix every mis-use users might make, we therefore should not fix the cases where we can fix it. For clarity, I think we should: - remove the assret check, it is I think spurious. - add a set of functions to the mock module that should be used in preference to Mock.assert* - mark the Mock.assert* functions as PendingDeprecation - in 3.6 move the PendingDeprecation to Deprecated - in 3.7 remove the Mock.assert* functions and the check for method names beginning with assert entirely. +1, but I think we need to get Larry's approval for the steps 2 and 3 because 3.5 is in feature-freeze mode. --Berker ___ Python-Dev mailing list Python-Dev@python.org https://mail.python.org/mailman/listinfo/python-dev Unsubscribe: https://mail.python.org/mailman/options/python-dev/archive%40mail-archive.com
Re: [Python-Dev] Computed Goto dispatch for Python 2
On Thu, May 28, 2015 at 3:17 AM, Parasa, Srinivas Vamsi srinivas.vamsi.par...@intel.com wrote: Attached is the computed goto patch (along with instructions to run) for Python 2.7.10 (based on the patch submitted by Jeffrey Yasskin at http://bugs.python.org/issue4753). We built and tested this patch for Python 2.7.10 on a Linux machine (Ubuntu 14.04 LTS server, Intel Xeon – Haswell EP CPU with 18 cores, hyper-threading off, turbo off). Hi Vamsi, Thank you for your work and your detailed email. I'm -1 on the idea because: * Performance improvements are not bug fixes * The patch doesn't make the migration process from Python 2 to Python 3 easier * In long term, it would be nice to work on making Python 3 better: See http://bugs.python.org/issue11549 for an example task. --Berker ___ Python-Dev mailing list Python-Dev@python.org https://mail.python.org/mailman/listinfo/python-dev Unsubscribe: https://mail.python.org/mailman/options/python-dev/archive%40mail-archive.com
Re: [Python-Dev] 3.5 doc warnings
On Sat, May 23, 2015 at 11:24 PM, Terry Reedy tjre...@udel.edu wrote: 35\Doc\whatsnew\3.5.rst:686: ERROR: Unknown interpreted text role module. 35\Doc\library\typing.rst:: WARNING: document isn't included in any toctree from building html docs just now Fixed in https://hg.python.org/cpython/rev/ec1e187173f7 --Berker ___ Python-Dev mailing list Python-Dev@python.org https://mail.python.org/mailman/listinfo/python-dev Unsubscribe: https://mail.python.org/mailman/options/python-dev/archive%40mail-archive.com
Re: [Python-Dev] Reminder: Python 3.5 beta 1 will be tagged tomorrow
On Sat, May 23, 2015 at 12:53 AM, Chris Barker chris.bar...@noaa.gov wrote: On Fri, May 22, 2015 at 2:33 PM, Larry Hastings la...@hastings.org wrote: On 05/22/2015 02:29 PM, Chris Barker wrote: Is it too late to get the isclose() code (PEP 485) into 3.5? ... Hopefully you can find a core dev familiar enough with the issues involved that they can (quickly!) guide it through the process of getting it checked in. Ping! Anyone willing to sponsor this? Hi Chris, Thanks for the PEP and the implementation! You'll get more attention If you open an issue with a patch at bugs.python.org. Having a GitHub repository is good, but the isclose() code(with tests and documentation) needs to be integrated into the CPython code base: * The C implementation should be in Modules/mathmodule.c * Tests should be in Lib/test/test_math.py * Documentation should be in Doc/library/math.rst * Add an entry to Doc/whatsnew/3.5.rst * If I remember correctly, we don't need the Python implementation and its tests --Berker ___ Python-Dev mailing list Python-Dev@python.org https://mail.python.org/mailman/listinfo/python-dev Unsubscribe: https://mail.python.org/mailman/options/python-dev/archive%40mail-archive.com
Re: [Python-Dev] Automated testing of patches from bugs.python.org
On Tue, May 19, 2015 at 6:02 PM, Kushal Das kushal...@gmail.com wrote: Hi, With the help of CentOS project I am happy to announce an automated system [1] to test patches from bugs.python.org. This can be fully automated to test the patches whenever someone uploads a patch in the roundup, but for now it accepts IRC commands on #python-dev channel. I worked on a docker based prototype during sprints in PyCon. How to use it? --- 1. Join #python-dev on irc.freenode.net. 2. Ask for test privilege from any one of kushal,Taggnostr,bitdancer 3. They will issue a simple command. #add: YOUR_NICK_NAME 4. You can then test by issuing the following command in the channel: #test: BUGNUMBER like #test: 21271 This will do the following: Start a new job on ci.centos.org, announce it on the channel, and announce the result also. Hi Kushal, Looks great, thanks! :) Two comments: * It would be good to have a pypatcher repository at hg.python.org (at least a mirror), so we can work on it together without dealing with add me to the repo messages on GitHub. * Do you have a roadmap or a TODO list? For example, I think downloading a tarball of the default branch every time (or is it cached?) would be a little bit slow. Do you have a plan to make the workflow Mercurial based (e.g. hg pull -u, hg imp --no-c issue.diff, compile instead of wget tarball, extract it, apply patch, compile)? I will be working on a minimal lint for patches, and include it the workflow. Could you give more details about the linter? Can we use Tools/scripts/patchcheck.py? Thanks! --Berker ___ Python-Dev mailing list Python-Dev@python.org https://mail.python.org/mailman/listinfo/python-dev Unsubscribe: https://mail.python.org/mailman/options/python-dev/archive%40mail-archive.com
Re: [Python-Dev] [Python-checkins] cpython: Issue #24064: Property() docstrings are now writeable.
On Wed, May 13, 2015 at 11:56 AM, Eric V. Smith e...@trueblade.com wrote: On 5/13/2015 4:10 AM, raymond.hettinger wrote: https://hg.python.org/cpython/rev/1e8a768fa0a5 changeset: 96010:1e8a768fa0a5 user:Raymond Hettinger pyt...@rcn.com date:Wed May 13 01:09:59 2015 -0700 summary: Issue #24064: Property() docstrings are now writeable. (Patch by Berker Peksag.) diff --git a/Doc/library/collections.rst b/Doc/library/collections.rst --- a/Doc/library/collections.rst +++ b/Doc/library/collections.rst @@ -924,6 +924,15 @@ Point3D = namedtuple('Point3D', Point._fields + ('z',)) +Docstrings can be customized by making direct assignments to the ``__doc__`` +fields: + +Book = namedtuple('Book', ['id', 'title', 'authors']) +Book.__doc__ = 'Hardcover book in active collection' +Book.id = '13-digit ISBN' +Book.title = 'Title of first printing' +Book.author = 'List of authors sorted by last name' Should these be: Book.id.__doc__ = ... etc.? Hi Eric, Good catch. Fixed in https://hg.python.org/cpython/rev/bde652ae05fd Thanks! --Berker +Point = namedtuple('Point', ['x', 'y']) +Point.__doc__ = 'ordered pair' +Point.x.__doc__ = 'abscissa' +Point.y.__doc__ = 'ordinate' These lines from /Doc/whatsnew/3.5.rst would make me think so. Eric. ___ Python-Dev mailing list Python-Dev@python.org https://mail.python.org/mailman/listinfo/python-dev Unsubscribe: https://mail.python.org/mailman/options/python-dev/berker.peksag%40gmail.com ___ Python-Dev mailing list Python-Dev@python.org https://mail.python.org/mailman/listinfo/python-dev Unsubscribe: https://mail.python.org/mailman/options/python-dev/archive%40mail-archive.com
Re: [Python-Dev] [python-committers] How shall we conduct the Python 3.5 beta and rc periods? (Please vote!)
On Tue, May 12, 2015 at 8:04 PM, Larry Hastings la...@hastings.org wrote: What do you think? My votes are as follows: Workflow 0: -0.5 Workflow 1: +1 Workflow 2: +0.5 Please cast your votes, Workflow 0: -0 Workflow 1: +1 Workflow 2: +0 --Berker ___ Python-Dev mailing list Python-Dev@python.org https://mail.python.org/mailman/listinfo/python-dev Unsubscribe: https://mail.python.org/mailman/options/python-dev/archive%40mail-archive.com
Re: [Python-Dev] How to behave regarding commiting
On Fri, Apr 17, 2015 at 4:32 AM, Facundo Batista facundobati...@gmail.com wrote: Hola! I'm asking this because quite some time passed since I was active in the development of our beloved language. I'm trying to not break any new rule not known by me. I opened a bug recently [0], somebody else proposed a patch that I like. However, that patch has no test. I will do a test for that code, but then what? Shall I just commit and push? Or the whole branch should be proposed for further reviewing? Hi, Since writing a test for that patch is simple, I'd just commit it to the default branch. --Berker ___ Python-Dev mailing list Python-Dev@python.org https://mail.python.org/mailman/listinfo/python-dev Unsubscribe: https://mail.python.org/mailman/options/python-dev/archive%40mail-archive.com
Re: [Python-Dev] Python bug tracker Roundup
On Mon, Jan 26, 2015 at 10:25 PM, Ethan Furman et...@stoneleaf.us wrote: Do we have our own mailing list for Roundup? Hi, Yes: https://mail.python.org/mailman/listinfo/tracker-discuss There is also a tracker for bugs.p.o: http://psf.upfronthosting.co.za/roundup/meta/ --Berker ___ Python-Dev mailing list Python-Dev@python.org https://mail.python.org/mailman/listinfo/python-dev Unsubscribe: https://mail.python.org/mailman/options/python-dev/archive%40mail-archive.com
Re: [Python-Dev] Move selected documentation repos to PSF BitBucket account?
On Mon, Nov 24, 2014 at 6:36 PM, Donald Stufft don...@stufft.io wrote: On Nov 24, 2014, at 11:28 AM, Brett Cannon br...@python.org wrote: On Mon Nov 24 2014 at 2:25:30 AM Nick Coghlan ncogh...@gmail.com wrote: That outcome would be the antithesis of the PSF's overall mission, This might be a little controversial, but the PSF's mission should not influence a decision of python-dev. If we had to break a tie then yes, I would choose the Python-based solution. But if a superior solution existed and it just happened to not be written in Python I'm not going to sacrifice productivity and the overall health of the project just to promote an inferior tool because they happened to choose Python. The only reason we didn't go with Jira for our issue tracker was because of pressure to not go with a closed-source solution and I was promised volunteers from the FSF to help manage our issue tracker (which never materialized, BTW). This is really what I’m trying to do but I’m apparently not getting my point across very well. I want us to pick the best tool for the job regardless of what language it’s written in. I just so happen to think that the best tool for the job in this case is Github. For peps and devguide repos GitHub would be the best tool, but not for Doc/ and CPython itself. I also agree that GitHub's big green merge button works well for small or middle sized projects. We can just press the merge button for pep and devguide repos, but for Doc/ I think using GitHub or Bitbucket would be painful. Currently, I do the following steps for a typo fix or a minor markup change: * Import the patch if it's provided: hg imp --no-c url * If it's just a typo in the default branch, just verify it and commit: hg commit and hg push * If not: hg update 3.4, hg commit, hg update default, hg merge 3.4, hg push * If it's a markup change, build the documentation locally. It'll take 2-3 minutes. The last two steps would be look tough to follow, it's actually not. I learned Hg when I started to send patches to CPython and learning a couple of commands is not that hard IMO. For GitHub or Bitbucket: * Review the pull request and merge it via the big green merge button. * Ask submitter to send another pull request for the 3.4 branch. If I remember correctly, it's possible to do that from GitHub's UI, but again opening two pull requests to fix a typo or a markup error isn't good. * Or cherrypick it yourself: - Update your local clone - Cherrypick the commit and push * We can use Travis CI to build the documentation on GitHub. I don't think this is a selling point. I tried to fix a broken URL via the edit button in the PyPy repo a couple of weeks ago. At my first try, Bitbucket opened a pull request in my fork. It took me 10-15 minutes to open a pull request correctly. This step would be easier on GitHub. However, I think sending an email to d...@python.org is the easiest solution. --Berker ___ Python-Dev mailing list Python-Dev@python.org https://mail.python.org/mailman/listinfo/python-dev Unsubscribe: https://mail.python.org/mailman/options/python-dev/archive%40mail-archive.com
Re: [Python-Dev] Fix Unicode-disabled build of Python 2.7
On Sat, Jun 28, 2014 at 2:51 AM, Victor Stinner victor.stin...@gmail.com wrote: 2014-06-26 13:04 GMT+02:00 Antoine Pitrou anto...@python.org: For the same reason, I agree with Victor that we should ditch the threading-disabled builds. It's too much of a hassle for no actual, practical benefit. People who want a threadless unicodeless Python can install Python 1.5.2 for all I care. By the way, adding a buildbot for testing Python without thread support is not enough. The buildbot is currently broken since more than one month and nobody noticed :-p I've opened http://bugs.python.org/issue21755 to fix the test a couple of weeks ago. --Berker http://buildbot.python.org/all/builders/AMD64%20Fedora%20without%20threads%203.x/ Ok, I noticed, but I consider that I spent too much time on this minor use case. I prefer to leave such task to someone else :-) Victor ___ Python-Dev mailing list Python-Dev@python.org https://mail.python.org/mailman/listinfo/python-dev Unsubscribe: https://mail.python.org/mailman/options/python-dev/berker.peksag%40gmail.com ___ Python-Dev mailing list Python-Dev@python.org https://mail.python.org/mailman/listinfo/python-dev Unsubscribe: https://mail.python.org/mailman/options/python-dev/archive%40mail-archive.com
Re: [Python-Dev] [Python-checkins] cpython: Closes #21256: Printout of keyword args in deterministic order in mock calls.
On Mon, Jun 9, 2014 at 11:16 AM, kushal.das python-check...@python.org wrote: http://hg.python.org/cpython/rev/8e05e15901a8 changeset: 91102:8e05e15901a8 user:Kushal Das kushal...@gmail.com date:Mon Jun 09 13:45:56 2014 +0530 summary: Closes #21256: Printout of keyword args in deterministic order in mock calls. Printout of keyword args should be in deterministic order in a mock function call. This will help to write better doctests. files: Lib/unittest/mock.py | 2 +- Lib/unittest/test/testmock/testmock.py | 6 ++ Misc/NEWS | 3 +++ 3 files changed, 10 insertions(+), 1 deletions(-) diff --git a/Lib/unittest/mock.py b/Lib/unittest/mock.py --- a/Lib/unittest/mock.py +++ b/Lib/unittest/mock.py @@ -1894,7 +1894,7 @@ formatted_args = '' args_string = ', '.join([repr(arg) for arg in args]) kwargs_string = ', '.join([ -'%s=%r' % (key, value) for key, value in kwargs.items() +'%s=%r' % (key, value) for key, value in sorted(kwargs.items()) ]) if args_string: formatted_args = args_string diff --git a/Lib/unittest/test/testmock/testmock.py b/Lib/unittest/test/testmock/testmock.py --- a/Lib/unittest/test/testmock/testmock.py +++ b/Lib/unittest/test/testmock/testmock.py @@ -1206,6 +1206,12 @@ with self.assertRaises(AssertionError): m.hello.assert_not_called() +#Issue21256 printout of keyword args should be in deterministic order +def test_sorted_call_signature(self): +m = Mock() +m.hello(name='hello', daddy='hero') +text = call(daddy='hero', name='hello') +self.assertEquals(repr(m.hello.call_args), text) Should this be assertEqual instead? --Berker def test_mock_add_spec(self): class _One(object): diff --git a/Misc/NEWS b/Misc/NEWS --- a/Misc/NEWS +++ b/Misc/NEWS @@ -92,6 +92,9 @@ Library --- +- Issue #21256: Printout of keyword args should be in deterministic order in + a mock function call. This will help to write better doctests. + - Issue #21677: Fixed chaining nonnormalized exceptions in io close() methods. - Issue #11709: Fix the pydoc.help function to not fail when sys.stdin is not a -- Repository URL: http://hg.python.org/cpython ___ Python-checkins mailing list python-check...@python.org https://mail.python.org/mailman/listinfo/python-checkins ___ Python-Dev mailing list Python-Dev@python.org https://mail.python.org/mailman/listinfo/python-dev Unsubscribe: https://mail.python.org/mailman/options/python-dev/archive%40mail-archive.com
Re: [Python-Dev] unicode_string future, str - basestring, fix or feature
On Sun, Mar 2, 2014 at 11:23 PM, Serhiy Storchaka storch...@gmail.com wrote: Patches which add support for unicode strings were accepted for one issues (e.g. http://bugs.python.org/issue19099) and rejected for other issues (e.g. http://bugs.python.org/issue20014 and http://bugs.python.org/issue20015). See also http://bugs.python.org/issue15843. --Berker ___ Python-Dev mailing list Python-Dev@python.org https://mail.python.org/mailman/listinfo/python-dev Unsubscribe: https://mail.python.org/mailman/options/python-dev/archive%40mail-archive.com
Re: [Python-Dev] ReST documents
On Thu, Feb 6, 2014 at 9:53 PM, Ethan Furman et...@stoneleaf.us wrote: My apologies if this is a stupid question (actually, two stupid questions! ;) , but: - is there someplace I can look to see what all the meta commands mean? Things like :class: or .. index:: pair: class; constructor Hi, I use the following links as reference: - http://docs.python.org/devguide/documenting.html#id3 - http://sphinx-doc.org/domains.html#the-python-domain - http://sphinx-doc.org/markup/inline.html#xref-syntax --Berker ___ Python-Dev mailing list Python-Dev@python.org https://mail.python.org/mailman/listinfo/python-dev Unsubscribe: https://mail.python.org/mailman/options/python-dev/archive%40mail-archive.com
Re: [Python-Dev] Python Language Summit at PyCon: Agenda
On Mon, Mar 4, 2013 at 9:14 PM, Barry Warsaw ba...@python.org wrote: On Mar 04, 2013, at 07:41 PM, Antoine Pitrou wrote: $ python -m unittest discover $ python setup.py test $ python setup.py nosetests $ python -m nose test $ nosetests-X.Y Besides having a multitude of choices, there's almost no way to automatically discover (e.g. by metadata inspection or some such) how to invoke the tests. You're often lucky if there's a README.test and it's still accurate. I hope we can have a pytest utility that does the right thing in 3.4 :-) Typing python -m unittest discover is too cumbersome. Where is this work being done (e.g. is there a PEP)? There is an open issue on the tracker: http://bugs.python.org/issue14266 --Berker ___ Python-Dev mailing list Python-Dev@python.org http://mail.python.org/mailman/listinfo/python-dev Unsubscribe: http://mail.python.org/mailman/options/python-dev/archive%40mail-archive.com
Re: [Python-Dev] [Python-checkins] r88914 - tracker/instances/python-dev/html/issue.item.js
Hi, On Wed, Oct 26, 2011 at 11:45 AM, ezio.melotti python-check...@python.org wrote: Author: ezio.melotti Date: Wed Oct 26 10:45:41 2011 New Revision: 88914 Log: Mark automated messages with a different background. Modified: tracker/instances/python-dev/html/issue.item.js Modified: tracker/instances/python-dev/html/issue.item.js == --- tracker/instances/python-dev/html/issue.item.js (original) +++ tracker/instances/python-dev/html/issue.item.js Wed Oct 26 10:45:41 2011 @@ -313,3 +313,14 @@ if (link.length != 0) link.attr('href', link.attr('href').split('?')[0]); }); + + +$(document).ready(function() { + /* Mark automated messages with a different background */ + $('table.messages th:nth-child(2)').each(function (i, e) { + var e = $(e); + if (/\(python-dev\)$/.test(e.text())) + e.parent().next().find('td.content').css( + 'background-color', '#efeff9'); + }); +}); I think this is shorter than $(document).ready(); $(function() { // ... }); See: http://stackoverflow.com/questions/3528509/document-readyfunction-vs-function/3528528#3528528 --Berker ___ Python-checkins mailing list python-check...@python.org http://mail.python.org/mailman/listinfo/python-checkins ___ Python-Dev mailing list Python-Dev@python.org http://mail.python.org/mailman/listinfo/python-dev Unsubscribe: http://mail.python.org/mailman/options/python-dev/archive%40mail-archive.com