[issue9998] ctypes find_library should search LD_LIBRARY_PATH on linux

2011-07-25 Thread Jonathan Niehof

Jonathan Niehof  added the comment:

Yaroslav: does the patch cause problems, or the original issue? If the former, 
could you be specific so I can try and fix it?

--

___
Python tracker 
<http://bugs.python.org/issue9998>
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue9993] shutil.move fails on symlink source

2011-08-22 Thread Jonathan Niehof

Jonathan Niehof  added the comment:

Éric, here's a quick docs-only patch against current default...does this do the 
job?

--
Added file: http://bugs.python.org/file23002/shutil_move_doc.patch

___
Python tracker 
<http://bugs.python.org/issue9993>
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue9993] shutil.move fails on symlink source

2011-08-23 Thread Jonathan Niehof

Jonathan Niehof  added the comment:

Éric: I think copying a relative symlink should also be relative, and that's 
the behaviour of this patch. That was the use case that tripped me up with the 
original behaviour of shutil.move: a relative symlink which was dangling in its 
original location, but not once moved. (This was, believe it or not, 
intentional design)

This is also the behaviour when src and dst are on the same filesystem. 
Basically my intention was to remove the distinction between "same filesystem" 
and "different filesystem."

--

___
Python tracker 
<http://bugs.python.org/issue9993>
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue9991] xmlrpc client ssl check faulty

2010-09-29 Thread Jonathan Niehof

New submission from Jonathan Niehof :

This has been reported before (#6494, #7987) and closed as "You need to build 
Python with SSL support." However, this error is raised even if ssl support is 
included.

The SSL check in xmlrpc.client for Python 3.1 is:
if not hasattr(socket, "ssl")
but ssl was removed from socket and into its own class for Py3k. So one 
workaround, provided ssl support is available:

import socket
if not hasattr(socket, 'ssl')
socket.ssl = None
import xmlrpc.client

at which point everything works fine.

The attached patch fixes the bug, checking for ssl support based on the 
existence of http.client.HTTPSConnection, which is similar to the check in 
Python 2.7.

--
components: Library (Lib)
files: xmlrpc_client_ssl_check.patch
keywords: patch
messages: 117667
nosy: jniehof
priority: normal
severity: normal
status: open
title: xmlrpc client ssl check faulty
type: crash
versions: Python 3.1, Python 3.2
Added file: http://bugs.python.org/file19061/xmlrpc_client_ssl_check.patch

___
Python tracker 
<http://bugs.python.org/issue9991>
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue9993] shutil.move fails on symlink source

2010-09-29 Thread Jonathan Niehof

New submission from Jonathan Niehof :

shutil.move does not behave as I expect when moving a symlink across 
filesystems. (This is when src itself is a symlink, not when it is a directory 
tree including symlinks.)

-If src is a symlink to file, rather than moving the symlink, it copies the 
contents of the file
-If src is a symlink to a directory, rather than moving the symlink, it copies 
the contents of the directory to a new directory
-If src is a dangling symlink, it errors out

Attached patch against the py3k branch adds tests for these cases and adds the 
expected behaviour, which is to recreate the symlink.

(I have encountered this on 2.6 - current SVN; it is probably in 2.5 as well 
but I have not confirmed.)

--
components: Library (Lib)
files: shutil_move_symlinks.patch
keywords: patch
messages: 117673
nosy: jniehof
priority: normal
severity: normal
status: open
title: shutil.move fails on symlink source
type: behavior
versions: Python 2.6, Python 2.7, Python 3.1, Python 3.2
Added file: http://bugs.python.org/file19063/shutil_move_symlinks.patch

___
Python tracker 
<http://bugs.python.org/issue9993>
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue9998] find_library should search LD_LIBRARY_PATH on linux

2010-09-30 Thread Jonathan Niehof

New submission from Jonathan Niehof :

It's come up on occasion (#2936, 
http://osdir.com/ml/python.ctypes/2008-05/msg00046.html) that ctypes 
find_library doesn't search LD_LIBRARY_PATH for libraries, which is different 
behaviour from the runtime linker. The attached patch adds this search.

Unfortunately I can't conceive of a reasonable unit test for this (compiling a 
shared library in setUp seems a bit overkill.)

--
assignee: theller
components: ctypes
files: ctypes_ld_lib_path.patch
keywords: patch
messages: 117738
nosy: jniehof, theller
priority: normal
severity: normal
status: open
title: find_library should search LD_LIBRARY_PATH on linux
type: feature request
versions: Python 2.7, Python 3.1, Python 3.2
Added file: http://bugs.python.org/file19068/ctypes_ld_lib_path.patch

___
Python tracker 
<http://bugs.python.org/issue9998>
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue9999] test_shutil cross-file-system tests are fragile (may not test what they pruport to test)

2010-09-30 Thread Jonathan Niehof

Jonathan Niehof  added the comment:

Might it make sense to skip-decorate those tests which require 
cross-filesystem? Put a test above the TestMove definition which compares 
tempfile.gettempdir() and os.path.dirname(__file__).

I don't know of an out-of-the-box function to see if two paths are on the same 
filesystem; I suppose one approach would be to walk up the directory tree of 
each, checking ismount. (Looks like somebody's tried it: 
http://stackoverflow.com/questions/1138383/python-get-mount-point-on-windows-or-linux)

--
nosy: +jniehof

___
Python tracker 
<http://bugs.python.org/issue>
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue9991] xmlrpc client ssl check faulty

2010-10-05 Thread Jonathan Niehof

Changes by Jonathan Niehof :


--
nosy: +Jelly.Chen, lister171254

___
Python tracker 
<http://bugs.python.org/issue9991>
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com