]> git.ipfire.org Git - thirdparty/Python/cpython.git/commitdiff
[2.7] bpo-34019: Fix wrong arguments for Opera Browser (GH-8047) (#8126)
authorPablo Galindo <Pablogsal@gmail.com>
Fri, 6 Jul 2018 23:54:09 +0000 (00:54 +0100)
committerGitHub <noreply@github.com>
Fri, 6 Jul 2018 23:54:09 +0000 (00:54 +0100)
The Opera Browser was using a outdated command line invocation that resulted in an incorrect URL being opened in the browser when requested using the webbrowser module.

* Correct the arguments passed to the Opera Browser when opening a new URL..
(cherry picked from commit 3cf1f154edb88c108877729ea09f4ac174697fea)

Co-authored-by: Bumsik Kim <k.bumsik@gmail.com>
Lib/webbrowser.py
Misc/NEWS.d/next/Library/2018-07-02-05-59-11.bpo-34019.ZXJIife.rst [new file with mode: 0644]

index 23891796e33b3c6eb0f93bb6eb599d43ef732959..15eeb660e258318303739c83cf912e1fcb5d312b 100755 (executable)
@@ -319,11 +319,10 @@ Chromium = Chrome
 class Opera(UnixBrowser):
     "Launcher class for Opera browser."
 
-    raise_opts = ["-noraise", ""]
-    remote_args = ['-remote', 'openURL(%s%action)']
+    remote_args = ['%action', '%s']
     remote_action = ""
-    remote_action_newwin = ",new-window"
-    remote_action_newtab = ",new-page"
+    remote_action_newwin = "--new-window"
+    remote_action_newtab = ""
     background = True
 
 
diff --git a/Misc/NEWS.d/next/Library/2018-07-02-05-59-11.bpo-34019.ZXJIife.rst b/Misc/NEWS.d/next/Library/2018-07-02-05-59-11.bpo-34019.ZXJIife.rst
new file mode 100644 (file)
index 0000000..8a9fe79
--- /dev/null
@@ -0,0 +1,2 @@
+webbrowser: Correct the arguments passed to Opera Browser when opening a new URL
+using the ``webbrowser`` module. Patch by Bumsik Kim.