This is an invite to all core-python developers, and developers of
alternative implementations, to attend the Python Language Summit at
EuroPython. The summit will be on June 19th and EuroPython this year
will be held at the beautiful city of Florence in Italy.
If you are not a core-Python developer but would like to attend then
please email me privately and I will let you know if spaces are
available. If you are a core developer, or you have received a direct
invitation, then please respond by private email to let me know if you
are able to attend. A maybe is fine, you can always change your mind
later. Attending for only part of the day is fine.
We expect the summit to run from 10am - 4pm with appropriate breaks.
Like previous language summits it is an opportunity to discuss topics
like, Python 3 adoption, PEPs and changes for Python 3.3, the future of
Python 2.7, documentation, package index, web site, etc.
If you have topics you'd like to discuss at the language summit please
let me know.
Volunteers for taking notes at the language summit, for posting to
Python-dev and the Python Insiders blog after the event, would be much
All the best,
N.B. Due to my impending doom (oops, I mean impending fatherhood) I am
not yet 100% certain I will be able to attend. If I can't I will arrange
for someone else to chair.
May you do good and not evil
May you find forgiveness for yourself and forgive others
May you share freely, never taking more than you give.
-- the sqlite blessing http://www.sqlite.org/different.html
A friend at work who is new to Python wondered why this didn't work with
self.i = Outer.Inner()
> From that:
> # functions defined at the top level of a module
> # built-in functions defined at the top level of a module
> # classes that are defined at the top level of a module
I've never questions this, but I wonder, is this a fundamental restriction
or could it be overcome with a modest amount of work?
Sincere apologies for posting a question without lurking for a while
first. I'm not sure whether I'm being dumb (which is very plausible) or
whether this is a potential bug. I asked on comp.lang.python but
responses were equivocal, so I'm following the README.txt advice and
asking here. If I'm out of line, do feel free to slap me down viciously,
remove me from the list, or whatever seems most appropriate.
Under py3k, is it necessary to flush() a file between buffered
read/write calls in order to see consistent results? I have a case under
Python 3.2 (r32:88445) where I see different results depending on
whether buffering is active, on Gentoo Linux and Windows Vista. Perusing
the docs and PEPs I couldn't seem to find an answer; I did find
bufferedio.c's comment: "BufferedReader, BufferedWriter and
BufferedRandom...share a single buffer...this enables interleaved reads
and writes without flushing" which is suggestive but I may be taking it
out of context.
The following is the smallest code I can conjure which demonstrates the
issue I'm seeing:
START = 0
MID = 1
LENGTH = 4
f = open("test.bin", "w+b", buffering = buffering)
for i in range(LENGTH):
print("Buffered result: ")
Output on both Gentoo and Vista is:
I expected the results to be the same, but they aren't. The issue is
reproducible with larger files provided that the constants are increased
~proportionally (START 0, MID 500, LENGTH 1000 for example). Transposing
the buffered/unbuffered tests and/or using different buffer sizes for
the buffered test seem have no effect.
Apologies once more if I'm wasting your time.
All the best,
PS. By way of entirely belated introduction, I'm a UK software developer
with a background mostly in C#, C++ and Lua in both "real software" and
commercial games. In my spare time I mostly write code (curiously I
don't know many developers who do; I suspect I just know the wrong
people.) I perpetrated the Trizbort mapper for interactive fiction which
doubtless nobody will have heard of, and with good reason. I'm toying
with Python as a genuinely portable alternative to C# for my own
projects, and so far loving it.
A commit (push) partition time and behavior into before and after (with
a short change period in between during which behavior is undefined).
Some commit messages have the form 'x does y'. Does 'does' mean before
or after? Sometimes that is clear. 'x crashes' means before. 'x return
correct value' means after. But some messages of this type are unclear
to me as written.
Consider 'x raises exception'? The temporal reference is obvious to the
committer but not necessary to everyone else. It could mean 'x used to
segfault and now raises a catchable exception'. There was a fix like
this (with a clear message) just today. It could also mean 'x used to
raise but now return an answer. There have been many fixes like this.
Two minimal fixes are 'x raised exception' or 'make x raise exception'.
Terry Jan Reedy
Commit changelogs are important to understand why the code was changed.
I regulary use hg blame to search which commit introduced a particular
line of code, and I am always happy if I can find an issue number
because it usually contains the whole story.
And since the migration to Mercurial, we have also a great tool adding a
comment to an issue if the changelog contains an issue number (e.g.
changelog starting with "Issue #118888: ..."). So if someone watchs an
issue (is in the nosy list), (s)he will be noticed that a related commit
was pushed. It is not exactly something new: we already do that with
Subversion except that today it is more automatic.
I noticed that some recent commits don't contain the issue number:
please try to always prefix your changelog with the issue number. It is
not "mandatory", but it helps me when I dig the Python history.
For merge commits: many developers just write "merge" or "merge 3.1". I
have to go to the parent commit (and something to the grandparent,
3.1->3.2->3.3) to learn more about the commit.
Would it be possible to repeat the changelog of the original commit in
the merge commits? svnmerge toold prepared a nice changelog containing
the changelog of all pendings commits, even when a commit was "blocked".
For a merge commit, I copy/paste the changelog of the original commit
and I add a "(Merge 3.1) " prefix. I prefer to add explictly a prefix
because it is not easy to notice that it is a merge commit in a
python-checkins email or in the history of hg.python.org.
We need maybe new tools to help the process.
Usecases needing better changelogs:
- "All changes" section of a buildbot build
- hg blame (or just hg log)
If you plan to attend, you could save quite a bit on registration fees!
The end of Early bird is on May 12th, Friday, 23:59:59 CEST. We'd like
to ask to you to forward this post to anyone that you feel may be
We have an amazing lineup of tutorials, events and talks. We have some
excellent keynote speakers and a very complete partner program... but
early bird registration ends in 2 days!
Right now, you still get discounts on talks and tutorials so if you
plan to attend Register Now:
While you are booking, remember to have a look at the partner program
and our offer for a prepaid, data+voice+tethering SIM.
We'd like to ask to you to forward this post to anyone that you feel
may be interested.
All the best,
I have a question: would it be possible to mask all signals in the Tcl
thread? To understand the question, let's see the context...
I'm working on signals, especially on pthread_sigmask(), and I'm trying
to understand test_signal failures.
test_signal fails if the _tkinter module is loaded, because _tkinter
loads the Tcl library which create a thread waiting events in select().
For example, "python -m test test_pydoc test_signal" fails, because
test_pydoc loads ALL Python modules. I opened an issue for test_pydoc:
_tkinter.c contains the following code:
/* This was not a good idea; through <Destroy> bindings,
Tcl_Finalize() may invoke Python code but at that point the
interpreter and thread state have already been destroyed! */
Tcl_Finalize() exits the thread, but this function is never called in
Python. Anyway, it is not possible to unload a module implemented in C.
I would like to know if it would be possible to mask all signals in the
Tcl thread, or if Tcl supports/uses signals.
It is possible to mask all signals in the Tcl thread using:
allsignals = range(1, signal.NSIG)
oldmask = signal.pthread_sigmask(signal.SIG_BLOCK, allsignals)
I'm not asking the question for test_signal: I have a patch fixing
test_signal, even if the Tcl zombi thread is present (use pthread_kill()
to send the signal directly to the main thread).
(I wrote "zombi" thread because I was not aware that Tcl uses a thread,
nor that test_pydoc loads all modules. The thread is valid, alive, and
it's just a joke. The threads is more hidden than zombi.)
On Tue, May 10, 2011 at 10:10:15AM +0200, vinay.sajip wrote:
> diff --git a/Lib/test/test_logging.py b/Lib/test/test_logging.py
> --- a/Lib/test/test_logging.py
> +++ b/Lib/test/test_logging.py
> @@ -1489,6 +1489,7 @@
> self.post_data = None
> + request.end_headers()
This is accurate. It should have resulted from the change made in the
http.server, because the headers are now cached and then written to
the output stream in one-shot when end_headers/flush_headers are