Wapp opening two browsers on Linux
(1) By Rodolfo Carvalho (rhcarvalho) on 2022-11-10 11:24:06 [source]
Hello! Thanks for Wapp!
When running a Wapp script in local mode on Linux, wappInt-start-browser (apparently unintentionally) opens two browsers (Chrome - set as system default, and Firefox).
I think the problem is that Chrome outputs some debug messages to stderr, and TCL's exec command treats that as an error.
I made a small change to my copy of wapp.tcl that solves the issue. I wonder if that would be applicable to other users as well?
@@ -414,7 +414,7 @@ proc wappInt-start-browser {url} {
exec cmd /c start $url &
} elseif {$tcl_platform(os)=="Darwin"} {
exec open $url &
- } elseif {[catch {exec xdg-open $url}]} {
+ } elseif {[catch {exec -ignorestderr xdg-open $url} msg opts]} {
exec firefox $url &
}
}
(2) By Rodolfo Carvalho (rhcarvalho) on 2022-11-10 20:50:02 in reply to 1 [link] [source]
For future reference, the proposed change was applied in 253fa3bcea19dde2.