This issue tracker has been migrated to GitHub, and is currently read-only.
For more information, see the GitHub FAQs in the Python's Developer Guide.

classification
Title: fix UnixBrowswer failure when no browser running
Type: Stage:
Components: Library (Lib) Versions: Python 2.5
process
Status: closed Resolution: accepted
Dependencies: Superseder:
Assigned To: Nosy List: georg.brandl, gregcouch
Priority: normal Keywords: patch

Created on 2005-12-03 02:04 by gregcouch, last changed 2022-04-11 14:56 by admin. This issue is now closed.

Files
File name Uploaded Description Edit
webbrowser.py.patch gregcouch, 2005-12-08 23:47 patch for revision 41511 of webbrowser.py
Messages (3)
msg49160 - (view) Author: Greg Couch (gregcouch) Date: 2005-12-03 02:04
See discussions in bug #1352621 and bug #1338995 for
even more details.

Background:

The webbrowser.py was modified, post-Python 2.4.2, to
tell whether or not the browser invocation succeeded or
not.  Unfortunately, the modifications caused Python
applications to hang when no browser was already
present.    And the reputed fix for bug #1338995,
revision 41419, only made things worse for UnixBrowsers.

Fix:

The changes to webbrowser.py were well intentioned, but
failed because it was difficult to tell if invocation
succeeded due to an extra level of indirection in
invoking the browser by using os.system().

The attached patch, for revision 41511, uses
subprocess.Popen() instead for UnixBrowser.  The other
uses of os.system() would also benefit, but are less
critical to me.
msg49161 - (view) Author: Greg Couch (gregcouch) Date: 2005-12-08 23:47
Logged In: YES 
user_id=131838

Replace original patch with one that has the tabs expanded
out into spaces.
msg49162 - (view) Author: Georg Brandl (georg.brandl) * (Python committer) Date: 2006-01-20 21:03
Logged In: YES 
user_id=1188172

Thanks for the patch, most of the changed have been adapted
and incorporated into the newest revision of webbrowser.py
(42121).
History
Date User Action Args
2022-04-11 14:56:14adminsetgithub: 42653
2005-12-03 02:04:48gregcouchcreate