[issue14835] plistlib: output empty elements correctly

2012-05-25 Thread Hynek Schlawack
Hynek Schlawack added the comment: Sidney, would you mind adding a regression test for both cases? Ned, Ronald what's your take on this? -- ___ Python tracker <http://bugs.python.org/is

[issue14814] Implement PEP 3144 (the ipaddress module)

2012-05-26 Thread Hynek Schlawack
Hynek Schlawack added the comment: One last wish: could we curb the copyright header a bit? I don't know the exact policy on that but as other modules don't have that I presume we could do without/with a shorter one. If we have one, I'd rather add something like "b

[issue14907] SSL module cannot handle unicode filenames

2012-05-26 Thread Hynek Schlawack
Hynek Schlawack added the comment: So are we going to add something to the docs or just close as rejected? -- ___ Python tracker <http://bugs.python.org/issue14

[issue14907] SSL module cannot handle unicode filenames

2012-05-26 Thread Hynek Schlawack
Hynek Schlawack added the comment: I'd just add some general catch-all phrase at the top that all paths are expected to be encoded strings. -- ___ Python tracker <http://bugs.python.org/is

[issue14932] Python 3.3.0a3 build fails on MacOS 10.7 with XCode 4.3.2

2012-05-28 Thread Hynek Schlawack
Hynek Schlawack added the comment: Hello Thomas, I presume your gcc is Apple's llvm-gcc (gcc --version output starts with "i686-apple-darwin11-llvm-gcc-4.2"), which is unfortunately a known to miscompile Python 3.3. If you want to compile the latest Python 3.3 on OS X, use c

[issue14932] Python 3.3.0a3 build fails on MacOS 10.7 with XCode 4.3.2

2012-05-28 Thread Hynek Schlawack
Hynek Schlawack added the comment: Have a look at issue13241 which is dedicated to this problem, especially at msg160081. -- ___ Python tracker <http://bugs.python.org/issue14

[issue14835] plistlib: output empty elements correctly

2012-05-29 Thread Hynek Schlawack
Hynek Schlawack added the comment: The patch LGTM, but Pam seemed to have problems to find your account (http://mail.python.org/pipermail/python-committers/2012-May/002037.html) – did you get the reply and followed up on that? -- ___ Python

[issue14835] plistlib: output empty elements correctly

2012-05-29 Thread Hynek Schlawack
Hynek Schlawack added the comment: Thank you for your contribution! But please help Pam to work out your contribution form. -- resolution: -> fixed stage: patch review -> committed/rejected status: open -> closed ___ Python track

[issue10053] Don’t close fd when FileIO.__init__ fails

2012-05-29 Thread Hynek Schlawack
Hynek Schlawack added the comment: I think this issue is still valid. However, I’d favor the attached (simpler) patch that keeps track whether self->fd is our own (i.e. a result of an open() operation) or from outside. A couple of notes: - I'm not sure why your test skippe

[issue14814] Implement PEP 3144 (the ipaddress module)

2012-05-31 Thread Hynek Schlawack
Hynek Schlawack added the comment: It's funny how raising the test coverage _always_ uncovers lurking bugs in obscure branches. :) Patch attached, let me know if I got it wrong – would commit otherwise. A few quick side-note: does the __version__ variable make sense in s

[issue14974] rename packaging.pypi to packaging.index

2012-05-31 Thread Hynek Schlawack
Hynek Schlawack added the comment: While I can see your point, I think that "index" is way too generic. I also think that the pypi term is overloaded with both meanings. -- nosy: +hynek ___ Python tracker <http://bugs.python.o

[issue14972] listcomp with nested classes

2012-05-31 Thread Hynek Schlawack
Changes by Hynek Schlawack : -- nosy: +hynek ___ Python tracker <http://bugs.python.org/issue14972> ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue14981] 3.3.0a4 compilation fails von MacOS Lion /10.7.4

2012-06-01 Thread Hynek Schlawack
Hynek Schlawack added the comment: Dupe of #13241. Apple's llvm-gcc is broken, please use clang instead (CC=clang ./configure). -- nosy: +hynek resolution: -> duplicate stage: -> committed/rejected status: open -> closed superseder: -> llvm-gcc-4.2 miscompiles Pyt

[issue13241] llvm-gcc-4.2 miscompiles Python (XCode 4.1 on Mac OS 10.7)

2012-06-01 Thread Hynek Schlawack
Hynek Schlawack added the comment: Ned, any progress/problems? I've closed two dupes already in the last few days and we're still in the alphas. We really should get this fixed before beta1 or the tracker will be flooded. Let me know if you need

[issue14986] print() fails on latin1 characters on OSX

2012-06-02 Thread Hynek Schlawack
Hynek Schlawack added the comment: '\u030a' can’t be latin1 as 0x030a = 778 which is waaay beyond 255. :) That's gonna be utf-8 and indeed that maps to " ̊". My best guess is that your LC_CTYPE is set to Mac Roman. You can check it using "import os;os.environ.

[issue14985] os.path.isfile and os.path.isdir inconsistent on OSX Lion

2012-06-02 Thread Hynek Schlawack
Hynek Schlawack added the comment: I think your problem is a different one: os.listdir() doesn't return full paths and os.path.isfile()/isdir() return False if the supplied path doesn't exist. For example if you have this directory structure: foo/ foo/bar/ foo/bar/baz Calling

[issue14814] Implement PEP 3144 (the ipaddress module)

2012-06-02 Thread Hynek Schlawack
Hynek Schlawack added the comment: As discussed on IRC, please: - add a link to the tutorial - add some typical use cases to the header of the api - change the name of the tutorial from "Howto" to "HOWTO" or a more descriptive title that doesn't conta

[issue14986] print() fails on latin1 characters on OSX

2012-06-02 Thread Hynek Schlawack
Hynek Schlawack added the comment: Glad we could help. I suspected it was running under "special circumstances". -- resolution: -> invalid stage: -> committed/rejected status: open -> closed ___ Python tracker <http://bugs

[issue15001] segmentation fault with del sys.module['__main__']

2012-06-04 Thread Hynek Schlawack
Changes by Hynek Schlawack : -- nosy: +hynek ___ Python tracker <http://bugs.python.org/issue15001> ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue14814] Implement PEP 3144 (the ipaddress module)

2012-06-04 Thread Hynek Schlawack
Hynek Schlawack added the comment: Dear friends of ip addresses, I made something: refactor dup code, minor janitoring, bump coverage - remove duplicate netmask/hostmask code (it was identical in ipv4address & interface) - make two ifs more pythonic - Refactor and fix packed property

[issue14814] Implement PEP 3144 (the ipaddress module)

2012-06-05 Thread Hynek Schlawack
Hynek Schlawack added the comment: So one more issue from me: as indicated, the constructor using packed of IPv6Networks is broken (wrong indent). The question is whether we want to be able to construct using packed at all. Also the strict check doesn't make any sense because the net ma

[issue15034] tutorial should use best practices in user defined execeptions section

2012-06-08 Thread Hynek Schlawack
Changes by Hynek Schlawack : -- nosy: +hynek ___ Python tracker <http://bugs.python.org/issue15034> ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue10053] Don’t close fd when FileIO.__init__ fails

2012-06-09 Thread Hynek Schlawack
Hynek Schlawack added the comment: Anyone? -- ___ Python tracker <http://bugs.python.org/issue10053> ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue4489] shutil.rmtree is vulnerable to a symlink attack

2012-06-09 Thread Hynek Schlawack
Hynek Schlawack added the comment: Martin, are you still committed to this? I still think code duplication is bad (especially for security related code) but I’d be willing to write a fwalk-less version so it doesn’t look like I’m just defending my code here

[issue4489] shutil.rmtree is vulnerable to a symlink attack

2012-06-11 Thread Hynek Schlawack
Hynek Schlawack added the comment: Fair enough, I'm not going to question your obviously superior judgement here. :) However, your patch currently breaks the test suite on any platform that uses the fallback rmtree: You forgot the ignore_errors=False in the _rmtree_unsafe signature

[issue15061] hmac.secure_compare() leaks information of length of strings

2012-06-14 Thread Hynek Schlawack
Hynek Schlawack added the comment: We should. Adding secure functions that aren't really secure is something we should rather avoid. :) Christian, are you willing to do that? -- components: +Library (Lib) -IO nosy: +hynek stage: patch review -> needs patch type: behavior -&g

[issue15061] hmac.secure_compare() leaks information about length of strings

2012-06-14 Thread Hynek Schlawack
Hynek Schlawack added the comment: I don’t want to be the killjoy but I find it highly questionable to add a function that is advertised as "secure" while we can't fully grok the complexities at play. If we can't produce a provable secure one, we should scrub the func

[issue14955] hmac.secure_compare() is not time-independent for unicode strings

2012-06-14 Thread Hynek Schlawack
Changes by Hynek Schlawack : -- nosy: +hynek ___ Python tracker <http://bugs.python.org/issue14955> ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue14532] multiprocessing module performs a time-dependent hmac comparison

2012-06-14 Thread Hynek Schlawack
Changes by Hynek Schlawack : -- nosy: +hynek ___ Python tracker <http://bugs.python.org/issue14532> ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue15061] hmac.secure_compare() leaks information about length of strings

2012-06-14 Thread Hynek Schlawack
Hynek Schlawack added the comment: > "Secure" vs "not secure" is not a binary state - it's about making attacks > progressively more difficult. Something that is secure against a casual > script kiddie scatter gunning attacks on various sites with an autom

[issue15061] hmac.secure_compare() leaks information about length of strings

2012-06-15 Thread Hynek Schlawack
Hynek Schlawack added the comment: >> Why not write a C function which can be more secure than Python code? > For Unicode strings, it's impossible to write a time-independent > comparison function even in C Really? Some comments sounded different. That's too bad but als

[issue15061] hmac.secure_compare() leaks information about length of strings

2012-06-15 Thread Hynek Schlawack
Hynek Schlawack added the comment: >> and any other place that compares passwords, tokens, … > > No no no. Any sensible place to compare passwords would use some > sort of one-way function (password hash) before the comparison, > so that someone breaking into the machine

[issue15084] Add option to os.makefile to not raise an exception for existing directories

2012-06-16 Thread Hynek Schlawack
Hynek Schlawack added the comment: +1. Raymond, is there a reason you put that for 3.4? I'd try to get it in before beta1 next week, it's trivial enough. Regarding the name: os.makedirs() uses exist_ok, we shouldn't invent new ones. -- assignee: ->

[issue15084] Add option to os.mkdir to not raise an exception for existing directories

2012-06-16 Thread Hynek Schlawack
Changes by Hynek Schlawack : -- title: Add option to os.makefile to not raise an exception for existing directories -> Add option to os.mkdir to not raise an exception for existing directories ___ Python tracker <http://bugs.python.org/issu

[issue15084] Add option to os.mkdir to not raise an exception for existing directories

2012-06-16 Thread Hynek Schlawack
Hynek Schlawack added the comment: I looked into the code. Assuming it should be added, we're facing the fact that os.mkdir() is C code ATM and the handling of the error would require to implement it for NT and Unix separately. Therefore it would make sense to add a Python os.mkdir()

[issue13498] os.makedirs exist_ok documentation is incorrect, as is some of the behavior

2012-06-16 Thread Hynek Schlawack
Changes by Hynek Schlawack : -- nosy: +hynek ___ Python tracker <http://bugs.python.org/issue13498> ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue4489] shutil.rmtree is vulnerable to a symlink attack

2012-06-18 Thread Hynek Schlawack
Hynek Schlawack added the comment: Martin, what exactly is the intended proceeding now? Are you going to fix your patch and tests as soon as you have time or was that just a PoC and expect me/us to bring it into shape? (<- troll-free question, I have no idea what to do next here and wo

[issue15100] Race conditions in shutil.copy, shutil.copy2 and shutil.copyfile

2012-06-18 Thread Hynek Schlawack
Changes by Hynek Schlawack : -- nosy: +hynek ___ Python tracker <http://bugs.python.org/issue15100> ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue15104] abusive language in __name__ description

2012-06-19 Thread Hynek Schlawack
Hynek Schlawack added the comment: I’m no native speaker but I fail to see anything abusive here. -- nosy: +hynek ___ Python tracker <http://bugs.python.org/issue15

[issue15100] Race conditions in shutil.copy, shutil.copy2 and shutil.copyfile

2012-06-19 Thread Hynek Schlawack
Hynek Schlawack added the comment: It's not that simple as we currently use public functions for copying the files and the metadata. copyfile is explicitly _not_ supposed to copy any metadata so we can't patch it up to do so. Also that won't help for other stat & xattr data

[issue15061] hmac.secure_compare() leaks information about length of strings

2012-06-19 Thread Hynek Schlawack
Hynek Schlawack added the comment: I thought this is settled as of f36af3766a20 (option 2)? -- ___ Python tracker <http://bugs.python.org/issue15061> ___ ___

[issue4489] shutil.rmtree is vulnerable to a symlink attack

2012-06-21 Thread Hynek Schlawack
Hynek Schlawack added the comment: I'll try to get it in before beta1 then. -- ___ Python tracker <http://bugs.python.org/issue4489> ___ ___ Python-bugs-l

[issue10053] Don’t close fd when FileIO.__init__ fails

2012-06-21 Thread Hynek Schlawack
Hynek Schlawack added the comment: Should be fixed now. -- resolution: -> fixed stage: patch review -> committed/rejected status: open -> closed ___ Python tracker <http://bugs.python.or

[issue10053] Don’t close fd when FileIO.__init__ fails

2012-06-21 Thread Hynek Schlawack
Hynek Schlawack added the comment: Hmmm, I thought Lib/_pyio.py actually uses Lib/_io/_fileio.c? At least I can't find the logic inside. There's no error handling at all. It just uses the FileIO object in Lib/_pyio.py:189 which it seems to get from Lib/_pyio.py:585 which I presume

[issue4489] shutil.rmtree is vulnerable to a symlink attack

2012-06-22 Thread Hynek Schlawack
Hynek Schlawack added the comment: Here is my revised patch with Martin's code integrated. Differences: - fixed docs - added some tests, test_on_errors could still use some refactorings though - renamed _rmtree_safe to _rmtree_safe_fd so we can implement more of them - _rmtree_sa

[issue15061] hmac.secure_compare() leaks information about length of strings

2012-06-23 Thread Hynek Schlawack
Hynek Schlawack added the comment: > For 3.4, I hope to see a discussion open up regarding the idea of something > like a "securitytools" module that aims to provide some basic primitives for > operations where Python's standard assumptions (such as flexibility

[issue15154] remove "rmdir" argument from os.unlink, add "dir_fd" to os.rmdir

2012-06-23 Thread Hynek Schlawack
Changes by Hynek Schlawack : -- nosy: +hynek ___ Python tracker <http://bugs.python.org/issue15154> ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue4489] shutil.rmtree is vulnerable to a symlink attack

2012-06-23 Thread Hynek Schlawack
Hynek Schlawack added the comment: I thought about that too but couldn't find a precedent (I didn't look very long though :)) where we've done that before so I went for an attribute. I'd change it immediately if others agree. -- __

[issue4489] shutil.rmtree is vulnerable to a symlink attack

2012-06-23 Thread Hynek Schlawack
Hynek Schlawack added the comment: Excellent Nick! I discussed the very same thing with David yesterday but somehow we didn't come up with a good name. So we kept it on "safe" (which predates the secure discussion). -- ___ Python

[issue4489] shutil.rmtree is vulnerable to a symlink attack

2012-06-24 Thread Hynek Schlawack
Hynek Schlawack added the comment: Okay everyone, let's call it day – after 3,5 years. :) Further enhancement requests please in separate tickets. Thanks to everybody who took part! -- resolution: -> fixed stage: patch review -> committed/rejected status: ope

[issue15100] Race conditions in shutil.copy, shutil.copy2 and shutil.copyfile

2012-06-24 Thread Hynek Schlawack
Changes by Hynek Schlawack : -- versions: +Python 3.4 -Python 3.3 ___ Python tracker <http://bugs.python.org/issue15100> ___ ___ Python-bugs-list mailin

[issue13520] Patch to make pickle aware of __qualname__

2012-06-24 Thread Hynek Schlawack
Changes by Hynek Schlawack : -- nosy: -hynek ___ Python tracker <http://bugs.python.org/issue13520> ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue7719] distutils: ignore .nfsXXXX files

2012-06-24 Thread Hynek Schlawack
Changes by Hynek Schlawack : -- nosy: -hynek ___ Python tracker <http://bugs.python.org/issue7719> ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue14974] rename packaging.pypi to packaging.index

2012-06-24 Thread Hynek Schlawack
Changes by Hynek Schlawack : -- nosy: -hynek ___ Python tracker <http://bugs.python.org/issue14974> ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue10142] Support for SEEK_HOLE/SEEK_DATA

2012-06-24 Thread Hynek Schlawack
Changes by Hynek Schlawack : -- nosy: -hynek ___ Python tracker <http://bugs.python.org/issue10142> ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue15159] Add failover for follow_symlinks and effective_ids where possible

2012-06-24 Thread Hynek Schlawack
Hynek Schlawack added the comment: It also passes OS X. There are no patch specific tests though. And alas, I don't have any platform at hand that would benefit from these additions. :( The idea sounds good to me and the code LGTM though. However I can't really say much as

[issue15118] uname and other os functions should return a struct sequence instead of a tuple

2012-06-24 Thread Hynek Schlawack
Changes by Hynek Schlawack : -- nosy: +hynek ___ Python tracker <http://bugs.python.org/issue15118> ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue15180] Cryptic traceback from os.path.join when mixing str & bytes

2012-06-25 Thread Hynek Schlawack
Hynek Schlawack added the comment: Catch TypeError, check whether bytes & str are being mixed, re-raise if not, say something user-friendly if yes? -- nosy: +hynek ___ Python tracker <http://bugs.python.org/iss

[issue14814] Implement PEP 3144 (the ipaddress module)

2012-06-25 Thread Hynek Schlawack
Hynek Schlawack added the comment: Currently, we get the following warnings: [ 26/369] test_ipaddress /home/vagrant/default/Lib/ipaddress.py:1401: BytesWarning: str() on a bytes instance addr = str(address).split('/') /home/vagrant/default/Lib/ipaddress.py:2004: BytesWarning:

[issue15180] Cryptic traceback from os.path.join when mixing str & bytes

2012-06-25 Thread Hynek Schlawack
Hynek Schlawack added the comment: Here's a fix. It would be nice if it could make for 3.3 final I guess. Tests pass for Linux and OS X. -- keywords: +needs review, patch stage: needs patch -> patch review Added file: http://bugs.python.org/file26156/nicer-error-on-str-bytes-

[issue14814] Implement PEP 3144 (the ipaddress module)

2012-06-25 Thread Hynek Schlawack
Hynek Schlawack added the comment: Ok I looked into it. It uses str() to convert objects into text representation which it then parses. -- ___ Python tracker <http://bugs.python.org/issue14

[issue14814] Implement PEP 3144 (the ipaddress module)

2012-06-25 Thread Hynek Schlawack
Hynek Schlawack added the comment: And the origin of the bytes seems to be: # Compatibility function to cast str to bytes objects _cb = lambda bytestr: bytes(bytestr, 'charmap') -- ___ Python tracker <http://bugs.python.o

[issue15187] test_shutil does not clean up after itself

2012-06-25 Thread Hynek Schlawack
Hynek Schlawack added the comment: LGTM -- ___ Python tracker <http://bugs.python.org/issue15187> ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue15202] followlinks/follow_symlinks/symlinks flags unification

2012-06-27 Thread Hynek Schlawack
Hynek Schlawack added the comment: Yeah, would be nice if that was consistent. -- nosy: +hynek ___ Python tracker <http://bugs.python.org/issue15202> ___ ___

[issue14814] Implement PEP 3144 (the ipaddress module)

2012-06-28 Thread Hynek Schlawack
Hynek Schlawack added the comment: Try running the test like: ./python[.exe] -bb -Wd -m test test_ipaddress -- ___ Python tracker <http://bugs.python.org/issue14

[issue4489] shutil.rmtree is vulnerable to a symlink attack

2012-06-28 Thread Hynek Schlawack
Hynek Schlawack added the comment: Thanks you for catching that! It seems we did something really stupid: followed symlinks. I’ve fixed that and added regression tests. This one is a facepalm gentlepeople. -- ___ Python tracker <h

[issue4489] shutil.rmtree is vulnerable to a symlink attack

2012-06-28 Thread Hynek Schlawack
Changes by Hynek Schlawack : -- resolution: -> fixed stage: -> committed/rejected status: open -> closed ___ Python tracker <http://bugs.python.o

[issue10571] "setup.py upload --sign" broken: TypeError: 'str' does not support the buffer interface

2012-06-28 Thread Hynek Schlawack
Changes by Hynek Schlawack : -- nosy: +hynek versions: +Python 3.4 -Python 3.1 ___ Python tracker <http://bugs.python.org/issue10571> ___ ___ Python-bugs-list m

[issue4489] shutil.rmtree is vulnerable to a symlink attack

2012-06-28 Thread Hynek Schlawack
Hynek Schlawack added the comment: > I'm not a security guy, but: shouldn't the os.unlink call when it isn't a > directory specify follow_symlinks=False? os.unlink has no follow_symlinks argument. Imagine what would happen if you‘d do a os.unlink() on a link and it would

[issue15217] os.listdir is missing in os.supports_dir_fd

2012-06-28 Thread Hynek Schlawack
New submission from Hynek Schlawack : >>> n = os.open('/tmp', os.O_RDONLY) >>> l = os.listdir(n) >>> os.listdir in os.supports_dir_fd False -- assignee: larry components: Library (Lib) messages: 164249 nosy: hynek, larry priority: release blocke

[issue4489] shutil.rmtree is vulnerable to a symlink attack

2012-06-28 Thread Hynek Schlawack
Hynek Schlawack added the comment: > I'm pretty busy right now, please open a ticket for listdir. done > _rmtree_safe_fd could remove the directory just after the recursive step > using the parent's dirfd. Of course you'd also have to add a rmdir for the > very-t

[issue15218] Check for all necessary dir_fd and follow_symlinks functions

2012-06-28 Thread Hynek Schlawack
New submission from Hynek Schlawack : Currently not all functions are checked. As soon as #15217 is fixed, we have to add the rest. -- assignee: hynek components: Library (Lib) files: fd-protection.diff keywords: patch messages: 164259 nosy: hynek priority: release blocker severity

[issue15218] Check for all necessary dir_fd and follow_symlinks functions

2012-06-28 Thread Hynek Schlawack
Changes by Hynek Schlawack : -- dependencies: +os.listdir is missing in os.supports_dir_fd ___ Python tracker <http://bugs.python.org/issue15218> ___ ___ Pytho

[issue15217] os.listdir is missing in os.supports_dir_fd

2012-06-28 Thread Hynek Schlawack
Hynek Schlawack added the comment: I don't really care about the name but I'd really like some way to check whether listdir supports fds. -- ___ Python tracker <http://bugs.python.o

[issue15217] os.listdir is missing in os.supports_dir_fd

2012-06-28 Thread Hynek Schlawack
Hynek Schlawack added the comment: Ah sorry, that wasn't in the mail (stupid >>>). -- ___ Python tracker <http://bugs.python.org/issue15217> ___

[issue15217] os.listdir is missing in os.supports_dir_fd

2012-06-28 Thread Hynek Schlawack
Hynek Schlawack added the comment: Just in my defense: Larry suggested in msg164245 to me to check for listdir in supports_dir_fd so I just assumed it's broken as it didn't work. I'm totally fine with the current behavior, the discussion about dir_fd support in listdir isn&#x

[issue15180] Cryptic traceback from os.path.join when mixing str & bytes

2012-07-03 Thread Hynek Schlawack
Hynek Schlawack added the comment: Cool, I'll finish it up in the sprints on Saturday. -- ___ Python tracker <http://bugs.python.org/issue15180> ___ ___

[issue15238] shutil.copystat should copy Linux extended attributes

2012-07-12 Thread Hynek Schlawack
Hynek Schlawack added the comment: The patch looks good enough. Not sure if we should write Linux though. I sincerely hope we’ll support xattrs on other OSes soonish. Did you catch Georg somewhere whether this can still go in? Would be nice as xattrs are new to 3.3. Changing this in 3.4

[issue15180] Cryptic traceback from os.path.join when mixing str & bytes

2012-07-12 Thread Hynek Schlawack
Hynek Schlawack added the comment: I didn’t, because I pulled an Antoine and enjoyed weather, people and Florence. :) I understand it’s okay to apply this towards 3.2 & 3.3 (with the proposed fixes)? 2.7 is not necessary because this problem doesn’t exist there: > os.path.joi

[issue15238] shutil.copystat should copy Linux extended attributes

2012-07-13 Thread Hynek Schlawack
Hynek Schlawack added the comment: > Hynek: You must forgive me, I'm a recovering Windows programmer. I thought > extended attributes were a Linux-only thing. Can you tell me what other > platforms they are available on? And/or suggest some alternate language? http://en.wiki

[issue15180] Cryptic traceback from os.path.join when mixing str & bytes

2012-07-15 Thread Hynek Schlawack
Hynek Schlawack added the comment: Fixed for 3.2 & default. -- resolution: -> fixed stage: patch review -> committed/rejected status: open -> closed ___ Python tracker <http://bugs.pytho

[issue15238] shutil.copystat should copy Linux extended attributes

2012-07-16 Thread Hynek Schlawack
Hynek Schlawack added the comment: You can’t just compare the xattr because some (like security.*) can be only copied as root. IIRC they come from SELinux. -- ___ Python tracker <http://bugs.python.org/issue15

[issue1492704] distinct error type from shutil.move()

2012-07-16 Thread Hynek Schlawack
Hynek Schlawack added the comment: If nobody else, I’ll review it tomorrow at the latest. On a first glance I realized our shutil Exceptions are all derived from EnvironmentError which is just a compatibility alias for OSError since 3.3. Quick poll before I open a dedicated ticket, change

[issue1492704] distinct error type from shutil.move()

2012-07-16 Thread Hynek Schlawack
Hynek Schlawack added the comment: Well, then fix is for shutil.move() too please, otherwise we can’t close this ticket which is a pity after over 6 years. :) -- ___ Python tracker <http://bugs.python.org/issue1492

[issue1492704] distinct error type if shutil.copyfile() fails because of src and dst are the same file

2012-07-16 Thread Hynek Schlawack
Hynek Schlawack added the comment: Sorry, I didn’t look at zooko’s patch which was also just about copyfile. I presume it’s all about the copy fallback that happens when os.rename didn’t work out. Will look at your code more closely later. -- title: distinct error type from

[issue15238] shutil.copystat should copy Linux extended attributes

2012-07-16 Thread Hynek Schlawack
Hynek Schlawack added the comment: I removed the check for good as we check for the existence of the xattr in the next line. However we check the destination now whether the xattrs have been copied. ;) Fedora is green again. -- ___ Python tracker

[issue1492704] distinct error type if shutil.copyfile() fails because of src and dst are the same file

2012-07-16 Thread Hynek Schlawack
Hynek Schlawack added the comment: > - SameFileError is now derived from EnvironmentError. Why? -- ___ Python tracker <http://bugs.python.org/issue1

[issue1492704] distinct error type if shutil.copyfile() fails because of src and dst are the same file

2012-07-16 Thread Hynek Schlawack
Hynek Schlawack added the comment: No, sorry if my ramblings confused you. I'm pondering about deriving Error from OSError in 3.4. That has nothing to do with this ticket. I just saw it while glancing over your patch. -- ___ Python tracker

[issue15377] os.path.join() error misleading with path1=None

2012-07-17 Thread Hynek Schlawack
Changes by Hynek Schlawack : -- nosy: +hynek ___ Python tracker <http://bugs.python.org/issue15377> ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue15377] os.path.join() error misleading with path1=None

2012-07-17 Thread Hynek Schlawack
Hynek Schlawack added the comment: I propose the following patch (against 3.2) that does the right thing. -- keywords: +patch nosy: +ncoghlan, pitrou stage: -> patch review Added file: http://bugs.python.org/file26414/nicer-error-for-none.d

[issue15377] os.path.join() error misleading with path1=None

2012-07-17 Thread Hynek Schlawack
Changes by Hynek Schlawack : -- assignee: -> hynek versions: +Python 3.2 ___ Python tracker <http://bugs.python.org/issue15377> ___ ___ Python-bugs-list mai

[issue15377] os.path.join() error misleading with path1=None

2012-07-17 Thread Hynek Schlawack
Hynek Schlawack added the comment: Yeah, we talked about that exact think with Antoine on IRC. New proposal. -- Added file: http://bugs.python.org/file26415/nicer-error-for-none-v2.diff ___ Python tracker <http://bugs.python.org/issue15

[issue15377] os.path.join() error misleading with path1=None

2012-07-17 Thread Hynek Schlawack
Hynek Schlawack added the comment: Fine! :) -- resolution: -> fixed stage: patch review -> committed/rejected status: open -> closed ___ Python tracker <http://bugs.python.or

[issue14811] decoding_fgets() truncates long lines and fails with a SyntaxError("Non-UTF-8 code starting with...")

2012-07-19 Thread Hynek Schlawack
Hynek Schlawack added the comment: Are we going to fix this before 3.3? Any objections to Victor's patch? -- ___ Python tracker <http://bugs.python.org/is

[issue1492704] distinct error type if shutil.copyfile() fails because of src and dst are the same file

2012-07-19 Thread Hynek Schlawack
Hynek Schlawack added the comment: As beta2 has been postponed I have already committed it with some slight modifications. Re: deriving from Error: It doesn't make any sense to do so but this way we're mostly backward compatible. Changing it to EnvironmentError uncovered the

[issue1492704] distinct error type if shutil.copyfile() fails because of src and dst are the same file

2012-07-19 Thread Hynek Schlawack
Hynek Schlawack added the comment: Oh my understanding was that it was pushed to 3.4 only because of the then imminent beta2. Georg, is it okay to keep it? -- ___ Python tracker <http://bugs.python.org/issue1492

[issue1492704] distinct error type if shutil.copyfile() fails because of src and dst are the same file

2012-07-19 Thread Hynek Schlawack
Hynek Schlawack added the comment: Ok sorry, backing out. -- resolution: fixed -> stage: committed/rejected -> status: closed -> open versions: +Python 3.4 -Python 3.3 ___ Python tracker <http://bugs.python.org/

[issue15406] Deprecation Warnings fixes on test suite

2012-07-20 Thread Hynek Schlawack
Changes by Hynek Schlawack : -- nosy: +hynek ___ Python tracker <http://bugs.python.org/issue15406> ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue15461] os.stat() 's inappropriate behavior when dealing with a broken link in linux systems.

2012-07-26 Thread Hynek Schlawack
Hynek Schlawack added the comment: For the sake of completeness: what you're looking for is os.lstat. -- nosy: +hynek ___ Python tracker <http://bugs.python.org/is

[issue15487] Correct __sizeof__ support for buffered I/O

2012-07-29 Thread Hynek Schlawack
Hynek Schlawack added the comment: There is no patch. -- stage: -> needs patch ___ Python tracker <http://bugs.python.org/issue15487> ___ ___ Python-bugs-lis

<    1   2   3   4   >