From 4421862b3ec84fdc8735fc7d35d3428fbc6b754f Mon Sep 17 00:00:00 2001 From: Florian Bruhin Date: Thu, 17 Apr 2014 11:49:19 +0200 Subject: [PATCH] Don't use shlex for splitting anymore --- TODO | 18 ------------------ qutebrowser/commands/parsers.py | 4 +--- 2 files changed, 1 insertion(+), 21 deletions(-) diff --git a/TODO b/TODO index 943a3e39e..82aa405e7 100644 --- a/TODO +++ b/TODO @@ -3,24 +3,6 @@ Bugs keybind doesn't work properly because it only wants 1 argument for cmd dump_userconfig dumps everything for ValueList sections -using " in command bar causes exception with shutil commands - Traceback (most recent call last): - File ".\qutebrowser\widgets\completion.py", line 244, in on_cmd_text_changed - parts = split_cmdline(text) - File ".\qutebrowser\commands\parsers.py", line 230, in split_cmdline - parts = parser.parse(text) - File ".\qutebrowser\commands\parsers.py", line 152, in parse - args = shlex.split(parts[1]) - File "C:\python33\lib\shlex.py", line 276, in split - return list(lex) - File "C:\python33\lib\shlex.py", line 266, in __next__ - token = self.get_token() - File "C:\python33\lib\shlex.py", line 93, in get_token - raw = self.read_token() - File "C:\python33\lib\shlex.py", line 169, in read_token - raise ValueError("No closing quotation") - ValueError: No closing quotation - All kind of FIXMEs Weird font rendering https://bugreports.qt-project.org/browse/QTBUG-20973 diff --git a/qutebrowser/commands/parsers.py b/qutebrowser/commands/parsers.py index e6289c28f..594029d3a 100644 --- a/qutebrowser/commands/parsers.py +++ b/qutebrowser/commands/parsers.py @@ -17,8 +17,6 @@ """Module containing commandline parsers ( SearchParser and CommandParser).""" -import shlex - from PyQt5.QtCore import pyqtSlot, pyqtSignal, QObject from PyQt5.QtWebKitWidgets import QWebPage @@ -149,7 +147,7 @@ class CommandParser: if len(parts) == 1: args = [] elif cmd.split_args: - args = shlex.split(parts[1]) + args = parts[1].split() else: args = [parts[1]] self._cmd = cmd