[issue17556] os.path.join() converts None to '' by default

2013-03-28 Thread Georg Brandl
Georg Brandl added the comment: Since most other os.path functions also choke (intentionally) on None values, I agree and would point out that if you want this behavior, it's easy to do the "or ''" dance on the caller side. -- nosy: +georg.brandl resolution: -> rejected status: open -

[issue17556] os.path.join() converts None to '' by default

2013-03-27 Thread Éric Araujo
Changes by Éric Araujo : -- nosy: +eric.araujo ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.pyth

[issue17556] os.path.join() converts None to '' by default

2013-03-27 Thread Eric V. Smith
Eric V. Smith added the comment: I agree with David. This is a programming error, and should result in an exception. -- nosy: +eric.smith ___ Python tracker ___

[issue17556] os.path.join() converts None to '' by default

2013-03-27 Thread R. David Murray
R. David Murray added the comment: I think it is probably better to keep the error, myself. It seems to me that a None creeping in is more likely to be an error in the program. But I could be convinced otherwise :) What is your use case? -- nosy: +r.david.murray versions: -Python

[issue17556] os.path.join() converts None to '' by default

2013-03-27 Thread Muhammad Hallaj Subery
Muhammad Hallaj Subery added the comment: I believe this can be easily archived by adding the following changes: 64c64 < path = a or '' --- > -- ___ Python tracker ___ _

[issue17556] os.path.join() converts None to '' by default

2013-03-27 Thread Muhammad Hallaj Subery
New submission from Muhammad Hallaj Subery: I think the default behavior of os.path.join() when None is passed as the first argument should be to translate it to '' by default. >>> import os >>> os.path.join(None, 'somewhere') 'somewhere' vs the current >>> import os >>> os.path.join(None, 's