[issue27069] webbrowser creates zombi processes in the background mode

2021-09-21 Thread STINNER Victor


STINNER Victor  added the comment:

Python 3.6 was released 5 years ago. Nobody complained about ResourceWarning. 
While it would be nice to fix the issue, nobody managed to write a fix in 5 
years and this issue has no activity for 3 years. I close the issue.

--
resolution:  -> out of date
stage:  -> resolved
status: open -> closed

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue27069] webbrowser creates zombi processes in the background mode

2020-01-11 Thread kernc


Change by kernc :


--
nosy: +kernc
versions: +Python 3.7, Python 3.8, Python 3.9

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue27069] webbrowser creates zombi processes in the background mode

2018-03-17 Thread Martin Panter

Martin Panter  added the comment:

It does look similar. They probably could be merged. The main difference is in 
Issue 5993 Eivind suggested to somehow use a “wait” system call, while here 
Victor suggested “fork” (perhaps to orphan a grandchild process?).

--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue27069] webbrowser creates zombi processes in the background mode

2018-03-01 Thread Serhiy Storchaka

Serhiy Storchaka  added the comment:

Isn't this a duplicate of issue5993?

--
nosy: +serhiy.storchaka

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue27069] webbrowser creates zombi processes in the background mode

2016-12-15 Thread Brendan Donegan

Brendan Donegan added the comment:

This appears to be Firefox specific? At least:

b = webbrowser.get("chromium-browser")
b.open("https://bugs.python.org/issue26741;)

returns simply:

True

With no exception

--
nosy: +brendan-donegan

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue27069] webbrowser creates zombi processes in the background mode

2016-05-20 Thread Martin Panter

Martin Panter added the comment:

I think the Firefox command will exit immediately if it just signals an 
existing Firefox process and window, but becomes the main Firefox process if 
there isn’t already one running.

Background = False sounds like it won’t help. Don’t we want the opposite?

--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue27069] webbrowser creates zombi processes in the background mode

2016-05-20 Thread STINNER Victor

STINNER Victor added the comment:

I checked how "xdg-open http://www.python.org/; works. It looks like the 
command works as webbrowser: create a child process "firefox URL", but then it 
waits until the command completes.

In fact, "firefox URL" exits quickly. So we can try "background = False" for 
firefox. Well, at least with my Firefox 46.0.1.

--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue27069] webbrowser creates zombi processes in the background mode

2016-05-20 Thread STINNER Victor

New submission from STINNER Victor:

The webbrowser opens almost all browsers in background mode, it looks like only 
Elinks is not opened in this mode.

Problem: the webbrowser doesn't read the exit status of the browser, and so 
create zombi process. On Python 3.6, the subprocess module now emits a 
ResourceWarning in this case (issue #26741).

For example, the following script shows a zombi process (""):
---
import webbrowser, os

b = webbrowser.get("firefox")
b.open("https://bugs.python.org/issue26741;)
b = None

os.system("ps ax|grep firefox")
input("press ENTER when firefox exited")
os.system("ps ax|grep firefox")
---

I guess that Python should use os.fork() somehow to fix this issue.

Another option is to hack the Popen object to not display the warning, but I 
don't think that it's a safe option.

See also the issue #27068 "Add a detach() method to subprocess.Popen", but I 
don't think that it is directly related to background processes run by 
webbrowser.

--
messages: 265939
nosy: haypo, martin.panter
priority: normal
severity: normal
status: open
title: webbrowser creates zombi processes in the background mode
versions: Python 3.5, Python 3.6

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com