Commit Graph

14288 Commits

Author SHA1 Message Date
Ryan Roden-Corrent
8358c76f86 Fix casing of LIKE in comment 2017-12-12 20:26:30 -05:00
Ryan Roden-Corrent
158cfa1194 Clean up "any order" SQL query code.
- Replace a list with a generator
- Add commments to the less obvious parts
- Simplify the binding variable names
2017-12-12 17:28:38 -05:00
Ryan Roden-Corrent
6a20f9d4c9 Cache url query when possible.
We don't need to regenerate a new query every keystroke, but rather
every time the user adds a new word.
2017-12-12 07:37:31 -05:00
Ryan Roden-Corrent
8909e03f1c Match url completion terms in any order.
Perviously, 'foo bar' would match 'foo/bar' but not 'bar/foo'. Now it
will match both, using a query with a WHERE clause like:

WHERE ((url || title) like '%foo%' AND (url || title) like '%bar%')

This does not seem to change the performance benchmark. However, it does
create a new query for every character added rather than re-running the
same query with different parameters. We could re-use queries if we
maintained a list like self._queries=[1_arg_query, 2_arg_query, ...].
However, it isn't clear that such a complexity would be necessary.

Resolves #1651.
2017-12-11 07:46:50 -05:00
Florian Bruhin
d4cadcc62e Add comment about @run-at
[ci skip]
2017-12-07 08:17:15 +01:00
Florian Bruhin
0f20f16b15 Merge branch 'greasemonkey' 2017-12-06 21:24:15 +01:00
Florian Bruhin
f033b228b1 Use py.path.local in save_script 2017-12-06 21:21:55 +01:00
Florian Bruhin
04d2004528 tox: Fix eslint environment
We need to set basepython there to not get InterpreterNotFound
2017-12-06 20:58:14 +01:00
Florian Bruhin
eb90f9835f Mark qute://settings test as flaky 2017-12-06 20:54:14 +01:00
Florian Bruhin
d6039a0e34 Fix markers for editor test 2017-12-06 20:30:46 +01:00
Florian Bruhin
6aafe02320 Make sure scripts are removed correctly 2017-12-06 20:18:41 +01:00
Florian Bruhin
a37ecc353c Simplify for loop 2017-12-06 20:18:41 +01:00
Florian Bruhin
2633dcc0d5 Fix lint 2017-12-06 20:18:41 +01:00
Florian Bruhin
dd63508be7 Add a greasemonkey.init()
This also creates the greasemonkey directory if it doesn't exist yet, for
discoverability.
2017-12-06 11:55:08 +01:00
Florian Bruhin
0c792d228e Update docs 2017-12-06 11:12:25 +01:00
Florian Bruhin
3cd2910fa2 Merge branch 'greasemonkey' of https://github.com/toofar/qutebrowser into greasemonkey 2017-12-06 10:47:29 +01:00
Jimmy
6b3e16b163 Greasemonkey: mark failing no(sub)frames test as flaky.
This test is supposed to ensure that user scripts don't run on iframes
when the @noframes directive is set in the greasemonkey metadata. It is
failing sometimes on travis but passing on local test runs. Personally I
haven't actually ran the whole test suite through, just the javascript
tests. It maybe be some stale state that only shows up when you run the
whole suite. It may be some timing issue that only shows up on travis
because ???. Hopefully this stops the red x from showing up on the PR.
2017-12-06 20:34:29 +13:00
Jimmy
ead108eeeb fixup! Greasemonkey: Add run-at document-idle. 2017-12-06 20:27:56 +13:00
Jimmy
129f97873a Greasemonkey: add assert to tests scripts_for assumptions.
And crash the users browsing session as a result of any accidental and
totally, otherwise, non-fatal unforseen errors.
2017-12-06 20:21:29 +13:00
Florian Bruhin
7d7c841250 Update changelog 2017-12-06 08:01:39 +01:00
Florian Bruhin
1a3f8662e6 Improve handling of cancelled search callbacks 2017-12-06 07:56:59 +01:00
Florian Bruhin
9ec4e749f1 Merge branch 'fix_search_callbacks' of https://github.com/jupart/qutebrowser 2017-12-06 07:51:19 +01:00
Florian Bruhin
a3ba7b9f60 Reformat hist_importer epilog. 2017-12-06 07:45:52 +01:00
Florian Bruhin
16e09d18fa Update changelog 2017-12-06 07:42:07 +01:00
Florian Bruhin
549a3a8f70 Improve hist_importer messages 2017-12-06 07:41:41 +01:00
Florian Bruhin
6ea250dc83 Merge remote-tracking branch 'origin/pr/3044' 2017-12-06 07:17:22 +01:00
Florian Bruhin
b326f12427 Mark editor test as flaky
See #3367
2017-12-06 06:59:08 +01:00
Florian Bruhin
9c042e4313 Update changelog 2017-12-06 06:58:22 +01:00
Florian Bruhin
0df1d07558 Merge remote-tracking branch 'origin/pr/3367' 2017-12-06 06:57:59 +01:00
Florian Bruhin
58212a7b15 Update docs 2017-12-06 06:56:12 +01:00
Florian Bruhin
7a6d568c8c Remove blank line 2017-12-06 06:53:27 +01:00
Florian Bruhin
7f81f0c0ab Always open session tabs in foreground
This helps with issues with lazy sessions as document.hidden was set
incorrectly.

See #3345, #3366
2017-12-06 06:51:15 +01:00
Florian Bruhin
dcb4448594 Merge remote-tracking branch 'origin/pr/3345' 2017-12-06 06:51:03 +01:00
Justin Partain
00a09354c3 Track number of active searches in tab, ignore all but most recent search callbacks 2017-12-05 08:28:10 -05:00
Ryan Roden-Corrent
636f9edff6 History completion by both URL and title.
Resolves #1649.
2017-12-05 07:32:58 -05:00
Florian Bruhin
e97fbfdf56 Merge remote-tracking branch 'origin/pr/3355' 2017-12-05 13:22:36 +01:00
Florian Bruhin
8a3437c6a4 Adjust Debian install instructions 2017-12-05 09:36:14 +01:00
Florian Bruhin
29c2e7b45f Skip :follow-selected tests on Qt 5.10
See #3003, #2635
2017-12-05 08:35:12 +01:00
Florian Bruhin
0ce9a355ae Fix download test with Qt 5.10
Not sure why this is needed (no prompt is shown otherwise), but it works like
this.

This probably is related to https://bugreports.qt.io/browse/QTBUG-63388

See #3003
2017-12-05 08:34:37 +01:00
Florian Bruhin
62228752aa Fix most end2end tests with Qt 5.10
For some reason, if we don't wait for about:blank to be fully loaded with
Qt 5.10, we get the next LoadStatus.finished notification with about:blank as
URL.

This is most likely caused by the changes in
https://codereview.qt-project.org/#/c/202924/

See #3003
2017-12-05 08:34:33 +01:00
Florian Bruhin
a8f4444c24 tests: Show more of the message 2017-12-04 22:07:49 +01:00
Florian Bruhin
b554e1f763 tests: Add after= argument to wait_for 2017-12-04 22:07:23 +01:00
François Chavant
9675ea93ee Do not call pip in travis_install.sh when TESTENV=shellcheck 2017-12-04 20:31:28 +01:00
mhm@mhm.com
02104a318e delay added, text changed 2017-12-04 19:03:12 +01:00
mhm@mhm.com
28caddf3c1 delay added, text changed 2017-12-04 19:02:09 +01:00
Florian Bruhin
3a04de62ae Recompile requirements 2017-12-04 19:01:21 +01:00
François Chavant
86c37538d7 Simply search for shell scripts to search
Use 2 simpler find commands and redirect the output to a temporary
file.
2017-12-04 18:29:55 +01:00
François Chavant
4467f51e42 Use 'language: generic' for shellcheck, fix typo, correct indentation 2017-12-04 18:15:02 +01:00
Josefson Fraga
b6466b7410 revision 2 2017-12-04 13:08:56 -03:00
Florian Bruhin
6973a703c5 Add pluggy to requirements 2017-12-04 16:56:39 +01:00