[issue31153] Update docstrings of itertools functions

2017-08-27 Thread Mike Hoy
Changes by Mike Hoy : -- nosy: +vexoxev ___ Python tracker ___ ___ Python-bugs-list mailing

[issue31286] import in finally results in SystemError

2017-08-27 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: PR 3217 implements the first way. It also includes some refactoring. Remove all pyc-files before testing. -- stage: -> patch review ___ Python tracker

[issue30780] IDLE: configdialog - add tests for ConfigDialog GUI.

2017-08-27 Thread Cheryl Sabella
Changes by Cheryl Sabella : -- pull_requests: +3255 ___ Python tracker ___ ___

[issue30024] Treat `import a.b.c as m` as `m = sys.modules['a.b.c']`

2017-08-27 Thread Serhiy Storchaka
Changes by Serhiy Storchaka : -- pull_requests: +3256 ___ Python tracker ___ ___

[RELEASE] Python 2.7.14 release candidate 1

2017-08-27 Thread Benjamin Peterson
I'm happy to announce the immediate availability of Python 2.7.14 release candidate 1, a testing release for the latest bugfix release in the Python 2.7 series. Downloads of source code and binaries are at https://www.python.org/downloads/release/python-2714rc1/ Please consider testing the

[issue31065] Documentation for Popen.poll is unclear

2017-08-27 Thread Elena Oat
Changes by Elena Oat : -- pull_requests: -3258 ___ Python tracker ___ ___

[issue31065] Documentation for Popen.poll is unclear

2017-08-27 Thread Elena Oat
Changes by Elena Oat : -- pull_requests: +3258 ___ Python tracker ___ ___

[issue31286] import in finally results in SystemError

2017-08-27 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: The regression was introduced in issue30024. It was missed a difference between LOAD_ATTR and IMPORT_FROM. LOAD_ATTR replaces the object with the value of the attribute (do not changing the stack pointer). IMPORT_FROM keeps the original module on the stack

[issue31286] import in finally results in SystemError

2017-08-27 Thread Serhiy Storchaka
Changes by Serhiy Storchaka : -- pull_requests: +3257 ___ Python tracker ___ ___

Re: BeautifulSoup doesn't work with a threaded input queue?

2017-08-27 Thread MRAB
On 2017-08-27 21:35, Christopher Reimer via Python-list wrote: On 8/27/2017 1:12 PM, MRAB wrote: What do you mean by "queue (random order)"? A queue is sequential order, first-in-first-out. With 20 threads requesting 20 different pages, they're not going into the queue in sequential order

[issue31287] IDLE configdialog tests: don't modify tkinter.messagebox.

2017-08-27 Thread Terry J. Reedy
Terry J. Reedy added the comment: New changeset 7e248904cd5b3e658b1792deca1b82d873b2d120 by Terry Jan Reedy in branch '3.6': [3.6] bpo-31287: IDLE - do not alter tkinter.messagebox in configdialog tests. (GH-3220) (#3221)

[issue31287] IDLE configdialog tests: don't modify tkinter.messagebox.

2017-08-27 Thread Terry J. Reedy
Changes by Terry J. Reedy : -- resolution: -> fixed stage: needs patch -> resolved status: open -> closed ___ Python tracker ___

Re: BeautifulSoup doesn't work with a threaded input queue?

2017-08-27 Thread Peter Otten
Christopher Reimer via Python-list wrote: > Greetings, > > I have Python 3.6 script on Windows to scrape comment history from a > website. It's currently set up this way: > > Requestor (threads) -> list -> Parser (threads) -> queue -> CVSWriter > (single thread) > > It takes 15 minutes to

[issue31288] IDLE tests: don't modify tkinter.messagebox.

2017-08-27 Thread Terry J. Reedy
New submission from Terry J. Reedy: Followup to #31287. Check existing tests for similar errors. Apply the idea of localizing access to messageboxes everywhere. In the process, end use of 'tkMessageBox'. -- assignee: terry.reedy components: IDLE messages: 300923 nosy: terry.reedy

[issue31289] File paths in exception traceback resolve symlinks

2017-08-27 Thread Paul Pinterits
New submission from Paul Pinterits: The file paths displayed in exception tracebacks have their symlinks resolved. I would prefer if the "original" path could be displayed instead, because resolved symlinks result in unexpected paths in the traceback and can be quite confusing. An example:

[issue31287] IDLE configdialog tests: don't modify tkinter.messagebox.

2017-08-27 Thread Terry J. Reedy
Changes by Terry J. Reedy : -- pull_requests: +3262 ___ Python tracker ___ ___

[issue30780] IDLE: configdialog - add tests for ConfigDialog GUI.

2017-08-27 Thread Cheryl Sabella
Changes by Cheryl Sabella : -- pull_requests: +3264 ___ Python tracker ___ ___

[issue31191] Fix grammar in threading.Barrier docs

2017-08-27 Thread Mariatta Wijaya
Changes by Mariatta Wijaya : -- pull_requests: +3266 ___ Python tracker ___ ___

[issue26656] Documentation for re.compile is a bit outdated

2017-08-27 Thread Henk-Jaap Wagenaar
Henk-Jaap Wagenaar added the comment: Emily: I've signed the CLA, just waiting for it to be checked. -- nosy: +Henk-Jaap Wagenaar ___ Python tracker ___

[issue30780] IDLE: configdialog - add tests for ConfigDialog GUI.

2017-08-27 Thread Terry J. Reedy
Terry J. Reedy added the comment: #31001 and #31002 have notes on what not tested in HighPage and KeysPage. -- ___ Python tracker ___

[issue31287] IDLE configdialog tests: don't modify tkinter.messagebox.

2017-08-27 Thread Terry J. Reedy
Terry J. Reedy added the comment: Additional patch or patches will be on generalized issue #31288. -- title: IDLE tests: don't modify tkinter.messagebox. -> IDLE configdialog tests: don't modify tkinter.messagebox. ___ Python tracker

Re: BeautifulSoup doesn't work with a threaded input queue?

2017-08-27 Thread Christopher Reimer via Python-list
On 8/27/2017 1:12 PM, MRAB wrote: What do you mean by "queue (random order)"? A queue is sequential order, first-in-first-out. With 20 threads requesting 20 different pages, they're not going into the queue in sequential order (i.e., 0, 1, 2, ..., 17, 18, 19) and coming in at different

Re: BeautifulSoup doesn't work with a threaded input queue?

2017-08-27 Thread Christopher Reimer via Python-list
On 8/27/2017 1:50 PM, MRAB wrote: What if you don't sort the list? I ask because it sounds like you're changing 2 variables (i.e. list->queue, sorted->unsorted) at the same time, so you can't be sure that it's the queue that's the problem. If I'm using a list, I'm using a for loop to input

Re: BeautifulSoup doesn't work with a threaded input queue?

2017-08-27 Thread Paul Rubin
Christopher Reimer writes: > I have 20 read_threads requesting and putting pages into the output > queue that is the input_queue for the parser. Given how slow parsing is, you probably want to scrap the pages into disk files, and then run the parser in parallel

[issue30617] IDLE: Add docstrings and unittests to outwin.py

2017-08-27 Thread Terry J. Reedy
Changes by Terry J. Reedy : -- pull_requests: +3265 ___ Python tracker ___ ___

[issue30617] IDLE: Add docstrings and unittests to outwin.py

2017-08-27 Thread Terry J. Reedy
Changes by Terry J. Reedy : -- resolution: -> fixed stage: -> resolved status: open -> closed versions: +Python 3.6 ___ Python tracker

[issue27099] IDLE: turn built-in extensions into regular modules

2017-08-27 Thread Terry J. Reedy
Changes by Terry J. Reedy : -- title: IDLE: turn builting extensions into regular modules -> IDLE: turn built-in extensions into regular modules ___ Python tracker

Re: BeautifulSoup doesn't work with a threaded input queue?

2017-08-27 Thread MRAB
On 2017-08-27 20:35, Christopher Reimer via Python-list wrote: On 8/27/2017 11:54 AM, Peter Otten wrote: The documentation https://www.crummy.com/software/BeautifulSoup/bs4/doc/#making-the-soup says you can make the BeautifulSoup object from a string or file. Can you give a few more details

Re: BeautifulSoup doesn't work with a threaded input queue?

2017-08-27 Thread Peter Otten
Christopher Reimer via Python-list wrote: > On 8/27/2017 11:54 AM, Peter Otten wrote: > >> The documentation >> >> https://www.crummy.com/software/BeautifulSoup/bs4/doc/#making-the-soup >> >> says you can make the BeautifulSoup object from a string or file. >> Can you give a few more details

[issue31287] IDLE configdialog tests: don't modify tkinter.messagebox.

2017-08-27 Thread Terry J. Reedy
Terry J. Reedy added the comment: New changeset 3457f428964d0fd6ab601272ead276a9bf8b1eaf by Terry Jan Reedy in branch 'master': bpo-31287: IDLE - do not alter tkinter.messagebox in configdialog tests. (#3220) https://github.com/python/cpython/commit/3457f428964d0fd6ab601272ead276a9bf8b1eaf

[issue31287] IDLE configdialog tests: don't modify tkinter.messagebox.

2017-08-27 Thread Cheryl Sabella
Changes by Cheryl Sabella : -- pull_requests: +3263 ___ Python tracker ___ ___

Re: BeautifulSoup doesn't work with a threaded input queue?

2017-08-27 Thread Christopher Reimer via Python-list
On 8/27/2017 1:31 PM, Peter Otten wrote: Here's a simple example that extracts titles from generated html. It seems to work. Does it resemble what you do? Your example is similar to my code when I'm using a list for the input to the parser. You have soup_threads and write_threads, but no

[issue23835] configparser does not convert defaults to strings

2017-08-27 Thread Łukasz Langa
Changes by Łukasz Langa : -- resolution: -> fixed stage: -> resolved status: open -> closed ___ Python tracker ___

[issue30617] IDLE: Add docstrings and unittests to outwin.py

2017-08-27 Thread Terry J. Reedy
Terry J. Reedy added the comment: New changeset 998f4966bf0c591f3e8b3d07eccad7501f60f524 by Terry Jan Reedy (Cheryl Sabella) in branch 'master': bpo-30617: IDLE: docstrings and unittest for outwin.py (#2046) https://github.com/python/cpython/commit/998f4966bf0c591f3e8b3d07eccad7501f60f524

Re: BeautifulSoup doesn't work with a threaded input queue?

2017-08-27 Thread Christopher Reimer via Python-list
Ah, shoot me. I had a .join() statement on the output queue but not on in the input queue. So the threads for the input queue got terminated before BeautifulSoup could get started. I went down that same rabbit hole with CSVWriter the other day. *sigh* Thanks for everyone's help. Chris R. --

Re: Need advice on writing better test cases.

2017-08-27 Thread Ben Finney
Anubhav Yadav writes: > I want to write more test cases, specially that rely on database > insertions and reads and file IO. Thanks for taking seriously the importance of test cases for your code! One important thing to recognise is that a unit test is only one type of

[issue30780] IDLE: configdialog - add tests for ConfigDialog GUI.

2017-08-27 Thread Terry J. Reedy
Changes by Terry J. Reedy : -- dependencies: +IDLE tests: don't modify tkinter.messagebox. nosy: +csabella ___ Python tracker ___

[issue31287] IDLE tests: don't modify tkinter.messagebox.

2017-08-27 Thread Terry J. Reedy
New submission from Terry J. Reedy: test_configdialog twice patches tkinter.messagebox to mock askyesno without restoring it properly. As a consequence, the outwin test in #30617 failed because the messagebox module in editor lacked askyesno. First patch: fix configdialog and

Re: BeautifulSoup doesn't work with a threaded input queue?

2017-08-27 Thread Christopher Reimer via Python-list
On 8/27/2017 11:54 AM, Peter Otten wrote: The documentation https://www.crummy.com/software/BeautifulSoup/bs4/doc/#making-the-soup says you can make the BeautifulSoup object from a string or file. Can you give a few more details where the queue comes into play? A small code sample would be

[issue31287] IDLE tests: don't modify tkinter.messagebox.

2017-08-27 Thread Terry J. Reedy
Changes by Terry J. Reedy : -- pull_requests: +3260 ___ Python tracker ___ ___

[issue30617] IDLE: Add docstrings and unittests to outwin.py

2017-08-27 Thread Cheryl Sabella
Changes by Cheryl Sabella : -- pull_requests: +3261 ___ Python tracker ___ ___

[issue31284] IDLE: Make GUI test teardown less fragile

2017-08-27 Thread Terry J. Reedy
Terry J. Reedy added the comment: I closed the patch; you can delete the branch. I changed the title to express the goal, though I am not sure how to get there yet. One thing is to be more aware of what callbacks and event loops are being set up and possibly not shut down gracefully. Your

Need advice on writing better test cases.

2017-08-27 Thread Anubhav Yadav
Hello, I am a (self-learned) python developer and I write a lot of python code everyday. I try to do as much unit testing as possible. But I want to be better at it, I want to write more test cases, specially that rely on database insertions and reads and file IO. Here are my use-cases for

Re: Express thanks

2017-08-27 Thread Abdur-Rahmaan Janhangeer
hi, liking py, i follow py discuss at pretty some places, i can say that upto now, py mailing lists are awesome just make a drop on irc ... Keep it up guys ! Abdur-Rahmaan Janhangeer, Mauritius abdurrahmaanjanhangeer.wordpress.com On 21 Aug 2017 18:38, "Hamish MacDonald"

Re: BeautifulSoup doesn't work with a threaded input queue?

2017-08-27 Thread Peter Otten
Christopher Reimer via Python-list wrote: > On 8/27/2017 1:31 PM, Peter Otten wrote: > >> Here's a simple example that extracts titles from generated html. It >> seems to work. Does it resemble what you do? > Your example is similar to my code when I'm using a list for the input > to the parser.

[issue31191] Fix grammar in threading.Barrier docs

2017-08-27 Thread Mariatta Wijaya
Changes by Mariatta Wijaya : -- resolution: -> fixed stage: backport needed -> resolved status: open -> closed ___ Python tracker

[issue31191] Fix grammar in threading.Barrier docs

2017-08-27 Thread Mariatta Wijaya
Mariatta Wijaya added the comment: New changeset 2dfafa3c565c0b51920269a891fa270848b378d5 by Mariatta in branch '3.6': bpo-31191: Improve grammar in threading.Barrier docs (GH-3080) (GH-3224) https://github.com/python/cpython/commit/2dfafa3c565c0b51920269a891fa270848b378d5 --

[issue30617] IDLE: Add docstrings and unittests to outwin.py

2017-08-27 Thread Terry J. Reedy
Terry J. Reedy added the comment: New changeset 5c89c2fd8a0be0ad2f89f084775c5f9f76687237 by Terry Jan Reedy in branch '3.6': [3.6] bpo-30617: IDLE: docstrings and unittest for outwin.py (GH-2046) (#3223) https://github.com/python/cpython/commit/5c89c2fd8a0be0ad2f89f084775c5f9f76687237

[issue19431] Document PyFrame_FastToLocals() and PyFrame_FastToLocalsWithError()

2017-08-27 Thread Cheryl Sabella
Cheryl Sabella added the comment: Victor, Should there be a PR for this? -- nosy: +csabella ___ Python tracker ___

[issue18975] timeit: Use thousands separators and print number of loops per second

2017-08-27 Thread Cheryl Sabella
Cheryl Sabella added the comment: Reviewing this patch, it appears that the PEP8 changes to timeit.py are already in the source and the discussion of the thousands separator is no longer an issue with the underscore changes in 3.6 (meaning underscore now seems the way to separate digits in

[issue27181] Add geometric mean to `statistics` module

2017-08-27 Thread Cheryl Sabella
Cheryl Sabella added the comment: I was wondering if this has been taken up again for 3.7? Thanks! -- nosy: +csabella ___ Python tracker ___

BeautifulSoup doesn't work with a threaded input queue?

2017-08-27 Thread Christopher Reimer via Python-list
Greetings, I have Python 3.6 script on Windows to scrape comment history from a website. It's currently set up this way: Requestor (threads) -> list -> Parser (threads) -> queue -> CVSWriter (single thread) It takes 15 minutes to process ~11,000 comments. When I replaced the list with a

[issue31285] a SystemError and an assertion failure in warnings.warn_explicit()

2017-08-27 Thread Oren Milman
Changes by Oren Milman : -- pull_requests: +3259 ___ Python tracker ___ ___

[issue2190] MozillaCookieJar ignore HttpOnly cookies

2017-08-27 Thread Mike Thomas
Mike Thomas added the comment: Can this issue be reopened? As Jérémie stated, curl uses this format and outputs cookie files using the #HttpOnly_ prefix. I also found at least one project that is working around lack of this support: https://code.google.com/archive/p/git-repo/

[issue31284] IDLE: Fix WindowList invalid command name error when running tests

2017-08-27 Thread Cheryl Sabella
Cheryl Sabella added the comment: Thank you for taking the time to research and explain that. It's funny, but on my code example, I got it to happen every time and you said it didn't happen unless you made the change to use root.update() and root.destroy(). I tried it out again and realized

[issue26656] Documentation for re.compile is a bit outdated

2017-08-27 Thread Roundup Robot
Changes by Roundup Robot : -- pull_requests: +3268 ___ Python tracker ___

[issue26656] Documentation for re.compile is a bit outdated

2017-08-27 Thread Mariatta Wijaya
Mariatta Wijaya added the comment: There are two PRs for this issue. I accepted the earlier one, and it's been backported to 3.6. Thanks everyone. -- resolution: -> fixed stage: -> resolved status: open -> closed versions: -Python 3.5 ___ Python

[issue31282] C APIs called without GIL in PyOS_Readline

2017-08-27 Thread Xiang Zhang
Xiang Zhang added the comment: In pymem.h, it's stated that "The GIL must be held when using these APIs". I think the reason is when PYMALLOC_DEBUG is defined, they finally delegate to PyObject_Malloc. Victor must be familiar with them since once he proposed to remote the restriction:

[issue26656] Documentation for re.compile is a bit outdated

2017-08-27 Thread Mariatta Wijaya
Mariatta Wijaya added the comment: New changeset ed94a8b2851914bcda3a77b28b25517b8baa91e6 by Mariatta (Henk-Jaap Wagenaar) in branch 'master': bpo-26656: Improve re.compile documentation (GH-3211) https://github.com/python/cpython/commit/ed94a8b2851914bcda3a77b28b25517b8baa91e6 --

[issue31282] C APIs called without GIL in PyOS_Readline

2017-08-27 Thread Xiang Zhang
Changes by Xiang Zhang : -- stage: -> needs patch versions: +Python 3.6, Python 3.7 ___ Python tracker ___

[issue29456] bugs in unicodedata.normalize: u1176, u11a7 and u11c3

2017-08-27 Thread Wonsup Yoon
Wonsup Yoon added the comment: Hello? -- ___ Python tracker ___ ___ Python-bugs-list mailing list

[issue31244] IDLE: work around shortcuts bug in Windows' IMEs and tk

2017-08-27 Thread Constantine Ketskalo
Constantine Ketskalo added the comment: Impossible... Yea, right... Will documenting it help to solve it? If that's impossible, then how do other programs deal with it? What does make Python so special? I still don't see anything impossible. If other programs can do it but Python IDLE can't do

[issue31282] C APIs called without GIL in PyOS_Readline

2017-08-27 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: AFAIK PyMem_Malloc/MALLOC can be used with released GIL. -- ___ Python tracker ___

[issue26656] Documentation for re.compile is a bit outdated

2017-08-27 Thread Mariatta Wijaya
Changes by Mariatta Wijaya : -- pull_requests: +3267 ___ Python tracker ___ ___

[issue26656] Documentation for re.compile is a bit outdated

2017-08-27 Thread Mariatta Wijaya
Mariatta Wijaya added the comment: New changeset 83e5c888fff2bf3663952b2bfd3a3ee6c20386ef by Mariatta in branch '3.6': [3.6] bpo-26656: Improve re.compile documentation (GH-3211) (GH-3225) https://github.com/python/cpython/commit/83e5c888fff2bf3663952b2bfd3a3ee6c20386ef --