[issue7490] IGNORE_EXCEPTION_DETAIL should ignore the module name
Julian Scheid added the comment: Having this in 2.6/2.7 would be great. I don't think the ELLIPSIS workaround suggested by Barry works, have you actually tried it? Below is an example where ELLIPSIS doesn't seem to help (run in 2.6.5). I have also tried "...Error:" and "...:", and tried replacing ". . ." by "...", to no avail. I'm assuming this has to do with issue #1192554, or am I making a silly mistake? Otherwise, are there any other workarounds you can suggest? Without ellipsis the following example works in 2.6 but of course fails in 3.x. Failed example: Redacted.from_str('1-7@') #doctest: +ELLIPSIS Expected: Traceback (most recent call last): . . . ...ParserError: : 1-7@ ^ expected digit Got: Traceback (most recent call last): ParserError: : 1-7@ ^ expected digit -- nosy: +Julian.Scheid ___ Python tracker <http://bugs.python.org/issue7490> ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue7490] IGNORE_EXCEPTION_DETAIL should ignore the module name
Julian Scheid added the comment: Here's a better example that you can cut and paste. import optparse def foo(): """ >>> foo() #doctest: +ELLIPSIS Traceback (most recent call last): . . . ...OptionError: option bar: foo """ raise optparse.OptionError('foo', 'bar') if __name__ == "__main__": import doctest doctest.testmod() -- ___ Python tracker <http://bugs.python.org/issue7490> ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue7490] IGNORE_EXCEPTION_DETAIL should ignore the module name
Julian Scheid added the comment: Ah, right... so there is no easy workaround at present? -- ___ Python tracker <http://bugs.python.org/issue7490> ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue7490] IGNORE_EXCEPTION_DETAIL should ignore the module name
Julian Scheid added the comment: Thank you for the suggestion but in my mind that's not a viable workaround, and not just because of uglyness: I'm using doctest to validate code examples, which are included in the documentation and are meant to be educational. If I'd change my examples to match the pattern you suggest they might still serve their purpose as a test but they'd become useless as an example. So it appears there is no real workaround for this issue. Any chance we can get the patch into 2.7? By the way, I said earlier that Barry suggested the ELLIPSIS workaround but it was actually ncoghlan who did so - apologies for the confusion. -- ___ Python tracker <http://bugs.python.org/issue7490> ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue7490] IGNORE_EXCEPTION_DETAIL should ignore the module name
Julian Scheid added the comment: Hmm, wait. Here's a variation of your suggestion that works OK-ish even as an example: >>> try: ...# ... code that fails ... ... except mypkg.MyException, e: ...print(str(e)) Expected error message. This works because it omits the exception type in the output. It's still far from ideal, because as an example it's more complicated than it would need to be, but I guess it works as a stop-gap solution. Still, +1 for including the patch. -- ___ Python tracker <http://bugs.python.org/issue7490> ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue3646] MacOS X framework install to non-standard directory fails
Julian Scheid added the comment: The same issue is present in 2.4 and 2.5 as well as 3.0 so I'm updating this issue accordingly (haven't tried 2.7 or 3.1). I've been working around this issue with some success and will be posting patches shortly. -- nosy: +julians37 versions: +Python 2.4, Python 2.5, Python 3.0 ___ Python tracker <http://bugs.python.org/issue3646> ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue3646] MacOS X framework install to non-standard directory fails
Julian Scheid added the comment: Actually this seems to be fixed in 3.0.1 - yay! -- versions: -Python 3.0 ___ Python tracker <http://bugs.python.org/issue3646> ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue3646] MacOS X framework install to non-standard directory fails
Julian Scheid added the comment: Attached a fix for release26-maint branch. I've tested this as follows: ./configure --enable-toolbox-glue --enable-universalsdk --enable-framework=/tmp/python-2.6-maint-install/Library/Framework --prefix=/tmp/python-2.6-maint-install && make -j3 && make frameworkinstall I have not tested this with the default install paths. Patches for 2.5 and 2.4 coming up. -- keywords: +patch Added file: http://bugs.python.org/file13659/Python-2.6-maint-osx-framework-path.patch ___ Python tracker <http://bugs.python.org/issue3646> ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue3646] MacOS X framework install to non-standard directory fails
Julian Scheid added the comment: I had a hunch that might be the case. I'm still planning to upload them here for the benefit of others who, like me, have to maintain those versions as framework installs. Is that OK? -- ___ Python tracker <http://bugs.python.org/issue3646> ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue3646] MacOS X framework install to non-standard directory fails
Julian Scheid added the comment: I was a bit surprised myself but I've just double-checked and it seems to work fine. I started with a freshly unpacked 3.0.1 tarball and used the following command: ./configure --enable-toolbox-glue --enable-universalsdk --enable-framework=/tmp/python-3.0.1-install/Library/Framework --prefix=/tmp/python-3.0.1-install && make -j3 && make fullinstall That went through OK, everything seems to be in its place and the interpreter starts up. I was testing with "make frameworkinstall" earlier, that worked, too. One question, $PREFIX/bin doesn't have the files without version number (e.g. it has python3.0 but doesn't have python) even in fullinstall mode. Is that intentional? (The framework's bin directory does have all files.) I've seen the same issue in 2.6. -- ___ Python tracker <http://bugs.python.org/issue3646> ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue3646] MacOS X framework install to non-standard directory fails
Julian Scheid added the comment: On second thought, are you sure that's how fullinstall is meant to work? If I use frameworkinstall I get the following message at the end: * Note: not installed as 'python'. * Use 'make fullinstall' to install as 'python'. * However, 'make fullinstall' is discouraged, * as it will clobber your Python 2.x installation. Doesn't that suggest that fullinstall would put the no-suffix symlinks in place? In other words, is there a reason that no-suffix links _are_ installed in the framework bin directory in fullinstall mode, but aren't installed in $PREFIX/bin? -- ___ Python tracker <http://bugs.python.org/issue3646> ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue3646] MacOS X framework install to non-standard directory fails
Julian Scheid added the comment: Ah, that makes sense - thanks for clarifying. And I was mistaken about 2.6, the no-suffix symlinks are there in $PREFIX/bin so all is good. Let me know what you think of the patch when you get a chance to look at it. -- ___ Python tracker <http://bugs.python.org/issue3646> ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue13829] exception error in _scproxy.so
Julian Scheid added the comment: FWIW, I've run into the same issue in a homegrown application with 2.6.8, 2.7.2 and 2.7.3 (these were the only versions I've tested). Looking around a little bit, I suspect this might be a bug in SCDynamicStoreCopyProxies that's only present on OS X 10.7 and only triggered when invoked in a forked child (?) [1][2]. I've tried working around it by invoking SCDynamicStoreCopyProxies with a non-NULL SCDynamicStoreRef but to no avail. Since I don't need this Python application to use HTTP proxies, I'm working around it now like this: proxy_handler = urllib2.ProxyHandler({}) opener = urllib2.build_opener(proxy_handler) request = urllib2.Request(...) response = opener.open(request) [1] http://forums.macrumors.com/archive/index.php/t-1295113.html [2] https://github.com/suminb/spider/issues/7 -- nosy: +Julian.Scheid ___ Python tracker <http://bugs.python.org/issue13829> ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com