Bug 17975 - Mageia Welcome page-1 links become unresponsive after opening a window of the default Web browser from MW (several DE)
Summary: Mageia Welcome page-1 links become unresponsive after opening a window of the...
Status: REOPENED
Alias: None
Product: Mageia
Classification: Unclassified
Component: RPM Packages (show other bugs)
Version: Cauldron
Hardware: All Linux
: High major
Target Milestone: Mageia 6
Assignee: Daniel Napora
QA Contact: Rémi Verschelde
URL:
Whiteboard: MGA5TOO
Keywords: 6sta2
Depends on:
Blocks:
 
Reported: 2016-03-13 00:39 CET by ben mcmonagle
Modified: 2017-03-05 20:17 CET (History)
3 users (show)

See Also:
Source RPM: os.system() waits on the spawned process to exit before getting back to MageiaWelcome, should spawn in background
CVE:
Status comment:


Attachments
install report (175.25 KB, application/x-xz)
2016-03-13 00:42 CET, ben mcmonagle
Details

Description ben mcmonagle 2016-03-13 00:39:27 CET
Description of problem:Mageia Welcome page-1 links become unresponsive after about 20 minutes
switching between "Welcome" and "Applications" still operates as does choosing options 1-4
exiting Mageia Welcome and then invoking a new instance does not exhibit this behaviour

not noted on other DE


Version-Release number of selected component (if applicable):

Mageia-6-dev1-i586-DVD.iso
Mageia-6-dev1-x86_64-DVD.iso
DATE.txt: Thu Mar 10 21:45:52 CET 2016


How reproducible:every time


Steps to Reproduce:
1.install only LXDE  from either  above .iso
2.reboot to and login to LXDE (default is Icewm so need to select LXDE)
3.(reset internet connection)
4. check  any link from welcome page 
5 wait about 20 minutes and try another link- button surround changes but no other response
Comment 1 ben mcmonagle 2016-03-13 00:42:10 CET
Created attachment 7566 [details]
install report
Comment 2 Nicolas Salguero 2016-03-29 17:02:25 CEST
Hi,

Is the problem still here?  I cannot reproduce it in my x86_64 Virtualbox VM, sorry.

Best regards,

Nico.
Comment 3 ben mcmonagle 2016-04-03 00:22:34 CEST
(In reply to Nicolas Salguero from comment #2)
> Hi,
> 
> Is the problem still here?

after updates applied last night, [378] no longer apparent
Comment 4 ben mcmonagle 2016-05-02 12:41:21 CEST
Hi Nico,

ok, discovered something.

if a link to the internet is opened from Mageia Welcome ie "wiki", while that Firefox instance is active, all other links from Mageia Welcome are unable to be used.

hope this helps narrow down the issue.

Time doesnt seem to be the issue
Comment 5 Marja van Waes 2016-05-05 09:36:55 CEST
@ Ben

Does this only happen in LXDE? (I don't have the issue in Plasma5 on a updated cauldron that dates from January)

CC'ing napcok, anyway, since he's MageiaWelcome's daddy.

Should the Keywords: be updated to "6sta1"?
Comment 6 ben mcmonagle 2016-05-05 11:36:19 CEST
(In reply to Marja van Waes from comment #5)
> @ Ben
> 
> Does this only happen in LXDE? (I don't have the issue in Plasma5 on a
> updated cauldron that dates from January)

yes, for Mageia-6-sta1-i586-DVD.iso
DATE.txt: Tue May  3 12:34:47 CEST 2016

single DE install and 29/04  multi DE install - 

> 
> Should the Keywords: be updated to "6sta1"?

yes - doing
Comment 7 ben mcmonagle 2016-05-25 11:41:42 CEST
fixed in 

Mageia-6-sta1-x86_64-DVD.iso
DATE.txt: Fri May 20 15:16:56 CEST 2016
Comment 8 ben mcmonagle 2016-05-25 21:51:13 CEST
I had an open (minimised) Firefox window before I started checking.
after closing all Firefox windows and attempting multiple web links from Mageia Welcome, problem is still apparent.

so still valid :-(
Comment 9 Nicolas Salguero 2016-05-26 14:41:35 CEST
Hi,

I tried to better understand the problem so I did some tests.

I found that not only LXDE is affected by the bug but also other DE (in my tests, at least LXQt, Openbox and IceWM are affected too).

I also found that the issue is in /usr/share/mageiawelcome/mageiawelcome.py at lines 189 and 191: os.system("xdg-open " + msg).

I added some print("OK...") just before and just after those lines, in the conditions elif msg.startswith("http") and elif msg.startswith("irc").

I saw that, when no web browser process is running (tested with firefox and midori, so the problem does not come from firefox), only the print just before the line os.system("xdg-open " + msg) is displayed; the print just after that line is only displayed when you close the web browser.

If a web browser process is running, the two print("OK...") are displayed.

That behaviour is coherent with the fact that, if no web browser process is running, if you click on the wiki link in mageiawelcome, for example, and, then, on the forum link, the second page will not be opened until you close the web browser.

It also works with the check box "Show this window at startup": creation or removal of $HOME/.mageiawelcome/norun.flag will not occur until you close the web browser if no web browser process was running at the time you clicked on a link in mageiawelcome.

I put some "echo OK..." in /bin/xdg-open and /bin/www-browser and replaced, in /usr/share/mageiawelcome/mageiawelcome.py, the line os.system("xdg-open " + msg) by os.system("firefox " + msg) and, with those tests, I am sure the problem is neither in /bin/xdg-open nor in /bin/www-browser.

In fact, when no web browser process is running, mageiawelcome needs to create a child process to display the requested link and, because of that, it waits the end of that child process before doing anything else (the child process is running in foreground).

I solved the problem by replacing os.system("xdg-open " + msg) by os.system("xdg-open " + msg + " &"), i.e. forcing mageiawelcome to launch the child process in background.

What I do not understand is why that issue does not occur in Plasma, XFCE or MATE, for instance, but my solution does not seem to cause additional problems with those DE.

Best regards,

Nico.
Comment 10 Nicolas Salguero 2016-05-27 14:24:16 CEST
Hi,

The problem also occurs with Enlightenment.

Best regards,

Nico.
Comment 11 ben mcmonagle 2016-06-09 21:55:30 CEST
thanks for keeping at this Nico

(no other testers appear to note this issue, so it may be "corner case?")
Comment 12 ben mcmonagle 2016-09-28 09:50:37 CEST
Hello Nico,

sadly this is now affecting Mga5(.1):

Mageia-5.1-x86_64-DVD.iso
DATE.txt: Thu Sep 22 23:59:29 CEST 2016
md5sum:   497c65d22b74cd8afcd24badf6df6a1c

6 in 1 DE install.

would you like a new report or shall this one do?
Comment 13 Rémi Verschelde 2016-10-17 11:52:07 CEST
Adding "&" to run in the background seems fine to me, could you push this fix Nicolas? Opening links should not be blocking for MageiaWelcome.

Alternatively, Python's documentation recommends using subprocess instead of os.system for such things: https://docs.python.org/3/library/os.html#os.system

Or webbrowser.open could do the trick too probably: http://stackoverflow.com/questions/4216985/call-to-operating-system-to-open-url
Comment 14 Rémi Verschelde 2016-10-17 11:53:35 CEST
Decreasing the priority as it can still be fixed post-release, and we now can still keep a good overview of High priority bugs.
Comment 15 Daniel Napora 2016-10-17 12:44:03 CEST
Hello, 
I will work on this later this week.
Comment 16 ben mcmonagle 2017-02-23 08:59:40 CET
Just to recap.

In Mageia6-sta2-x86_64 LXDE only install (MBR/legacy  with intel 810 or later).
Issue is still apparent.

Currently, invoking any single web-link will spawn Firefox (default browser) with a single tab.
 
Invoking a second or more links now queues the request(s).
So closing the open Browser tab immediately spawns the next "request"in the queue.
If this happens to be a web-link, Firefox will spawn.
If it is a link to MCC, it will spawn the authentication dialogue window. 

For comparison, in Cinnamon DE, invoking an single web link will spawn Firefox ( default browser) with a single tab.
Choosing another or more web-kinks will spawn a new browser tab, and choosing an MCC link will spawn the authentication dialogue window.
I would consider this to be normal behaviour.

Is there any assistance that I (humble tester) could provide to resolve this issue.
Comment 17 Marja van Waes 2017-03-05 10:31:40 CET
(In reply to ben mcmonagle from comment #4)
> 
> ok, discovered something.
> 
> if a link to the internet is opened from Mageia Welcome ie "wiki", while
> that Firefox instance is active, all other links from Mageia Welcome are
> unable to be used.
> 
> hope this helps narrow down the issue.
> 
> Time doesnt seem to be the issue

Is this bug still valid for _newest_ 6sta2?
Comment 18 ben mcmonagle 2017-03-05 20:17:00 CET
yes

Note You need to log in before you can comment on or make changes to this bug.