[issue13881] Stream encoder for zlib_codec doesn't use the incremental encoder

2015-07-15 Thread Martin Panter
Changes by Martin Panter vadmium...@gmail.com: -- dependencies: +Fix codecs.iterencode/decode() by allowing data parameter to be omitted stage: - patch review ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue13881

Re: Noob in Python. Problem with fairly simple test case

2015-07-15 Thread Larry Hudson via Python-list
On 07/15/2015 05:11 AM, Chris Angelico wrote: On Wed, Jul 15, 2015 at 9:44 PM, Jason P. suscrici...@gmail.com wrote: I can't understand very well what's happening. It seems that the main thread gets blocked listening to the web server. My intent was to spawn another process for the server

[issue23247] Crash in the reset() method of StreamWriter of CJK codecs

2015-07-15 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: cjk_codecs_reset.patch LGTM. -- assignee: serhiy.storchaka - haypo stage: - test needed ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue23247 ___

[issue23247] Crash in the reset() method of StreamWriter of CJK codecs

2015-07-15 Thread Aaron Hill
Aaron Hill added the comment: The patch didn't get attached for some reason. It's attached now. -- Added file: http://bugs.python.org/file39933/fix-multibytecodec-segfault.patch ___ Python tracker rep...@bugs.python.org

Re: Noob in Python. Problem with fairly simple test case

2015-07-15 Thread Chris Angelico
On Thu, Jul 16, 2015 at 1:01 PM, Larry Hudson via Python-list python-list@python.org wrote: On 07/15/2015 05:11 AM, Chris Angelico wrote: On Wed, Jul 15, 2015 at 9:44 PM, Jason P. suscrici...@gmail.com wrote: I can't understand very well what's happening. It seems that the main thread gets

Re: Noob in Python. Problem with fairly simple test case

2015-07-15 Thread Chris Angelico
On Thu, Jul 16, 2015 at 1:33 PM, Rick Johnson rantingrickjohn...@gmail.com wrote: On Wednesday, July 15, 2015 at 10:11:43 PM UTC-5, Chris Angelico wrote: That's a neat trick, as long as you actually do have a console. Well if you don't have a console, another option is to use the dialogs of

Re: Mapping, with sequence as key, wildcard and subsequence matching

2015-07-15 Thread Steven D'Aprano
On Thu, 16 Jul 2015 11:51 am, Ben Finney wrote: Howdy all, What well-defined data type exists with the following properties: * Mapping, key → value. * Each key is a sequence (e.g. `tuple`) of items such as text strings. * Items in a key may be the sentinel `ANY` value, which will

Mapping, with sequence as key, wildcard and subsequence matching

2015-07-15 Thread Ben Finney
Howdy all, What well-defined data type exists with the following properties: * Mapping, key → value. * Each key is a sequence (e.g. `tuple`) of items such as text strings. * Items in a key may be the sentinel `ANY` value, which will match any value at that position. * A key may specify that

[issue23661] Setting a exception side_effect on a mock from create_autospec does not work

2015-07-15 Thread Berker Peksag
Changes by Berker Peksag berker.pek...@gmail.com: -- resolution: - fixed stage: - resolved status: open - closed versions: +Python 3.6 -Python 3.4 ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue23661

Re: Noob in Python. Problem with fairly simple test case

2015-07-15 Thread Rick Johnson
On Wednesday, July 15, 2015 at 10:11:43 PM UTC-5, Chris Angelico wrote: That's a neat trick, as long as you actually do have a console. Well if you don't have a console, another option is to use the dialogs of the batteries included GUI named Tkinter. from tkMessageBox import showinfo #

Re: Keypress Input

2015-07-15 Thread Michael Torrie
On 07/15/2015 07:03 PM, Rick Johnson wrote: too much to quote I think you've missed the whole point of the OP's project. He doesn't want to make a GUI. He simply wants to have his program do something like blink an LED when someone presses a big red button. He just wanted a quick way to test

Re: Mapping, with sequence as key, wildcard and subsequence matching

2015-07-15 Thread Terry Reedy
On 7/15/2015 9:51 PM, Ben Finney wrote: Howdy all, What well-defined data type exists with the following properties: * Mapping, key → value. * Each key is a sequence (e.g. `tuple`) of items such as text strings. * Items in a key may be the sentinel `ANY` value, which will match any value

Re: Mapping, with sequence as key, wildcard and subsequence matching

2015-07-15 Thread Ben Finney
Steven D'Aprano st...@pearwood.info writes: Sounds like a regular expression. Remember that computer science theoretical regular expressions don't just match strings, they can apply to any sequence of primitive values. Good insight, thank you. In your case, you only need two special tokens,

[issue23963] Windows build error using original openssl source

2015-07-15 Thread Zachary Ware
Zachary Ware added the comment: bcf93e3766e8 applied cleanly to 2.7, so I just used it. Thanks for the report, and sorry it took so long to fix! -- assignee: - zach.ware ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue23963

[issue24635] test_typing is flaky

2015-07-15 Thread Raymond Hettinger
Changes by Raymond Hettinger raymond.hettin...@gmail.com: -- nosy: +lukasz.langa ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue24635 ___ ___

[issue23963] Windows build error using original openssl source

2015-07-15 Thread Roundup Robot
Roundup Robot added the comment: New changeset d1f4d14bd550 by Zachary Ware in branch '2.7': Close #23963: Fix building with original OpenSSL sources. https://hg.python.org/cpython/rev/d1f4d14bd550 -- nosy: +python-dev resolution: - fixed stage: - resolved status: open - closed

[issue23247] Crash in the reset() method of StreamWriter of CJK codecs

2015-07-15 Thread Aaron Hill
Aaron Hill added the comment: The included patch fixes the issue, and modifies the existing unittest to prevent a future regression. The patch corrects an issue where the 'pending' struct field was NULL, but was used as the input to multibytecodec_encode anyay. --

[issue24626] please sync cgi.parse document

2015-07-15 Thread Berker Peksag
Changes by Berker Peksag berker.pek...@gmail.com: -- nosy: +berker.peksag ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue24626 ___ ___

[issue24508] Backport 3.5's Windows build project files to 2.7

2015-07-15 Thread Roundup Robot
Roundup Robot added the comment: New changeset ca78b9449e04 by Zachary Ware in branch '2.7': Close #24508: Backport the 3.5 MSBuild project files. https://hg.python.org/cpython/rev/ca78b9449e04 -- nosy: +python-dev resolution: - fixed stage: patch review - resolved status: open -

[issue23247] Crash in the reset() method of StreamWriter of CJK codecs

2015-07-15 Thread Martin Panter
Martin Panter added the comment: Perhaps this test case proposed in my patch for Issue 13881 could be useful: +def test_writer_reuse(self): +StreamWriter should be reusable after reset Looks like that is where my “broken_stream_codecs” list from the original post came from. --

Re: Keypress Input

2015-07-15 Thread Rick Johnson
On Friday, June 19, 2015 at 12:20:14 AM UTC-5, Christian Gollwitzer wrote: The nonsense starts here: [...snip code...] it seems you don't understand event based programming. Duh. No need to abuse the lad. It waits for the user input and does the dispatching, i.e. when a key is pressed,

Re: Improve usage of Python 3

2015-07-15 Thread Chris Angelico
On Wed, Jul 15, 2015 at 2:28 AM, Marcos bugshide...@gmail.com wrote: And incredibly, there are a few users on the same project who refuse to use python 3 simply because of the print statement. Solution: Explain to them the massive benefits of the print function. It may be simpler to omit the

Re: Possibly Pythonic Tail Call Optimization (TCO/TRE)

2015-07-15 Thread Antoon Pardon
On 07/14/2015 07:48 PM, Steven D'Aprano wrote: On Wed, 15 Jul 2015 03:29 am, Marko Rauhamaa wrote: Chris Angelico ros...@gmail.com: On Tue, Jul 14, 2015 at 11:38 PM, Marko Rauhamaa ma...@pacujo.net wrote: No, tail call optimization doesn't change the behavior of the program, for the worse

Re: Improve usage of Python 3

2015-07-15 Thread Terry Reedy
On 7/14/2015 12:28 PM, Marcos wrote: Hi! Just like many, I want the projects in which I work on to move to Python 3. And incredibly, there are a few users on the same project who refuse to use python 3 simply because of the print statement. That has probably already been discussed, but since

data visualization - graph

2015-07-15 Thread Kasper Jepsen
Hi, I am looking for a solution to graph charts from real time measurements on the web like: http://pvoutput.org/intraday.jsp?id=16919sid=14707gs=1dxa=1dt=20150715 I have some solar systems i like to save data into an sql database - and then i like to have some web service where i can select

Re: Possibly Pythonic Tail Call Optimization (TCO/TRE)

2015-07-15 Thread Marko Rauhamaa
Gregory Ewing greg.ew...@canterbury.ac.nz: A tail call *is* a goto. That's how you implement one in assembly language -- you write a jump instruction instead of a call instruction. The jump doesn't have to be to the same function. In functional programming languages you might not even have a

EuroPython 2015: Guggenheim and Fine Arts Museum

2015-07-15 Thread M.-A. Lemburg
EuroPython is not the only attraction in Bilbao to attend in July. The city also hosts the famous *Guggenheim Museum*, featuring modern art in an amazing building designed by Frank O. Gehry. See below for a special deal we have available for the Guggenheim. You can also find the *Fine Arts

Re: data visualization - graph

2015-07-15 Thread Mark Lawrence
On 15/07/2015 09:08, Kasper Jepsen wrote: Hi, I am looking for a solution to graph charts from real time measurements on the web like: http://pvoutput.org/intraday.jsp?id=16919sid=14707gs=1dxa=1dt=20150715 I have some solar systems i like to save data into an sql database - and then i like

Re: Possibly Pythonic Tail Call Optimization (TCO/TRE)

2015-07-15 Thread Antoon Pardon
On 07/15/2015 02:41 AM, Terry Reedy wrote: On 7/14/2015 10:02 AM, Antoon Pardon wrote: On 07/14/2015 03:43 PM, Chris Angelico wrote: On Tue, Jul 14, 2015 at 11:38 PM, Marko Rauhamaa ma...@pacujo.net wrote: No, tail call optimization doesn't change the behavior of the program, for the worse

Re: Possibly Pythonic Tail Call Optimization (TCO/TRE)

2015-07-15 Thread Gregory Ewing
Chris Angelico wrote: I'm still interested in the explicit replace current stack frame with this call operation. Calling it goto seems wrong, as most languages with goto restrict it to _within_ a function, This just suggests to me is that most language designers are not very imaginative. :-)

Re: A new module for performing tail-call elimination

2015-07-15 Thread Antoon Pardon
On 07/13/2015 05:44 PM, Th. Baruchel wrote: Hi, after having spent much time thinking about tail-call elimination in Python (see for instance http://baruchel.github.io/blog/ ), I finally decided to write a module for that. You may find it at: https://github.com/baruchel/tco Tail-call

Re: Possibly Pythonic Tail Call Optimization (TCO/TRE)

2015-07-15 Thread Marko Rauhamaa
Gregory Ewing greg.ew...@canterbury.ac.nz: Marko Rauhamaa wrote: It might even be tail-call optimized by Python. Only you can't count on it because the language spec doesn't guarantee it. The language spec might permit it, but the BDFL has explicitly expressed a dislike for the idea of

Re: Can't install/uninstall Python

2015-07-15 Thread udhay prakash pethakamsetty
On Tuesday, 14 July 2015 17:24:22 UTC+5:30, Chris Angelico wrote: On Tue, Jul 14, 2015 at 7:20 AM, Thomas Via kingklong2...@hotmail.com wrote: I'm trying to reinstall Python 2.7.9/2.7.10, but during the installation, it didn't let me, which gave me this: There is a problem with this

[issue24632] Improve documentation about __main__.py

2015-07-15 Thread Ezio Melotti
Ezio Melotti added the comment: Another thing that should be clarified, is the difference between __main__.py inside a package, and __main__.py inside a zip file. For packages, as far as I understand, __main__.py should be inside the package (i.e. pkg/__main__.py, in the same dir of

ANN: psutil 3.1.0 released

2015-07-15 Thread Giampaolo Rodola'
Hello all, I'm glad to announce the release of psutil 3.1.0: https://github.com/giampaolo/psutil/ About = psutil (python system and process utilities) is a cross-platform library for retrieving information on running processes and system utilization (CPU, memory, disks, network) in Python.

Improve usage of Python 3

2015-07-15 Thread Marcos
Hi! Just like many, I want the projects in which I work on to move to Python 3. And incredibly, there are a few users on the same project who refuse to use python 3 simply because of the print statement. That has probably already been discussed, but since I actually couldn't find anything

ANN python-taiga 0.4.0

2015-07-15 Thread Andrea Stagi
Python-taiga 0.4.0 released! python-taiga is a python module for communicating with Taiga.io, a new project management platform! For more info https://taiga.io/ This release includes minfixes and support for tasks, issues and user stories history. You can find python-taiga code on Github

xlrd 0.9.4 released!

2015-07-15 Thread Chris Withers
Hi All, I'm pleased to announce the release of xlrd 0.9.4: http://pypi.python.org/pypi/xlrd/0.9.4 This release includes the following changes: - Automated tests are now run on Python 3.4 - Use ElementTree.iter() if available, not deprecated getiterator() when parsing xlsx files. - Fix

Re: Why pay DICE When TheGongzuo.com is !! FREE !!

2015-07-15 Thread Ian Kelly
On Tue, Jul 14, 2015 at 8:47 PM, Steve Hayes hayes...@telkomsa.net wrote: On Tue, 14 Jul 2015 17:31:31 -0700 (PDT), trentonwesle...@gmail.com wrote: Greetings! You been Invited as a Beta User for TheGongzuo.com ( Absolutely Extended Trial). We bring to you TheGongzuo.com, Top notch highly

[issue24632] Improve documentation about __main__.py

2015-07-15 Thread Ethan Furman
Ethan Furman added the comment: RDM noted: - The surprising thing is that __main__ works without there being an __init__. I didn't know that, assumed it wasn't true, and so never tried it. I think this is due to PEP 420 Namespace Packages. --

password authentication failed

2015-07-15 Thread Gary Roach
Every time I try to do a python manage.py migrate I get: django.db.utils.OperationalError: FATAL: password authentication failed for user postgres FATAL: password authentication failed for user postgres System Debian linux jessie python 2.79 Django 1.8 Postgresql 9.4.3 database Using

Re: password authentication failed

2015-07-15 Thread Chris Angelico
On Thu, Jul 16, 2015 at 3:13 AM, Gary Roach gary719_li...@verizon.net wrote: Every time I try to do a python manage.py migrate I get: django.db.utils.OperationalError: FATAL: password authentication failed for user postgres FATAL: password authentication failed for user postgres

[issue23530] os and multiprocessing.cpu_count do not respect cpuset/affinity

2015-07-15 Thread Charles-François Natali
Charles-François Natali added the comment: It's just a doc improvement, I'm not convinced it really needs backporting. -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue23530 ___

Re: Possibly Pythonic Tail Call Optimization (TCO/TRE)

2015-07-15 Thread Ned Batchelder
On Wednesday, July 15, 2015 at 2:44:55 AM UTC-4, Marko Rauhamaa wrote: Gregory Ewing greg.ew...@canterbury.ac.nz: Marko Rauhamaa wrote: It might even be tail-call optimized by Python. Only you can't count on it because the language spec doesn't guarantee it. The language spec might

Re: Possibly Pythonic Tail Call Optimization (TCO/TRE)

2015-07-15 Thread Ned Batchelder
On Wednesday, July 15, 2015 at 6:56:10 AM UTC-4, Marko Rauhamaa wrote: Ned Batchelder n...@nedbatchelder.com: On Wednesday, July 15, 2015 at 2:44:55 AM UTC-4, Marko Rauhamaa wrote: The other problem for tail call elimination is the requirement that functions return None by default. Smooth

[issue24632] Improve documentation about __main__.py

2015-07-15 Thread R. David Murray
R. David Murray added the comment: The surprising thing is that __main__ works without there being an __init__. I didn't know that, assumed it wasn't true, and so never tried it. -- ___ Python tracker rep...@bugs.python.org

Re: Noob in Python. Problem with fairly simple test case

2015-07-15 Thread Chris Angelico
On Wed, Jul 15, 2015 at 9:44 PM, Jason P. suscrici...@gmail.com wrote: I can't understand very well what's happening. It seems that the main thread gets blocked listening to the web server. My intent was to spawn another process for the server independent of the test. Obviously I'm doing

[issue24636] re.search not respecting anchor markers in or-ed construction

2015-07-15 Thread Almer Tigelaar
New submission from Almer Tigelaar: From the documentation ^ should restrict the matching of re.search to the beginning of the string, as mentioned here: https://docs.python.org/3.4/library/re.html#search-vs-match However, this doesn't always seem to work as the following example shows:

Re: Possibly Pythonic Tail Call Optimization (TCO/TRE)

2015-07-15 Thread Antoon Pardon
On 07/15/2015 12:55 PM, Marko Rauhamaa wrote: Ned Batchelder n...@nedbatchelder.com: On Wednesday, July 15, 2015 at 2:44:55 AM UTC-4, Marko Rauhamaa wrote: The other problem for tail call elimination is the requirement that functions return None by default. Smooth tail call elimination would

Re: Possibly Pythonic Tail Call Optimization (TCO/TRE)

2015-07-15 Thread Mark Lawrence
On 15/07/2015 10:13, Gregory Ewing wrote: Chris Angelico wrote: I'm still interested in the explicit replace current stack frame with this call operation. Calling it goto seems wrong, as most languages with goto restrict it to _within_ a function, This just suggests to me is that most

Re: Possibly Pythonic Tail Call Optimization (TCO/TRE)

2015-07-15 Thread Marko Rauhamaa
Ned Batchelder n...@nedbatchelder.com: On Wednesday, July 15, 2015 at 6:56:10 AM UTC-4, Marko Rauhamaa wrote: Ned Batchelder n...@nedbatchelder.com: I don't understand this, can you explain more? Are you saying that the Python specification shouldn't specify what x becomes?: def

[issue24632] Improve documentation about __main__.py

2015-07-15 Thread Ezio Melotti
Ezio Melotti added the comment: After further tests, I think I figured out how things works. There are three separate things that interact with each other: * packages (dirs with an __init__.py) and regular dirs (with no __init__.py) or zip files; * how python is executed (with or without

Re: xlrd 0.9.4 released!

2015-07-15 Thread Karim
On 15/07/2015 08:27, Chris Withers wrote: Hi All, I'm pleased to announce the release of xlrd 0.9.4: http://pypi.python.org/pypi/xlrd/0.9.4 This release includes the following changes: - Automated tests are now run on Python 3.4 - Use ElementTree.iter() if available, not deprecated

Re: Possibly Pythonic Tail Call Optimization (TCO/TRE)

2015-07-15 Thread Marko Rauhamaa
Ned Batchelder n...@nedbatchelder.com: On Wednesday, July 15, 2015 at 2:44:55 AM UTC-4, Marko Rauhamaa wrote: The other problem for tail call elimination is the requirement that functions return None by default. Smooth tail call elimination would require that Python leave the default return

Noob in Python. Problem with fairly simple test case

2015-07-15 Thread Jason P.
Hi all! I'm working in a little Python exercise with testing since the beginning. So far I'm with my first end to end test (not even finished yet) trying to: 1) Launch a development web server linked to a demo app that just returns 'Hello World!' 2) Make a GET request successfully I can't

Re: Possibly Pythonic Tail Call Optimization (TCO/TRE)

2015-07-15 Thread MRAB
On 2015-07-15 12:22, Mark Lawrence wrote: On 15/07/2015 10:13, Gregory Ewing wrote: Chris Angelico wrote: I'm still interested in the explicit replace current stack frame with this call operation. Calling it goto seems wrong, as most languages with goto restrict it to _within_ a function,

[issue24631] Regression in timeit with multyline setup

2015-07-15 Thread Serhiy Storchaka
Changes by Serhiy Storchaka storch...@gmail.com: -- resolution: - fixed stage: commit review - resolved status: open - closed ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue24631 ___

[issue24631] Regression in timeit with multyline setup

2015-07-15 Thread Roundup Robot
Roundup Robot added the comment: New changeset fce682a493e7 by Serhiy Storchaka in branch '3.5': Issue #24631: Fixed regression in the timeit modulu with multyline setup. https://hg.python.org/cpython/rev/fce682a493e7 New changeset 0b04e5689c33 by Serhiy Storchaka in branch 'default': Issue

[issue24636] re.search not respecting anchor markers in or-ed construction

2015-07-15 Thread Serhiy Storchaka
Changes by Serhiy Storchaka storch...@gmail.com: -- nosy: +serhiy.storchaka resolution: - not a bug stage: - resolved status: open - closed ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue24636

Re: Keypress Input

2015-07-15 Thread John McKenzie
Hello, all. Thanks to everyone who responded to my post. I decided to make sure I had something that worked with what I have now and used Curses to finish it. However, it turns out that the extra work and problems with using GPIO pins and wiring up controllers that way is a small amount

Re: Keypress Input

2015-07-15 Thread Michael Torrie
On 07/15/2015 01:05 PM, John McKenzie wrote: Hello, all. Thanks to everyone who responded to my post. I decided to make sure I had something that worked with what I have now and used Curses to finish it. However, it turns out that the extra work and problems with using GPIO pins and

[issue8106] SSL session management

2015-07-15 Thread Mladen Milosevic
Changes by Mladen Milosevic milosevic.mla...@gmail.com: -- nosy: +mladen.milosevic ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue8106 ___ ___

Re: Possibly Pythonic Tail Call Optimization (TCO/TRE)

2015-07-15 Thread Gregory Ewing
Chris Angelico wrote: Which really says that TCO is impossible if you have any sort of clean-up or deallocation to be done after the call begins. The only way to truly turn your tail call into a GOTO is to do all your cleanup first. Indeed. In compilers that implement TCO, there's quite a lot

Re: Possibly Pythonic Tail Call Optimization (TCO/TRE)

2015-07-15 Thread Gregory Ewing
Mark Lawrence wrote: IIRC the realms of the C setjmp and longjmp. Not really the same thing. A longjmp chops the stack back, whereas a tail call avoids putting something on the stack to begin with. -- Greg -- https://mail.python.org/mailman/listinfo/python-list

Re: Possibly Pythonic Tail Call Optimization (TCO/TRE)

2015-07-15 Thread Gregory Ewing
Antoon Pardon wrote: But it doesn't need to be all or nothing. How about the following possibility. When the runtime detects a serie of tail calls, it will keep the bottom three and the top three backtrace records of the serie. Whatever value you choose for N, keeping only the first/last N

[issue23247] Crash in the reset() method of StreamWriter of CJK codecs

2015-07-15 Thread STINNER Victor
STINNER Victor added the comment: Happens for all the multibyte codecs: (...) All these codecs share the same C implementation: the CJK codecs. The bug was introduced in Python 3.4 by my huge changeset d621bdaed7c3: Issue #17693: CJK encoders now use the new Unicode API (PEP 393). It looks

[issue23247] Crash in the reset() method of StreamWriter of CJK codecs

2015-07-15 Thread STINNER Victor
STINNER Victor added the comment: It looks like there was no test for this specific bug :-/ Calling reset() just after creating a StreamReader object. Oops: StreamWriter, not StreamReader. -- ___ Python tracker rep...@bugs.python.org

[issue22858] unittest.__init__:main shadows unittest.main

2015-07-15 Thread Brett Cannon
Brett Cannon added the comment: Ah, I see my misunderstanding; when Antoine said Numba subclasses unittest.main I wasn't thinking and thought he meant something in unitest.main the module, not the unittest.main alias for unittest.main.TestProgram which is exposed as unitest.__init__.main

[issue22858] unittest.__init__:main shadows unittest.main

2015-07-15 Thread Brett Cannon
Brett Cannon added the comment: Or deprecate in 3.5 if Larry will let you. -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue22858 ___ ___

EuroPython 2015: Guidebook (Mobile Schedule) available

2015-07-15 Thread M.-A. Lemburg
We are pleased to announce the official guidebook for the EuroPython 2015 conference: *** https://ep2015.europython.eu/en/events/mobile-schedule/ *** We will regularly issue updates to the guidebook when there are changes in schedule. Available for all platforms

[issue24631] Regression in timeit with multyline setup

2015-07-15 Thread Brett Cannon
Brett Cannon added the comment: Patch LGTM -- stage: patch review - commit review ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue24631 ___ ___

[issue24640] no ensurepip in embedded Windows distribution

2015-07-15 Thread STINNER Victor
Changes by STINNER Victor victor.stin...@gmail.com: -- components: +Windows nosy: +paul.moore, tim.golden, zach.ware ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue24640 ___

[issue24640] no ensurepip in embedded Windows distribution

2015-07-15 Thread Chris Krycho
New submission from Chris Krycho: There is no `ensurepip` module bundled with the embedded distribution of Python 3.5 for Windows: Z:\python-3.5.0b3-embed .\python -m ensurepip --upgrade Z:\python-3.5.0b3-embed\python.exe: No module named ensurepip This may be the *intent*, but I

[issue24641] Log type of unserializable value when raising JSON TypeError

2015-07-15 Thread Madison May
New submission from Madison May: Currently the json lib only logs the string representation of the variable, which does not always include type information. I recently ran into a difficult to debug issue with code similar to the following: ``` import json import numpy as np d = {'data':

Re: A new module for performing tail-call elimination

2015-07-15 Thread Terry Reedy
On 7/15/2015 5:29 AM, Antoon Pardon wrote: On 07/13/2015 05:44 PM, Th. Baruchel wrote: Hi, after having spent much time thinking about tail-call elimination in Python (see for instance http://baruchel.github.io/blog/ ), I finally decided to write a module for that. You may find it at:

Re: Possibly Pythonic Tail Call Optimization (TCO/TRE)

2015-07-15 Thread Mark Lawrence
On 15/07/2015 23:34, Gregory Ewing wrote: Mark Lawrence wrote: IIRC the realms of the C setjmp and longjmp. Not really the same thing. A longjmp chops the stack back, whereas a tail call avoids putting something on the stack to begin with. Thanks for that :) -- My fellow Pythonistas, ask

Where is pyvenv.py in new Python3.4 environment on CentOS7?

2015-07-15 Thread David Karr
I'm just learning more about Python (although I've been a Java dev for many years, and C/C++ before that). A book I'm reading (Learning Python Network Programming) refers to running pyvenv. I can find this in my Win7 environment, but I was planning on using my CentOS7 VM for most of this. I

[issue24640] no ensurepip in embedded Windows distribution

2015-07-15 Thread STINNER Victor
Changes by STINNER Victor victor.stin...@gmail.com: -- assignee: - docs@python components: +Documentation nosy: +docs@python ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue24640 ___

[issue24640] no ensurepip in embedded Windows distribution

2015-07-15 Thread Steve Dower
Steve Dower added the comment: It's a deliberate exclusion, I just haven't gotten to all the documentation yet (mostly because I still expect things to change). My idea was that packages would be deployed statically alongside the embedded distribution rather than going into a site-packages

[issue24640] no ensurepip in embedded Windows distribution

2015-07-15 Thread Chris Krycho
Chris Krycho added the comment: Using --root or --target (as appropriate to the specific package) does appear to be the preferred approach for that, and given the constraints of an embedded installation, I agree that that's the most reasonable solution. I spent a fair bit of time reading up

[issue23972] Asyncio reuseport

2015-07-15 Thread STINNER Victor
STINNER Victor added the comment: A quick search told me that Windows only knows the SO_REUSEADDR option, there is no SO_REUSEPORT. It should be at least documented that SO_REUSEADDR is not supported on Windows. Maybe we should raise an exception on Windows if reuse_port=True? Ignoring the

[issue23926] skipitem() in getargs.c still supports 'w' and 'w#', and shouldn't

2015-07-15 Thread Joe Jevnik
Joe Jevnik added the comment: Sorry it took so long to get back to this. I didn't realize this was still open. I have provided the update to the docs and moved it to the 3.6 section. I also made sure the patch still applies and the tests all pass. -- Added file:

Re: Where is pyvenv.py in new Python3.4 environment on CentOS7?

2015-07-15 Thread Mark Lawrence
On 15/07/2015 22:54, David Karr wrote: I'm just learning more about Python (although I've been a Java dev for many years, and C/C++ before that). Welcome to the world of sanity after years of insanity :) A book I'm reading (Learning Python Network Programming) refers to running pyvenv. I

[issue23247] Multibyte codec StreamWriter.reset() crashes

2015-07-15 Thread Aaron Hill
Aaron Hill added the comment: This is also present in the latest Python 3.6. I'm going to work on providing a patch for this, unless someone else already is -- nosy: +Aaron1011 versions: +Python 3.6 ___ Python tracker rep...@bugs.python.org

[issue24636] re.search not respecting anchor markers in or-ed construction

2015-07-15 Thread Matthew Barnett
Matthew Barnett added the comment: The or-ed patterns aren't between the anchors. The ^ is at the start of the first alternative and the $ is at the end of the last alternative. -- ___ Python tracker rep...@bugs.python.org

[issue24632] Improve documentation about __main__.py

2015-07-15 Thread R. David Murray
R. David Murray added the comment: What you just described is exactly what I would have said was the case (a zip file acts exactly like it was a directory), so I'm glad that's the way it actually works :). -- nosy: +r.david.murray ___ Python

Re: Possibly Pythonic Tail Call Optimization (TCO/TRE)

2015-07-15 Thread Chris Angelico
On Wed, Jul 15, 2015 at 10:00 PM, MRAB pyt...@mrabarnett.plus.com wrote: On 2015-07-15 12:22, Mark Lawrence wrote: On 15/07/2015 10:13, Gregory Ewing wrote: Chris Angelico wrote: I'm still interested in the explicit replace current stack frame with this call operation. Calling it goto

Re: Possibly Pythonic Tail Call Optimization (TCO/TRE)

2015-07-15 Thread Chris Angelico
On Wed, Jul 15, 2015 at 7:13 PM, Gregory Ewing greg.ew...@canterbury.ac.nz wrote: Chris Angelico wrote: I'm still interested in the explicit replace current stack frame with this call operation. Calling it goto seems wrong, as most languages with goto restrict it to _within_ a function,

Nikola version 7.6.1 released

2015-07-15 Thread Roberto Alsina
On behalf of the Nikola team, I am pleased to announce the immediate availability of Nikola v7.6.1. It fixes some bugs and adds new features. What is Nikola? === Nikola is a static site and blog generator, written in Python. It can use Mako and Jinja2 templates, and input in many

Re: Possibly Pythonic Tail Call Optimization (TCO/TRE)

2015-07-15 Thread Ian Kelly
On Tue, Jul 14, 2015 at 11:27 AM, Marko Rauhamaa ma...@pacujo.net wrote: Ian Kelly ian.g.ke...@gmail.com: On Tue, Jul 14, 2015 at 2:33 AM, Marko Rauhamaa ma...@pacujo.net wrote: The programmer shouldn't be controlling tail call optimizations. The programmer controls it regardless.

[issue23972] Asyncio reuseport

2015-07-15 Thread chris laws
chris laws added the comment: Attached is a patch that implements the suggested solution along with tests and associated doc updates. Hope this helps. -- keywords: +patch Added file: http://bugs.python.org/file39930/23972_cjl.patch ___ Python

[issue24638] asyncio loop argument must agree with future error message could be improved

2015-07-15 Thread R. David Murray
R. David Murray added the comment: This error message is in tasks.py. -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue24638 ___ ___

[issue24638] asyncio loop argument must agree with future error message could be improved

2015-07-15 Thread R. David Murray
New submission from R. David Murray: I just got the titular error message and had no idea what it meant until I looked at the source. It seems to mean the specified loop is different from the _loop attribute of the future-or-coroutine. Since _loop is nominally private, perhaps the message

[issue24639] Documentation: broken link on unittest page

2015-07-15 Thread Ruth Berkow
New submission from Ruth Berkow: The documentation for unittest, in the See also box contains a link for Simple Smalltalk Testing: With Patterns that leads to a 404. Replacing this with a working link seems like a good idea; may I suggest

[issue24639] Documentation: broken link on unittest page

2015-07-15 Thread R. David Murray
R. David Murray added the comment: This has already been corrected in issue 24548 using a link to archive.org. -- nosy: +r.david.murray resolution: - duplicate stage: - resolved status: open - closed superseder: - Broken link in the unittest documentation type: performance - behavior

[issue24637] locals dictionary in PyRun_String

2015-07-15 Thread Matthew Keeter
New submission from Matthew Keeter: The C API docs for PyRun_StringFlags, PyEval_EvalCodeEx, and PyEval_EvalCode say that globals and locals both must be dictionaries. However, digging into the source [1] shows that locals can be any object implementing the mapping protocol. Furthermore,

[issue23812] asyncio.Queue.put_nowait(), followed get() task cancellation leads to item being lost

2015-07-15 Thread Gustavo J. A. M. Carneiro
Gustavo J. A. M. Carneiro added the comment: Don't know if it helps, but I made a github pull request for this: https://github.com/python/asyncio/pull/256 -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue23812

A couple virtual env questions

2015-07-15 Thread Skip Montanaro
I built and installed Python from Mercurial tip (head, whatever), so I have a Python 3.6.0a0 available. I created a virtualenv using that. Q1: Suppose I install something like matplotlib into that virtualenv which itself contains extension modules. Those will depend on the include files and

Re: Possibly Pythonic Tail Call Optimization (TCO/TRE)

2015-07-15 Thread Marko Rauhamaa
Ian Kelly ian.g.ke...@gmail.com: On Tue, Jul 14, 2015 at 11:27 AM, Marko Rauhamaa ma...@pacujo.net wrote: You'll see that the generated code is tail-call-optimized. This can't be done generally, though. What if, instead of a local variable, the assignment were to a dict item? Even if the

[issue24632] Improve documentation about __main__.py

2015-07-15 Thread Ezio Melotti
Ezio Melotti added the comment: The surprising thing is that __main__ works without there being an __init__. That's also what surprised me, I always thought __main__.py was supposed to be used within a package executed with python -m pkg, but apparently regular dirs and zip files can have

  1   2   >