[issue18174] Make regrtest with --huntrleaks check for fd leaks

2013-06-12 Thread Richard Oudkerk
Richard Oudkerk added the comment: Updated version which adds checks for handle leaks on Windows. -- Added file: http://bugs.python.org/file30561/fdleak.patch ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue18174

[issue9122] Problems with multiprocessing, Python embedding and Windows

2013-06-14 Thread Richard Oudkerk
Changes by Richard Oudkerk shibt...@gmail.com: -- nosy: +sbt ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue9122 ___ ___ Python-bugs-list mailing

[issue18214] Stop purging modules which are garbage collected before shutdown

2013-06-14 Thread Richard Oudkerk
New submission from Richard Oudkerk: Currently when a module is garbage collected its dict is purged by replacing all values except __builtins__ by None. This helps clear things at shutdown. But this can cause problems if it occurs *before* shutdown: if we use a function defined in a module

[issue18212] No way to check whether Future is finished?

2013-06-14 Thread Richard Oudkerk
Richard Oudkerk added the comment: Do you want something like f.done() and not f.cancelled() and f.exception() is None -- nosy: +sbt ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue18212

[issue18214] Stop purging modules which are garbage collected before shutdown

2013-06-15 Thread Richard Oudkerk
Changes by Richard Oudkerk shibt...@gmail.com: -- nosy: +pitrou ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue18214 ___ ___ Python-bugs-list

[issue18214] Stop purging modules which are garbage collected before shutdown

2013-06-15 Thread Richard Oudkerk
Richard Oudkerk added the comment: On 15/06/2013 7:11pm, Antoine Pitrou wrote: Usually garbage collection will end up clearing the module's dict anyway. This is not true, since global objects might have a __del__ and then hold the whole module dict alive through a reference cycle. Happily

[issue18252] timeit makes code run faster?

2013-06-18 Thread Richard Oudkerk
Richard Oudkerk added the comment: I think if you use timeit then the code is wrapped inside a function before it is compiled. This means that your code can mostly use faster local lookups rather than global lookups. -- nosy: +sbt ___ Python

[issue18252] timeit makes code run faster?

2013-06-18 Thread Richard Oudkerk
Changes by Richard Oudkerk shibt...@gmail.com: -- stage: committed/rejected - ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue18252 ___ ___ Python

[issue18252] timeit makes code run faster?

2013-06-18 Thread Richard Oudkerk
Changes by Richard Oudkerk shibt...@gmail.com: -- stage: - committed/rejected ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue18252 ___ ___ Python

[issue16507] Patch selectmodule.c to support WSAPoll on Windows

2013-06-20 Thread Richard Oudkerk
Changes by Richard Oudkerk shibt...@gmail.com: -- keywords: +gsoc -patch resolution: - rejected stage: - committed/rejected status: open - closed ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue16507

[issue9122] Problems with multiprocessing, Python embedding and Windows

2013-06-20 Thread Richard Oudkerk
Richard Oudkerk added the comment: We don't do non-security updates on Python 2.6 anymore. As a workaround you might be able to do something like import sys, multiprocessing sys.frozen = True# or multiprocessing.forking.WINEXE = True ... if __name__ == '__main__

[issue6461] multiprocessing: freezing apps on Windows

2013-06-20 Thread Richard Oudkerk
Richard Oudkerk added the comment: I just tried freezing the program from multiprocessing import freeze_support,Manager if __name__ == '__main__': freeze_support() m=Manager() l = m.list([1,2,3]) l.append(4) print(l) print(repr(l)) using cx_Freeze

[issue17018] Inconsistent behaviour of methods waiting for child process

2013-06-20 Thread Richard Oudkerk
Changes by Richard Oudkerk shibt...@gmail.com: -- resolution: - fixed stage: - committed/rejected status: open - closed ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue17018

[issue18122] RuntimeError: not holding the import lock

2013-06-20 Thread Richard Oudkerk
Richard Oudkerk added the comment: See also #9573 and #15914. -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue18122 ___ ___ Python-bugs-list

[issue15198] multiprocessing Pipe send of non-picklable objects doesn't raise error

2013-06-20 Thread Richard Oudkerk
Changes by Richard Oudkerk shibt...@gmail.com: -- resolution: - works for me stage: - committed/rejected status: open - closed ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue15198

[issue18277] Queue is empty right after put from the same process/thread

2013-06-21 Thread Richard Oudkerk
Richard Oudkerk added the comment: This is a very similar issue to #17985. While it may seem counter-intuitive, I don't see how it makes any difference. Another thread/process might remove the item before you can get it. I find it very difficult to imagine a real program where you can safely

[issue18277] Queue is empty right after put from the same process/thread

2013-06-21 Thread Richard Oudkerk
Richard Oudkerk added the comment: Why would you use a multi-process queue to pass messages from one part of the program to another part, in the same process and thread? Why not just use a deque? Is this something you actually did, or are you just trying to come up with a plausible example

[issue17621] Create a lazy import loader mixin

2013-06-22 Thread Richard Oudkerk
Richard Oudkerk added the comment: Apologies for being dense, but how would you actually use such a loader? Would you need to install something in sys.meta_path/sys.path_hooks? Would it make all imports lazy or only imports of specified modules? -- nosy: +sbt

[issue17621] Create a lazy import loader mixin

2013-06-22 Thread Richard Oudkerk
Richard Oudkerk added the comment: Shouldn't the import lock be held to make it threadsafe? -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue17621

[issue18277] Queue is empty right after put from the same process/thread

2013-06-24 Thread Richard Oudkerk
Richard Oudkerk added the comment: I did this to use the same abstraction that was used extensively for other purposes, instead of recreating the same abstraction with a deque as its basis. So you wanted a FIFO queue and preferred the API of Queue to that of deque? Well it will be *much

[issue7292] Multiprocessing Joinable race condition?

2013-06-24 Thread Richard Oudkerk
Richard Oudkerk added the comment: unfinished_tasks is simply used as a counter. It is only accessed while holding self._cond. If you get this error then I think the error text is correct -- your progam calls task_done() to many times. The proposed patch silences the sanity check by making

[issue15818] multiprocessing documentation of Process.exitcode

2013-06-24 Thread Richard Oudkerk
Changes by Richard Oudkerk shibt...@gmail.com: -- resolution: - fixed stage: - committed/rejected status: open - closed ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue15818

[issue17621] Create a lazy import loader mixin

2013-06-24 Thread Richard Oudkerk
Richard Oudkerk added the comment: I was thinking about the line self.__dict__.update(state) overwriting new data with stale data. -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue17621

[issue18277] Queue is empty right after put from the same process/thread

2013-06-24 Thread Richard Oudkerk
Richard Oudkerk added the comment: 1. but should not cause any pratical difficulties -- you have a typo in 'pratical' there. 2. What exactly do you mean by managed queues in the new addition? Woops. Fixed now see 860fc6a2bd21, 347647a1f798. A managed queue is one created like

[issue18277] Queue is empty right after put from the same process/thread

2013-06-24 Thread Richard Oudkerk
Changes by Richard Oudkerk shibt...@gmail.com: -- assignee: - docs@python components: +Documentation -IO, Interpreter Core nosy: +docs@python resolution: - fixed stage: - committed/rejected status: open - closed type: behavior - ___ Python

[issue17985] multiprocessing Queue.qsize() and Queue.empty() with different results

2013-06-24 Thread Richard Oudkerk
Richard Oudkerk added the comment: This is really a documentation issue. The doc fix for #18277 covers this. -- components: +Library (Lib) -Extension Modules resolution: - wont fix stage: - committed/rejected status: open - closed type: - behavior

[issue18329] for line in socket.makefile() speed degradation

2013-06-29 Thread Richard Oudkerk
Richard Oudkerk added the comment: I think in Python 3 makefile() returns a TextIOWrapper object by default. To force the use of binary you need to specfiy the mode: fileobj = ss.makefile(mode='rb') -- nosy: +sbt ___ Python tracker rep

[issue18331] runpy.run_path gives functions with corrupted .__globals__

2013-06-30 Thread Richard Oudkerk
Richard Oudkerk added the comment: When modules are garbage collected the associated globals dict is purged -- see #18214. This means that all values (except __builtins__) are replaced by None. To work around this run_path() apparently returns a *copy* of the globals dict which was created

[issue18332] _posix_listdir may leak FD

2013-06-30 Thread Richard Oudkerk
Richard Oudkerk added the comment: I think this is a duplicate of #17899. -- nosy: +sbt ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue18332

[issue17097] multiprocessing BaseManager serve_client() does not check EINTR on recv

2013-07-01 Thread Richard Oudkerk
Changes by Richard Oudkerk shibt...@gmail.com: -- resolution: - fixed stage: - committed/rejected status: open - closed ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue17097

[issue18344] _bufferedreader_read_all() may leak reference to data

2013-07-02 Thread Richard Oudkerk
Richard Oudkerk added the comment: Patch attached. -- keywords: +patch Added file: http://bugs.python.org/file30748/buf-readall.patch ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue18344

[issue17273] Pool methods can only be used by parent process.

2013-07-02 Thread Richard Oudkerk
Changes by Richard Oudkerk shibt...@gmail.com: -- resolution: - fixed stage: - committed/rejected status: open - closed title: multiprocessing.pool.Pool task/worker handlers are not fork safe - Pool methods can only be used by parent process. type: behavior - versions: +Python 2.7

[issue14206] multiprocessing.Queue documentation is lacking important details

2013-07-02 Thread Richard Oudkerk
Changes by Richard Oudkerk shibt...@gmail.com: -- status: open - closed ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue14206 ___ ___ Python-bugs

[issue14206] multiprocessing.Queue documentation is lacking important details

2013-07-02 Thread Richard Oudkerk
Changes by Richard Oudkerk shibt...@gmail.com: -- resolution: - fixed stage: - committed/rejected ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue14206

[issue17261] multiprocessing.manager BaseManager cannot return proxies from proxies remotely (when listening on '')

2013-07-02 Thread Richard Oudkerk
Changes by Richard Oudkerk shibt...@gmail.com: -- resolution: - fixed stage: - committed/rejected status: open - closed versions: +Python 3.3, Python 3.4 ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue17261

[issue2286] Stack overflow exception caused by test_marshal on Windows x64

2013-07-02 Thread Richard Oudkerk
Richard Oudkerk added the comment: Reopening because I think this is again a problem for Win64 and 3.x. The Win64 buildbots always seem to crash on test_marshal (and I do too). It appears to be BugsTestCase.test_loads_2x_code() which crashes, which is virtually the same

[issue2286] Stack overflow exception caused by test_marshal on Windows x64

2013-07-02 Thread Richard Oudkerk
Richard Oudkerk added the comment: Closing because this is caused by #17206 and is already discussed there. -- status: open - closed ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue2286

[issue7292] Multiprocessing Joinable race condition?

2013-07-03 Thread Richard Oudkerk
Changes by Richard Oudkerk shibt...@gmail.com: -- resolution: - works for me stage: test needed - committed/rejected status: open - closed ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue7292

[issue18329] for line in socket.makefile() speed degradation

2013-07-04 Thread Richard Oudkerk
Richard Oudkerk added the comment: I think I know what's going on here. For socket IO readline() uses a readahead buffer size of 1. Why is that? I think that makefile(mode='rb') and fdopen() both create BufferedReader objects with the same buffer size. It looks to me like

[issue18329] for line in socket.makefile() speed degradation

2013-07-04 Thread Richard Oudkerk
Richard Oudkerk added the comment: Using while True: if not fileobj.read(8192): break instead of for line in fileobj: pass results in higher throughput, but a similar slowdown with makefile(). So this is not a problem specific

[issue18329] for line in socket.makefile() speed degradation

2013-07-04 Thread Richard Oudkerk
Richard Oudkerk added the comment: The only real reason for implementing SocketIO in pure Python is because read() and write() do not work on Windows with sockets. (I think there are also a few complications involving SSL sockets and the close() method.) On Windows I have implemented a file

[issue18329] for line in socket.makefile() speed degradation

2013-07-04 Thread Richard Oudkerk
Richard Oudkerk added the comment: Ah. I had not thought of socket timeouts. -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue18329

[issue18329] for line in socket.makefile() speed degradation

2013-07-04 Thread Richard Oudkerk
Richard Oudkerk added the comment: I find that by adding the lines fileobj.raw.readinto = ss.recv_into fileobj.raw.read = ss.recv the speed with makefile() is about 30% slower than with fdopen(). -- ___ Python tracker rep

[issue6642] returning after forking a child thread doesn't call Py_Finalize

2013-07-05 Thread Richard Oudkerk
Richard Oudkerk added the comment: Shouldn't the child process be terminating using os._exit()? -- nosy: +sbt ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue6642

[issue18382] multiprocessing's overlapped PipeConnection issues on Windows 8

2013-07-06 Thread Richard Oudkerk
Richard Oudkerk added the comment: Does that test always fail? -- nosy: +sbt ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue18382 ___ ___ Python

[issue4708] os.pipe should return inheritable descriptors (Windows)

2013-07-09 Thread Richard Oudkerk
Richard Oudkerk added the comment: - would improve POSIX compatibility, it mimics what os.pipe() does on those OS I disagree. On Windows fds can only be inherited if you start processes using the spanwn*() family of functions. If you start them using CreateProcess() then the underlying

[issue4708] os.pipe should return inheritable descriptors (Windows)

2013-07-09 Thread Richard Oudkerk
Richard Oudkerk added the comment: Oops. I confused os.popen() with os.spawn*(). os.spawnv() IS still implemented using spawnv() in Python 3. -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue4708

[issue18455] Multiprocessing connection SocketClient retries connection on socket

2013-07-14 Thread Richard Oudkerk
Changes by Richard Oudkerk shibt...@gmail.com: -- nosy: +sbt ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue18455 ___ ___ Python-bugs-list mailing

[issue18344] _bufferedreader_read_all() may leak reference to data

2013-07-15 Thread Richard Oudkerk
Changes by Richard Oudkerk shibt...@gmail.com: -- status: open - closed ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue18344 ___ ___ Python-bugs

[issue18344] _bufferedreader_read_all() may leak reference to data

2013-07-15 Thread Richard Oudkerk
Changes by Richard Oudkerk shibt...@gmail.com: -- resolution: - fixed stage: needs patch - committed/rejected ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue18344

[issue18455] Multiprocessing connection SocketClient retries connection on socket

2013-07-15 Thread Richard Oudkerk
Richard Oudkerk added the comment: Thanks for the report. This should be fixed now in 2.7. (3.1 and 3.2 only get security fixes.) -- resolution: - fixed stage: - committed/rejected status: open - closed ___ Python tracker rep...@bugs.python.org

[issue17778] Fix test discovery for test_multiprocessing.py

2013-07-16 Thread Richard Oudkerk
Richard Oudkerk added the comment: Thanks for the patches! -- resolution: - fixed stage: patch review - committed/rejected status: open - closed ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue17778

[issue15758] 500x speed up for Popen.communicate() on Windows

2012-08-21 Thread Richard Oudkerk
Richard Oudkerk added the comment: RawIOBase.readall() does the sensible thing already. Maybe FileIO should be allowed to inherit it. The alternative patch (which probably only works for raw unbuffered case) diff -r ca54c27a9045 Lib/subprocess.py --- a/Lib/subprocess.py Tue Aug 21 14:54:22

[issue15758] 500x speed up for Popen.communicate() on Windows

2012-08-21 Thread Richard Oudkerk
Richard Oudkerk added the comment: FileIO.readall() already has an overallocation mechanism which should yield linear complexity. Perhaps it needs to be tweaked a bit? (look at new_buffersize in Modules/_io/fileio.c) I think it needs a bit more than a tweak;-) Looks like it increases

[issue15758] 500x speed up for Popen.communicate() on Windows

2012-08-22 Thread Richard Oudkerk
Richard Oudkerk added the comment: In each loop before calling read() the buffer size is recalculated based on the amount of space used, causing a realloc *regardless* of how much empty space is left in the buffer. And each read is only producing a smallish chunk (5120 bytes). So assuming

[issue15758] 500x speed up for Popen.communicate() on Windows

2012-08-22 Thread Richard Oudkerk
Richard Oudkerk added the comment: The attached patch (readall-resize.patch) makes the resizes only happen when the buffer is full. It produces amount = 1 MB; time taken = 0.02 secs; rate = 64.10 MB/s amount = 2 MB; time taken = 0.03 secs; rate = 64.10 MB/s amount = 4 MB; time taken = 0.06

[issue15758] 500x speed up for Popen.communicate() on Windows

2012-08-22 Thread Richard Oudkerk
Richard Oudkerk added the comment: Alternative patch (readall-chunks.patch) which delegates to RawIOBase.readall() if the file cannot be stat-ed or appears to have size zero. amount = 1 MB; time taken = 0.02 secs; rate = 64.10 MB/s amount = 2 MB; time taken = 0.02 secs; rate = 128.21 MB/s

[issue15758] 500x speed up for Popen.communicate() on Windows

2012-08-22 Thread Richard Oudkerk
Richard Oudkerk added the comment: It seems we could do both (fix the resizing logic, and fallback on chunks if the size is unknown). Combined patch attached. -- Added file: http://bugs.python.org/file26963/readall-combined.patch ___ Python

[issue15758] 500x speed up for Popen.communicate() on Windows

2012-08-23 Thread Richard Oudkerk
Changes by Richard Oudkerk shibt...@gmail.com: Removed file: http://bugs.python.org/file26953/popen_communicate.patch ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue15758

[issue15758] 500x speed up for Popen.communicate() on Windows

2012-08-23 Thread Richard Oudkerk
Changes by Richard Oudkerk shibt...@gmail.com: Removed file: http://bugs.python.org/file26960/readall-chunks.patch ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue15758

[issue15758] 500x speed up for Popen.communicate() on Windows

2012-08-23 Thread Richard Oudkerk
Changes by Richard Oudkerk shibt...@gmail.com: Removed file: http://bugs.python.org/file26959/readall-resize.patch ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue15758

[issue15758] 500x speed up for Popen.communicate() on Windows

2012-08-23 Thread Richard Oudkerk
Changes by Richard Oudkerk shibt...@gmail.com: Removed file: http://bugs.python.org/file26963/readall-combined.patch ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue15758

[issue15758] FileIO.readall() has worst case O(n^2) complexity

2012-08-23 Thread Richard Oudkerk
Richard Oudkerk added the comment: Here is the patch (with the old ones removed). Note that the old code mishandled the case where _PyBytes_Resize() failed by assuming that the old bytes object would still be valid. I have assumed that stream psuedo-files will never claim to have a size

[issue15758] FileIO.readall() has worst case O(n^2) complexity

2012-08-24 Thread Richard Oudkerk
Richard Oudkerk added the comment: After playing with the patch on Linux it seems that Linux much prefers the realloc() scheme to the list-of-chunks scheme. This new patch only does list-of-chunks on Windows. -- Added file: http://bugs.python.org/file26985/readall-combined.patch

[issue15758] FileIO.readall() has worst case O(n^2) complexity

2012-08-24 Thread Richard Oudkerk
Richard Oudkerk added the comment: Attached is an alternative benchmark program which does not use subprocess. -- Added file: http://bugs.python.org/file26986/readall-benchmark.py ___ Python tracker rep...@bugs.python.org http://bugs.python.org

[issue15758] FileIO.readall() has worst case O(n^2) complexity

2012-08-24 Thread Richard Oudkerk
Changes by Richard Oudkerk shibt...@gmail.com: Removed file: http://bugs.python.org/file26952/push-thru-cat.py ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue15758

[issue15758] FileIO.readall() has worst case O(n^2) complexity

2012-08-24 Thread Richard Oudkerk
Changes by Richard Oudkerk shibt...@gmail.com: Removed file: http://bugs.python.org/file26970/readall-combined.patch ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue15758

[issue15758] FileIO.readall() has worst case O(n^2) complexity

2012-08-24 Thread Richard Oudkerk
Richard Oudkerk added the comment: What about the method call overhead in RawIO.readall(), and the different progression of buffer sizes? (the realloc scheme uses larger and larger read() sizes, while RawIO.readall() uses a constant read() size). For this benchmark the call overhead does

[issue15784] OSError.__str__() should distinguish between errno and winerror

2012-08-25 Thread Richard Oudkerk
New submission from Richard Oudkerk: Since WindowsError became an alias of OSError, the error number shown in the stringification of an OSError err can either be a windows error code (err.winerror) or a posix style error number (err.errno), with no way to tell which. For instance

[issue15784] OSError.__str__() should distinguish between errno and winerror

2012-08-25 Thread Richard Oudkerk
Changes by Richard Oudkerk shibt...@gmail.com: Added file: http://bugs.python.org/file27002/winerror.patch ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue15784

[issue15784] OSError.__str__() should distinguish between errno and winerror

2012-08-25 Thread Richard Oudkerk
Changes by Richard Oudkerk shibt...@gmail.com: Removed file: http://bugs.python.org/file27001/winerror.patch ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue15784

[issue15784] OSError.__str__() should distinguish between errno and winerror

2012-08-27 Thread Richard Oudkerk
Richard Oudkerk added the comment: Well, Error and Errno are rather hard to distinguish Embarrassingly, I did not even notice the was a difference. -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue15784

[issue15784] OSError.__str__() should distinguish between errno and winerror

2012-08-29 Thread Richard Oudkerk
Richard Oudkerk added the comment: The changeset is 2e587b9bae35. Georg, could you copy it to your release branch please. -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue15784

[issue15812] inspect.getframeinfo() cannot show first line

2012-08-29 Thread Richard Oudkerk
New submission from Richard Oudkerk: When inspect.getframeinfo() tries to collect lines of context it never shows the first line (unless context is as big as the number of lines in the file). The relevant code is start = lineno - 1 - context//2 try: lines, lnum

[issue15818] multiprocessing documentation of Process.exitcode

2012-08-30 Thread Richard Oudkerk
Changes by Richard Oudkerk shibt...@gmail.com: -- nosy: +sbt ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue15818 ___ ___ Python-bugs-list mailing

[issue15798] subprocess.Popen() fails if 0, 1 or 2 descriptor is closed

2012-08-30 Thread Richard Oudkerk
Richard Oudkerk added the comment: Would it simplify matters to stop treating 0,1,2 specially and just add them to pass_fds instead? -- nosy: +sbt ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue15798

[issue15819] Unable to build Python out-of-tree when source tree is readonly.

2012-08-30 Thread Richard Oudkerk
Richard Oudkerk added the comment: I tried building from out-of-tree with a read-only srcdir, but I found two other files which the build process tries to create in the source directory: $(srcdir)/Objects/typeslots.inc $(srcdir)/Lib/_sysconfigdata.py -- nosy: +sbt

[issue15819] Unable to build Python out-of-tree when source tree is readonly.

2012-08-31 Thread Richard Oudkerk
Richard Oudkerk added the comment: Richard: what was your use case? Building on the main host and a VM without having to commit and synchronize temporary changes. (The VM has read-only access to the host's repositories). What steps did you take that resulted in getting typeslots.inc

[issue15819] Unable to build Python out-of-tree when source tree is readonly.

2012-08-31 Thread Richard Oudkerk
Richard Oudkerk added the comment: Why is that? python will work just fine if it can't write pyc files. When I hacked around the _sysconfigdata.py issue, running the created python produced Fatal Python error: Py_Initialize: Unable to get the locale encoding Traceback (most recent call last

[issue15819] Unable to build Python out-of-tree when source tree is readonly.

2012-08-31 Thread Richard Oudkerk
Richard Oudkerk added the comment: It looks like the code which writes the byte-compiled codes checks for and ignores PermissionError (EACCES, EPERM) and FileExistsError (EEXIST). However, for me it is EIO which is raised. -- ___ Python tracker rep

[issue15833] most failures to write byte-compiled file no longer suppressed

2012-08-31 Thread Richard Oudkerk
New submission from Richard Oudkerk: As discussed in http://bugs.python.org/issue15819 trying to run python built outside a read-only source directory fails for me because OSError(EIO, ...) is raised when importlib tries to write the byte compiled file. (I built python in a Linux VM

[issue15819] Unable to build Python out-of-tree when source tree is readonly.

2012-08-31 Thread Richard Oudkerk
Richard Oudkerk added the comment: I have opened a new issue: http://bugs.python.org/issue15833 It is a regression because in Python 3.2 all failures to open the file for writing were supressed. But as I said: I'd also be fine with declaring this VM software unsupported. If this work

[issue15298] _sysconfigdata is generated in srcdir, not builddir

2012-09-05 Thread Richard Oudkerk
Richard Oudkerk added the comment: If sysconfig._generate_posix_vars() creates the build directory and pybuilddir.txt (instead of setup.py) then it could write _sysconfigdata.py in the correct place. Then setup.py would not have to mess with its own sys.path. One issue with having

[issue15298] _sysconfigdata is generated in srcdir, not builddir

2012-09-05 Thread Richard Oudkerk
Richard Oudkerk added the comment: Alternative patch. -- Added file: http://bugs.python.org/file27122/alt_sysconfigdata.patch ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue15298

[issue15298] _sysconfigdata is generated in srcdir, not builddir

2012-09-05 Thread Richard Oudkerk
Richard Oudkerk added the comment: builddir should have added +(-pydebug if hasattr(sys, gettotalrefcount) else ) Oops, yes. the installation installs this to the lib-dynload directory, which maybe is not desired. The lines + -rm $(DESTDIR)$(DESTSHARED)/_sysconfigdata.py

[issue15298] _sysconfigdata is generated in srcdir, not builddir

2012-09-05 Thread Richard Oudkerk
Richard Oudkerk added the comment: Updated patch. -- Added file: http://bugs.python.org/file27125/alt_sysconfigdata.patch ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue15298

[issue15298] _sysconfigdata is generated in srcdir, not builddir

2012-09-05 Thread Richard Oudkerk
Changes by Richard Oudkerk shibt...@gmail.com: Removed file: http://bugs.python.org/file27125/alt_sysconfigdata.patch ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue15298

[issue15298] _sysconfigdata is generated in srcdir, not builddir

2012-09-05 Thread Richard Oudkerk
Richard Oudkerk added the comment: Try again. -- Added file: http://bugs.python.org/file27126/alt_sysconfigdata.patch ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue15298

[issue15298] _sysconfigdata is generated in srcdir, not builddir

2012-09-05 Thread Richard Oudkerk
Changes by Richard Oudkerk shibt...@gmail.com: Added file: http://bugs.python.org/file27127/alt_sysconfigdata.patch ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue15298

[issue15298] _sysconfigdata is generated in srcdir, not builddir

2012-09-05 Thread Richard Oudkerk
Changes by Richard Oudkerk shibt...@gmail.com: Removed file: http://bugs.python.org/file27126/alt_sysconfigdata.patch ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue15298

[issue15298] _sysconfigdata is generated in srcdir, not builddir

2012-09-05 Thread Richard Oudkerk
Changes by Richard Oudkerk shibt...@gmail.com: Removed file: http://bugs.python.org/file27122/alt_sysconfigdata.patch ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue15298

[issue15881] multiprocessing 'NoneType' object is not callable

2012-09-07 Thread Richard Oudkerk
Changes by Richard Oudkerk shibt...@gmail.com: -- nosy: +sbt ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue15881 ___ ___ Python-bugs-list mailing

[issue15901] multiprocessing sharedctypes Array don't accept strings

2012-09-10 Thread Richard Oudkerk
Richard Oudkerk added the comment: The documentation needs updating for Python 3 so that a byte string is used. So the line becomes s = Array('c', b'hello world', lock=lock) -- nosy: +sbt ___ Python tracker rep...@bugs.python.org http

[issue15901] multiprocessing sharedctypes Array don't accept strings

2012-09-10 Thread Richard Oudkerk
Changes by Richard Oudkerk shibt...@gmail.com: -- resolution: - fixed stage: - committed/rejected status: open - closed ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue15901

[issue15903] Make rawiobase_read() read directly to bytes object

2012-09-10 Thread Richard Oudkerk
New submission from Richard Oudkerk: Currently rawiobase_read() reads to a bytearray object and then copies the data to a bytes object. There is a TODO comment saying that the bytes object should be created directly. The attached patch does that. -- files: iobase_read.patch keywords

[issue15881] multiprocessing 'NoneType' object is not callable

2012-09-10 Thread Richard Oudkerk
Richard Oudkerk added the comment: I see the same error on Windows (when pressing ^C), but on Linux I get Error in sys.exitfunc: Traceback (most recent call last): File /usr/lib/python2.7/atexit.py, line 28, in _run_exitfuncs import traceback File /usr/lib/python2.7/traceback.py, line 3

[issue15904] file,close() can fail assert on Windows in 2.7

2012-09-10 Thread Richard Oudkerk
New submission from Richard Oudkerk: With Python 2.7 on Windows the following crashes with an assertion: import os [43042 refs] f = open(foobar, wb) [43048 refs] os.close(f.fileno()) [43048 refs] f.close() Failed assertion A box pops up with Program: C

[issue15904] file,close() can fail assert on Windows in 2.7

2012-09-10 Thread Richard Oudkerk
Richard Oudkerk added the comment: If buffering is off then they all fail the assertion except isatty(). -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue15904

[issue15881] multiprocessing 'NoneType' object is not callable

2012-09-10 Thread Richard Oudkerk
Richard Oudkerk added the comment: I suspect the problem is caused by nose's isolate plugin. With this enabled, a copy of sys.modules is saved before each test and then restored after the test. This causes garbage collection of newly imported modules. The destructor for the module type

[issue15881] multiprocessing 'NoneType' object is not callable

2012-09-10 Thread Richard Oudkerk
Richard Oudkerk added the comment: Actually, I am not so sure it is the isolate plugin. But I do think that sys.modules is being manipulated somewhere before shutdown. -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue15881

<    1   2   3   4   5   6   7   8   >