diff --git a/README.org b/README.org
index 5135cdc..6ff4a0f 100644
--- a/README.org
+++ b/README.org
@@ -1,7 +1,6 @@
#+TITLE: org-ql
# NOTE: Using =BEGIN_HTML= for this causes TeX/info export to fail, but this HTML block works.
-# #+HTML:
#+HTML:
# NOTE: To avoid having this in the info manual, we use HTML rather than Org syntax; it still appears with the GitHub renderer.
@@ -543,10 +542,21 @@ Simple links may also be written manually in either sexp or non-sexp form, like:
/Note:/ Breaking changes may be made before version 1.0, but in the event of major changes, attempts at backward compatibility will be made with obsolescence declarations, translation of arguments, etc. Users who need stability guarantees before 1.0 may choose to use tagged stable releases.
-** 0.7.1-pre
+** 0.7.2
+
+*Fixes*
++ Timestamp predicates are more tolerant of partial input (e.g. preventing errors while the user is typing a query into ~org-ql-find~).
++ Query parser ignores leading whitespace (e.g. preventing errors while the user is typing a query into ~org-ql-find~).
++ Use of ~org-ql-find~ with ~:query-prefix~ argument prevented selection of results. ([[https://github.com/alphapapa/org-ql/issues/351][#351]]. Thanks to [[https://github.com/danielfleischer][Daniel Fleischer]] for reporting.)
++ Handle narrowed buffers correctly in ~org-ql-find~.
++ Warn about empty headings in ~org-ql-completing-read~ (the Org format allows a heading line to have no text, but it's useless for this purpose, and usually indicates unnoticed corruption).
+
+** 0.7.1
*Fixes*
+ Function ~org-ql-completing-read~ is more compatible with default Emacs completion. (See [[https://github.com/alphapapa/org-ql/issues/338][#338]]. Thanks to [[https://github.com/arozbiz][arozbiz]] for reporting.)
++ Function ~org-ql-completing-read~ would sometimes stop updating with changes in input. (See [[https://github.com/alphapapa/org-ql/issues/350][#350]]. Thanks to [[https://github.com/anpandey][Ankit Raj Pandey]] for reporting and fixing, and to [[https://github.com/minad][Daniel Mendler]] for advising.)
++ In ~org-ql-completing-read~, format links for display, and use ~org-entry-get~ internally rather than ~org-get-heading~.
** 0.7
diff --git a/images/dont-tread-on-emacs-150.png b/images/dont-tread-on-emacs-150.png
deleted file mode 100644
index 71f3736..0000000
Binary files a/images/dont-tread-on-emacs-150.png and /dev/null differ
diff --git a/org-ql-completing-read.el b/org-ql-completing-read.el
index b72c8fa..0c4e70e 100644
--- a/org-ql-completing-read.el
+++ b/org-ql-completing-read.el
@@ -111,144 +111,151 @@ single predicate)."
(cl-labels (;; (debug-message
;; (f &rest args) (apply #'message (concat "ORG-QL-COMPLETING-READ: " f) args))
(action
- () (font-lock-ensure (point-at-bol) (point-at-eol))
- ;; FIXME: We want the fontified heading, and `org-heading-components' returns it
- ;; without properties, so we have to use `org-get-heading', which added additional
- ;; optional arguments in a certain Org version, so in those versions, it will
- ;; return priority cookies and comment strings.
- (let ((heading (org-get-heading t t)))
- (when (gethash heading table)
- ;; Disambiguate heading (even adding the path isn't enough, because that could
- ;; also be duplicated).
- (if-let ((suffix (gethash heading disambiguations)))
- (setf heading (format "%s <%s>" heading (cl-incf suffix)))
- (setf heading (format "%s <%s>" heading (puthash heading 2 disambiguations)))))
- (puthash heading (point-marker) table)))
+ () (font-lock-ensure (point-at-bol) (point-at-eol))
+ ;; FIXME: We want the fontified heading, and `org-heading-components' returns it
+ ;; without properties, so we have to use `org-get-heading', which added additional
+ ;; optional arguments in a certain Org version, so in those versions, it will
+ ;; return priority cookies and comment strings.
+ (let ((heading (org-link-display-format (org-entry-get (point) "ITEM"))))
+ (if (string-empty-p heading)
+ ;; A heading's string can be empty, but we can't use one because it
+ ;; wouldn't be useful to the user; and if one is found, it's very
+ ;; likely to indicate an unnoticed mistake or corruption in the
+ ;; file: so display a warning and don't record it as a candidate.
+ (warn "Empty heading at %S in %S" (point) (buffer-name))
+ (when (gethash heading table)
+ ;; Disambiguate heading (even adding the path isn't enough, because that could
+ ;; also be duplicated).
+ (if-let ((suffix (gethash heading disambiguations)))
+ (setf heading (format "%s <%s>" heading (cl-incf suffix)))
+ (setf heading (format "%s <%s>" heading (puthash heading 2 disambiguations)))))
+ (let ((marker (point-marker)))
+ (puthash (propertize heading 'org-marker marker) marker table)))))
(path (marker)
- (org-with-point-at marker
- (let* ((path (thread-first (org-get-outline-path nil t)
- (org-format-outline-path window-width nil "")
- (org-split-string "")))
- (formatted-path (if org-ql-completing-read-reverse-paths
- (concat "\\" (string-join (reverse path) "\\"))
- (concat "/" (string-join path "/")))))
- formatted-path)))
+ (org-with-point-at marker
+ (let* ((path (thread-first (org-get-outline-path nil t)
+ (org-format-outline-path window-width nil "")
+ (org-split-string "")))
+ (formatted-path (if org-ql-completing-read-reverse-paths
+ (concat "\\" (string-join (reverse path) "\\"))
+ (concat "/" (string-join path "/")))))
+ formatted-path)))
(todo
- (marker) (if-let (it (org-entry-get marker "TODO"))
- (concat (propertize it 'face (org-get-todo-face it)) " ")
- ""))
+ (marker) (if-let (it (org-entry-get marker "TODO"))
+ (concat (propertize it 'face (org-get-todo-face it)) " ")
+ ""))
(affix (completions)
- ;; (debug-message "AFFIX:%S" completions)
- (cl-loop for completion in completions
- for marker = (gethash completion table)
- for prefix = (todo marker)
- for suffix = (concat (path marker) " " (snippet marker))
- collect (list completion prefix suffix)))
+ ;; (debug-message "AFFIX:%S" completions)
+ (cl-loop for completion in completions
+ for marker = (get-text-property 0 'org-marker completion)
+ for prefix = (todo marker)
+ for suffix = (concat (path marker) " " (snippet marker))
+ collect (list completion prefix suffix)))
(annotate (candidate)
- ;; (debug-message "ANNOTATE:%S" candidate)
- (while-no-input
- ;; Using `while-no-input' here doesn't make it as responsive as,
- ;; e.g. Helm while typing, but it seems to help a little when using the
- ;; org-rifle-style snippets.
- (or (snippet (gethash candidate table)) "")))
+ ;; (debug-message "ANNOTATE:%S" candidate)
+ (while-no-input
+ ;; Using `while-no-input' here doesn't make it as responsive as,
+ ;; e.g. Helm while typing, but it seems to help a little when using the
+ ;; org-rifle-style snippets.
+ (or (snippet (get-text-property 0 'org-marker candidate)) "")))
(snippet
- (marker) (when-let
- ((snippet
- (org-with-point-at marker
- (or (funcall org-ql-completing-read-snippet-function snippet-regexp)
- (org-ql-completing-read--snippet-simple)))))
- (propertize (concat " " snippet)
- 'face 'org-ql-completing-read-snippet)))
+ (marker) (when-let
+ ((snippet
+ (org-with-point-at marker
+ (or (funcall org-ql-completing-read-snippet-function snippet-regexp)
+ (org-ql-completing-read--snippet-simple)))))
+ (propertize (concat " " snippet)
+ 'face 'org-ql-completing-read-snippet)))
(group (candidate transform)
- (pcase transform
- (`nil (buffer-name (marker-buffer (gethash candidate table))))
- (_ candidate)))
+ (pcase transform
+ (`nil (buffer-name (marker-buffer (get-text-property 0 'org-marker candidate))))
+ (_ candidate)))
(try (string _collection _pred point &optional _metadata)
- ;; (debug-message "TRY: STRING:%S" string)
- (cons string point))
+ ;; (debug-message "TRY: STRING:%S" string)
+ (cons string point))
(all (string table pred _point)
- ;; (debug-message "all: STRING:%S" string)
- ;; (debug-message "all-completions RETURNS: %S" (all-completions string table pred))
- (all-completions string table pred))
+ ;; (debug-message "all: STRING:%S" string)
+ ;; (debug-message "all-completions RETURNS: %S" (all-completions string table pred))
+ (all-completions string table pred))
(collection (input _pred flag)
- (when query-prefix
- (setf input (concat query-prefix input)))
- (pcase flag
- ('metadata (list 'metadata
- (cons 'group-function #'group)
- (cons 'affixation-function #'affix)
- (cons 'annotation-function #'annotate)))
- (`t
- ;; (debug-message "COLLECTION:t INPUT:%S KEYS:%S"
- ;; input (hash-table-keys table))
- ;; It's not ideal to call `run-query' unconditionally here, but due to
- ;; the complexity of the "Programmed Completion" API, it's basically
- ;; necessary, and org-ql's caching should make it nearly free.
- (run-query input)
- (hash-table-keys table))
- ('lambda
- ;; (debug-message "COLLECTION:lambda INPUT:%S KEYS:%S"
- ;; input (hash-table-keys table))
- (if (not (hash-table-empty-p table))
- (when (gethash input table)
- t)
- (run-query input)
- (when (gethash input table)
- ;; (debug-message "COLLECTION:lambda INPUT:%S FOUND" input)
- t)))
- (`nil
- ;; (debug-message "COLLECTION:nil INPUT:%S" input)
- (if (not (hash-table-empty-p table))
- (when (gethash input table)
- t)
- (run-query input)
- ;; (debug-message "COLLECTION:nil INPUT:%S KEYS:%S"
- ;; input (hash-table-keys table))
- (cond ((hash-table-empty-p table)
- nil)
- ((gethash input table)
- t)
- (t
- ;; FIXME: "it should return the longest common prefix
- ;; substring of all matches otherwise"...but there's no
- ;; function to compute that? At least returning an empty
- ;; string doesn't seem to break anything.
- input))))
- (`(boundaries . ,suffix)
- ;; (debug-message "COLLECTION:boundaries INPUT:%S SUFFIX:%S KEYS:%S"
- ;; input suffix (hash-table-keys table))
- ;; FIXME: This is unlikely to be correct, but I'm not even sure if it
- ;; can be correct in this case since the input (e.g. "todo: foo")
- ;; usually won't match a completion candidate directly.
- `(boundaries 0 . ,(length suffix)))))
+ (pcase flag
+ ('metadata (list 'metadata
+ (cons 'group-function #'group)
+ (cons 'affixation-function #'affix)
+ (cons 'annotation-function #'annotate)))
+ (`t
+ ;; (debug-message "COLLECTION:t INPUT:%S KEYS:%S"
+ ;; input (hash-table-keys table))
+ ;; It's not ideal to call `run-query' unconditionally here, but due to
+ ;; the complexity of the "Programmed Completion" API, it's basically
+ ;; necessary, and org-ql's caching should make it nearly free.
+ (run-query input)
+ (hash-table-keys table))
+ ('lambda
+ ;; (debug-message "COLLECTION:lambda INPUT:%S KEYS:%S"
+ ;; input (hash-table-keys table))
+ (if (not (hash-table-empty-p table))
+ (when (gethash input table)
+ t)
+ (run-query input)
+ (when (gethash input table)
+ ;; (debug-message "COLLECTION:lambda INPUT:%S FOUND" input)
+ t)))
+ (`nil
+ ;; (debug-message "COLLECTION:nil INPUT:%S" input)
+ (if (not (hash-table-empty-p table))
+ (when (gethash input table)
+ t)
+ (run-query input)
+ ;; (debug-message "COLLECTION:nil INPUT:%S KEYS:%S"
+ ;; input (hash-table-keys table))
+ (cond ((hash-table-empty-p table)
+ nil)
+ ((gethash input table)
+ t)
+ (t
+ ;; FIXME: "it should return the longest common prefix
+ ;; substring of all matches otherwise"...but there's no
+ ;; function to compute that? At least returning an empty
+ ;; string doesn't seem to break anything.
+ input))))
+ (`(boundaries . ,suffix)
+ ;; (debug-message "COLLECTION:boundaries INPUT:%S SUFFIX:%S KEYS:%S"
+ ;; input suffix (hash-table-keys table))
+ ;; FIXME: This is unlikely to be correct, but I'm not even sure if it
+ ;; can be correct in this case since the input (e.g. "todo: foo")
+ ;; usually won't match a completion candidate directly.
+ `(boundaries 0 . ,(length suffix)))))
(run-query (input)
- ;; (debug-message "RUN-QUERY:%S" input)
- (unless (or (string-empty-p input)
- (equal last-input input))
- ;; (debug-message "RUN-QUERY:%S RUNNING" input)
- (setf last-input input)
- ;; Clear hash table each time the user changes the input.
- (clrhash table)
- (clrhash disambiguations)
- (when query-filter
- (setf input (funcall query-filter input)))
- (pcase org-ql-completing-read-snippet-function
- ('org-ql-completing-read--snippet-regexp
- (setf query-tokens
- ;; Remove any tokens that specify predicates or are too short.
- (--select (not (or (string-match-p (rx bos (1+ (not (any ":"))) ":") it)
- (< (length it) org-ql-completing-read-snippet-minimum-token-length)))
- (split-string input nil t (rx space)))
- snippet-regexp
- (when query-tokens
- ;; Limiting each context word to 15 characters prevents
- ;; excessively long, non-word strings from ending up in
- ;; snippets, which can adversely affect performance.
- (rx-to-string `(seq (optional (repeat 1 3 (repeat 1 15 (not space)) (0+ space)))
- bow (or ,@query-tokens) (0+ (not space))
- (optional (repeat 1 3 (0+ space) (repeat 1 15 (not space))))))))))
- (org-ql-select buffers-files (org-ql--query-string-to-sexp input)
- :action #'action))))
+ ;; (debug-message "RUN-QUERY:%S" input)
+ (when query-prefix
+ (setf input (concat query-prefix input)))
+ (unless (or (string-empty-p input)
+ (equal last-input input))
+ ;; (debug-message "RUN-QUERY:%S RUNNING" input)
+ (setf last-input input)
+ ;; Clear hash table each time the user changes the input.
+ (clrhash table)
+ (clrhash disambiguations)
+ (when query-filter
+ (setf input (funcall query-filter input)))
+ (pcase org-ql-completing-read-snippet-function
+ ('org-ql-completing-read--snippet-regexp
+ (setf query-tokens
+ ;; Remove any tokens that specify predicates or are too short.
+ (--select (not (or (string-match-p (rx bos (1+ (not (any ":"))) ":") it)
+ (< (length it) org-ql-completing-read-snippet-minimum-token-length)))
+ (split-string input nil t (rx space)))
+ snippet-regexp
+ (when query-tokens
+ ;; Limiting each context word to 15 characters prevents
+ ;; excessively long, non-word strings from ending up in
+ ;; snippets, which can adversely affect performance.
+ (rx-to-string `(seq (optional (repeat 1 3 (repeat 1 15 (not space)) (0+ space)))
+ bow (or ,@query-tokens) (0+ (not space))
+ (optional (repeat 1 3 (0+ space) (repeat 1 15 (not space))))))))))
+ (org-ql-select buffers-files (org-ql--query-string-to-sexp input)
+ :action #'action))))
;; NOTE: It seems that the `completing-read' machinery can call, abort, and re-call the
;; collection function while the user is typing, which can interrupt the machinery Org uses to
;; prepare an Org buffer when an Org file is loaded. This results in, e.g. the buffer being
diff --git a/org-ql-find.el b/org-ql-find.el
index 9483c61..dd9fea9 100644
--- a/org-ql-find.el
+++ b/org-ql-find.el
@@ -83,8 +83,7 @@ single predicate)."
:query-prefix query-prefix
:query-filter query-filter
:prompt prompt)))
- (with-current-buffer (marker-buffer marker)
- (goto-char marker)
+ (org-with-point-at marker
(display-buffer (current-buffer) org-ql-find-display-buffer-action)
(select-window (get-buffer-window (current-buffer)))
(run-hook-with-args 'org-ql-find-goto-hook))))
diff --git a/org-ql.el b/org-ql.el
index 40ad7e8..0980908 100644
--- a/org-ql.el
+++ b/org-ql.el
@@ -4,7 +4,7 @@
;; Author: Adam Porter
;; Url: https://github.com/alphapapa/org-ql
-;; Version: 0.7.1-pre
+;; Version: 0.7.2
;; Package-Requires: ((emacs "26.1") (dash "2.18.1") (f "0.17.2") (map "2.1") (org "9.0") (org-super-agenda "1.2") (ov "1.0.6") (peg "1.0.1") (s "1.12.0") (transient "0.1") (ts "0.2-pre"))
;; Keywords: hypermedia, outlines, Org, agenda
@@ -76,6 +76,7 @@ Tags are stored in match group 1. Match group 2 stores the tags
without the enclosing colons.")
(defvaralias 'org-ql-link-regexp
+ ;; FIXME: `org-link-bracket-re' is void until `org-link-make-regexps' is called.
(if (bound-and-true-p org-link-bracket-re)
'org-link-bracket-re
'org-bracket-link-regexp)
@@ -944,7 +945,7 @@ value of `org-ql-predicates')."
;; obscure bug in `peg': when one keyword is a substring of another,
;; and the shorter one is listed first, the shorter one fails to match.
(-sort (-on #'> #'length))))
- (pexs `((query (+ (and term (* [blank]))))
+ (pexs `((query (and (* [blank]) (+ (and term (* [blank])))))
(term (or (and negation (list positive-term)
;; This is a bit confusing, but it seems to work. There's probably a better way.
`(pred -- (list 'not (car pred))))
@@ -1285,6 +1286,9 @@ result form."
to on))
(when from
(setq from (pcase from
+ ("-"
+ ;; Ignore, because it means the user is typing a negative number.
+ nil)
((or 'today "today") (->> (ts-now)
(ts-apply :hour 0 :minute 0 :second 0)))
((pred numberp) (->> (ts-now)
@@ -1301,6 +1305,9 @@ result form."
((pred ts-p) from))))
(when to
(setq to (pcase to
+ ("-"
+ ;; Ignore, because it means the user is typing a negative number.
+ nil)
((or 'today "today") (->> (ts-now)
(ts-apply :hour 23 :minute 59 :second 59)))
((pred numberp) (->> (ts-now)
diff --git a/org-ql.info b/org-ql.info
index 7998193..c1e5e13 100644
--- a/org-ql.info
+++ b/org-ql.info
@@ -1,4 +1,4 @@
-This is README.info, produced by makeinfo version 5.2 from README.texi.
+This is README.info, produced by makeinfo version 6.7 from README.texi.
INFO-DIR-SECTION Emacs
START-INFO-DIR-ENTRY
@@ -71,33 +71,34 @@ Functions / Macros
Changelog
-* 0.7.1-pre: 071-pre.
-* 0.7: 07.
-* 0.6.3: 063.
-* 0.6.2: 062.
-* 0.6.1: 061.
-* 0.6: 06.
-* 0.5.2: 052.
-* 0.5.1: 051.
-* 0.5: 05.
-* 0.4.9: 049.
-* 0.4.8: 048.
-* 0.4.7: 047.
-* 0.4.6: 046.
-* 0.4.5: 045.
-* 0.4.4: 044.
-* 0.4.3: 043.
-* 0.4.2: 042.
-* 0.4.1: 041.
-* 0.4: 04.
-* 0.3.2: 032.
-* 0.3.1: 031.
-* 0.3: 03.
-* 0.2.3: 023.
-* 0.2.2: 022.
-* 0.2.1: 021.
-* 0.2: 02.
-* 0.1: 01.
+* 0.7.2: 072.
+* 0.7.1: 071.
+* 0.7: 07.
+* 0.6.3: 063.
+* 0.6.2: 062.
+* 0.6.1: 061.
+* 0.6: 06.
+* 0.5.2: 052.
+* 0.5.1: 051.
+* 0.5: 05.
+* 0.4.9: 049.
+* 0.4.8: 048.
+* 0.4.7: 047.
+* 0.4.6: 046.
+* 0.4.5: 045.
+* 0.4.4: 044.
+* 0.4.3: 043.
+* 0.4.2: 042.
+* 0.4.1: 041.
+* 0.4: 04.
+* 0.3.2: 032.
+* 0.3.1: 031.
+* 0.3: 03.
+* 0.2.3: 023.
+* 0.2.2: 022.
+* 0.2.1: 021.
+* 0.2: 02.
+* 0.1: 01.
Notes
@@ -991,50 +992,79 @@ releases.
* Menu:
-* 0.7.1-pre: 071-pre.
-* 0.7: 07.
-* 0.6.3: 063.
-* 0.6.2: 062.
-* 0.6.1: 061.
-* 0.6: 06.
-* 0.5.2: 052.
-* 0.5.1: 051.
-* 0.5: 05.
-* 0.4.9: 049.
-* 0.4.8: 048.
-* 0.4.7: 047.
-* 0.4.6: 046.
-* 0.4.5: 045.
-* 0.4.4: 044.
-* 0.4.3: 043.
-* 0.4.2: 042.
-* 0.4.1: 041.
-* 0.4: 04.
-* 0.3.2: 032.
-* 0.3.1: 031.
-* 0.3: 03.
-* 0.2.3: 023.
-* 0.2.2: 022.
-* 0.2.1: 021.
-* 0.2: 02.
-* 0.1: 01.
+* 0.7.2: 072.
+* 0.7.1: 071.
+* 0.7: 07.
+* 0.6.3: 063.
+* 0.6.2: 062.
+* 0.6.1: 061.
+* 0.6: 06.
+* 0.5.2: 052.
+* 0.5.1: 051.
+* 0.5: 05.
+* 0.4.9: 049.
+* 0.4.8: 048.
+* 0.4.7: 047.
+* 0.4.6: 046.
+* 0.4.5: 045.
+* 0.4.4: 044.
+* 0.4.3: 043.
+* 0.4.2: 042.
+* 0.4.1: 041.
+* 0.4: 04.
+* 0.3.2: 032.
+* 0.3.1: 031.
+* 0.3: 03.
+* 0.2.3: 023.
+* 0.2.2: 022.
+* 0.2.1: 021.
+* 0.2: 02.
+* 0.1: 01.
-File: README.info, Node: 071-pre, Next: 07, Up: Changelog
+File: README.info, Node: 072, Next: 071, Up: Changelog
-5.1 0.7.1-pre
-=============
+5.1 0.7.2
+=========
+
+*Fixes*
+ • Timestamp predicates are more tolerant of partial input (e.g.
+ preventing errors while the user is typing a query into
+ ‘org-ql-find’).
+ • Query parser ignores leading whitespace (e.g. preventing errors
+ while the user is typing a query into ‘org-ql-find’).
+ • Use of ‘org-ql-find’ with ‘:query-prefix’ argument prevented
+ selection of results. (#351
+ (https://github.com/alphapapa/org-ql/issues/351). Thanks to Daniel
+ Fleischer (https://github.com/danielfleischer) for reporting.)
+ • Handle narrowed buffers correctly in ‘org-ql-find’.
+ • Warn about empty headings in ‘org-ql-completing-read’ (the Org
+ format allows a heading line to have no text, but it’s useless for
+ this purpose, and usually indicates unnoticed corruption).
+
+
+File: README.info, Node: 071, Next: 07, Prev: 072, Up: Changelog
+
+5.2 0.7.1
+=========
*Fixes*
• Function ‘org-ql-completing-read’ is more compatible with default
Emacs completion. (See #338
(https://github.com/alphapapa/org-ql/issues/338). Thanks to
arozbiz (https://github.com/arozbiz) for reporting.)
+ • Function ‘org-ql-completing-read’ would sometimes stop updating
+ with changes in input. (See #350
+ (https://github.com/alphapapa/org-ql/issues/350). Thanks to Ankit
+ Raj Pandey (https://github.com/anpandey) for reporting and fixing,
+ and to Daniel Mendler (https://github.com/minad) for advising.)
+ • In ‘org-ql-completing-read’, format links for display, and use
+ ‘org-entry-get’ internally rather than ‘org-get-heading’.
-File: README.info, Node: 07, Next: 063, Prev: 071-pre, Up: Changelog
+File: README.info, Node: 07, Next: 063, Prev: 071, Up: Changelog
-5.2 0.7
+5.3 0.7
=======
*Added*
@@ -1094,7 +1124,7 @@ File: README.info, Node: 07, Next: 063, Prev: 071-pre, Up: Changelog
File: README.info, Node: 063, Next: 062, Prev: 07, Up: Changelog
-5.3 0.6.3
+5.4 0.6.3
=========
*Fixed*
@@ -1110,7 +1140,7 @@ File: README.info, Node: 063, Next: 062, Prev: 07, Up: Changelog
File: README.info, Node: 062, Next: 061, Prev: 063, Up: Changelog
-5.4 0.6.2
+5.5 0.6.2
=========
*Fixed*
@@ -1121,7 +1151,7 @@ File: README.info, Node: 062, Next: 061, Prev: 063, Up: Changelog
File: README.info, Node: 061, Next: 06, Prev: 062, Up: Changelog
-5.5 0.6.1
+5.6 0.6.1
=========
*Fixed*
@@ -1139,7 +1169,7 @@ File: README.info, Node: 061, Next: 06, Prev: 062, Up: Changelog
File: README.info, Node: 06, Next: 052, Prev: 061, Up: Changelog
-5.6 0.6
+5.7 0.6
=======
*Added*
@@ -1206,7 +1236,7 @@ File: README.info, Node: 06, Next: 052, Prev: 061, Up: Changelog
File: README.info, Node: 052, Next: 051, Prev: 06, Up: Changelog
-5.7 0.5.2
+5.8 0.5.2
=========
*Fixed*
@@ -1217,7 +1247,7 @@ File: README.info, Node: 052, Next: 051, Prev: 06, Up: Changelog
File: README.info, Node: 051, Next: 05, Prev: 052, Up: Changelog
-5.8 0.5.1
+5.9 0.5.1
=========
*Fixed*
@@ -1230,8 +1260,8 @@ File: README.info, Node: 051, Next: 05, Prev: 052, Up: Changelog
File: README.info, Node: 05, Next: 049, Prev: 051, Up: Changelog
-5.9 0.5
-=======
+5.10 0.5
+========
*Added*
• View dispatcher using ‘transient.el’ (like Magit), bound to ‘v’ in
@@ -1271,7 +1301,7 @@ File: README.info, Node: 05, Next: 049, Prev: 051, Up: Changelog
File: README.info, Node: 049, Next: 048, Prev: 05, Up: Changelog
-5.10 0.4.9
+5.11 0.4.9
==========
*Fixed*
@@ -1282,7 +1312,7 @@ File: README.info, Node: 049, Next: 048, Prev: 05, Up: Changelog
File: README.info, Node: 048, Next: 047, Prev: 049, Up: Changelog
-5.11 0.4.8
+5.12 0.4.8
==========
*Fixed*
@@ -1294,7 +1324,7 @@ File: README.info, Node: 048, Next: 047, Prev: 049, Up: Changelog
File: README.info, Node: 047, Next: 046, Prev: 048, Up: Changelog
-5.12 0.4.7
+5.13 0.4.7
==========
*Fixed*
@@ -1307,7 +1337,7 @@ File: README.info, Node: 047, Next: 046, Prev: 048, Up: Changelog
File: README.info, Node: 046, Next: 045, Prev: 047, Up: Changelog
-5.13 0.4.6
+5.14 0.4.6
==========
*Fixed*
@@ -1320,7 +1350,7 @@ File: README.info, Node: 046, Next: 045, Prev: 047, Up: Changelog
File: README.info, Node: 045, Next: 044, Prev: 046, Up: Changelog
-5.14 0.4.5
+5.15 0.4.5
==========
*Fixed*
@@ -1332,7 +1362,7 @@ File: README.info, Node: 045, Next: 044, Prev: 046, Up: Changelog
File: README.info, Node: 044, Next: 043, Prev: 045, Up: Changelog
-5.15 0.4.4
+5.16 0.4.4
==========
*Fixed*
@@ -1344,7 +1374,7 @@ File: README.info, Node: 044, Next: 043, Prev: 045, Up: Changelog
File: README.info, Node: 043, Next: 042, Prev: 044, Up: Changelog
-5.16 0.4.3
+5.17 0.4.3
==========
*Fixed*
@@ -1354,7 +1384,7 @@ File: README.info, Node: 043, Next: 042, Prev: 044, Up: Changelog
File: README.info, Node: 042, Next: 041, Prev: 043, Up: Changelog
-5.17 0.4.2
+5.18 0.4.2
==========
*Fixed*
@@ -1363,7 +1393,7 @@ File: README.info, Node: 042, Next: 041, Prev: 043, Up: Changelog
File: README.info, Node: 041, Next: 04, Prev: 042, Up: Changelog
-5.18 0.4.1
+5.19 0.4.1
==========
*Fixed*
@@ -1373,7 +1403,7 @@ File: README.info, Node: 041, Next: 04, Prev: 042, Up: Changelog
File: README.info, Node: 04, Next: 032, Prev: 041, Up: Changelog
-5.19 0.4
+5.20 0.4
========
_Note:_ The next release, 0.5, may include changes which will require
@@ -1454,7 +1484,7 @@ automatically, as they will be pushed to the ‘master’ branch when ready.
File: README.info, Node: 032, Next: 031, Prev: 04, Up: Changelog
-5.20 0.3.2
+5.21 0.3.2
==========
*Fixed*
@@ -1467,7 +1497,7 @@ File: README.info, Node: 032, Next: 031, Prev: 04, Up: Changelog
File: README.info, Node: 031, Next: 03, Prev: 032, Up: Changelog
-5.21 0.3.1
+5.22 0.3.1
==========
*Fixed*
@@ -1477,7 +1507,7 @@ File: README.info, Node: 031, Next: 03, Prev: 032, Up: Changelog
File: README.info, Node: 03, Next: 023, Prev: 031, Up: Changelog
-5.22 0.3
+5.23 0.3
========
*Added*
@@ -1545,7 +1575,7 @@ File: README.info, Node: 03, Next: 023, Prev: 031, Up: Changelog
File: README.info, Node: 023, Next: 022, Prev: 03, Up: Changelog
-5.23 0.2.3
+5.24 0.2.3
==========
*Fixed*
@@ -1555,7 +1585,7 @@ File: README.info, Node: 023, Next: 022, Prev: 03, Up: Changelog
File: README.info, Node: 022, Next: 021, Prev: 023, Up: Changelog
-5.24 0.2.2
+5.25 0.2.2
==========
*Fixed*
@@ -1566,7 +1596,7 @@ File: README.info, Node: 022, Next: 021, Prev: 023, Up: Changelog
File: README.info, Node: 021, Next: 02, Prev: 022, Up: Changelog
-5.25 0.2.1
+5.26 0.2.1
==========
*Fixed*
@@ -1576,7 +1606,7 @@ File: README.info, Node: 021, Next: 02, Prev: 022, Up: Changelog
File: README.info, Node: 02, Next: 01, Prev: 021, Up: Changelog
-5.26 0.2
+5.27 0.2
========
*Added*
@@ -1659,7 +1689,7 @@ File: README.info, Node: 02, Next: 01, Prev: 021, Up: Changelog
File: README.info, Node: 01, Prev: 02, Up: Changelog
-5.27 0.1
+5.28 0.1
========
First tagged release.
@@ -1717,71 +1747,72 @@ GPLv3
Tag Table:
Node: Top225
-Node: Contents1812
-Node: Screenshots1935
-Node: Installation2053
-Node: Quelpa2567
-Node: Helm support3095
-Node: Usage3498
-Node: Commands3896
-Node: org-ql-find4340
-Node: org-ql-refile4806
-Node: org-ql-search5129
-Node: helm-org-ql6825
-Node: org-ql-view7203
-Node: org-ql-view-sidebar7733
-Node: org-ql-view-recent-items8113
-Node: org-ql-sparse-tree8609
-Node: Queries9409
-Node: Non-sexp query syntax10526
-Node: General predicates12285
-Node: Ancestor/descendant predicates19272
-Node: Date/time predicates20400
-Node: Functions / Macros23524
-Node: Agenda-like views23822
-Ref: Function ‘org-ql-block’23984
-Node: Listing / acting-on results25245
-Ref: Caching25453
-Ref: Function ‘org-ql-select’26366
-Ref: Function ‘org-ql-query’28792
-Ref: Macro ‘org-ql’ (deprecated)30566
-Node: Custom predicates30881
-Ref: Macro ‘org-ql-defpred’31105
-Node: Dynamic block34546
-Node: Links37270
-Node: Tips37957
-Node: Changelog38281
-Node: 071-pre39079
-Node: 0739416
-Node: 06342344
-Node: 06242875
-Node: 06143180
-Node: 0643748
-Node: 05246802
-Node: 05147102
-Node: 0547525
-Node: 04949054
-Node: 04849336
-Node: 04749685
-Node: 04650094
-Node: 04550502
-Node: 04450863
-Node: 04351222
-Node: 04251425
-Node: 04151586
-Node: 0451833
-Node: 03255934
-Node: 03156337
-Node: 0356534
-Node: 02359834
-Node: 02260068
-Node: 02160348
-Node: 0260553
-Node: 0164631
-Node: Notes64732
-Node: Comparison with Org Agenda searches64894
-Node: org-sidebar65783
-Node: License66062
+Node: Contents1791
+Node: Screenshots1914
+Node: Installation2032
+Node: Quelpa2546
+Node: Helm support3074
+Node: Usage3477
+Node: Commands3875
+Node: org-ql-find4319
+Node: org-ql-refile4785
+Node: org-ql-search5108
+Node: helm-org-ql6804
+Node: org-ql-view7182
+Node: org-ql-view-sidebar7712
+Node: org-ql-view-recent-items8092
+Node: org-ql-sparse-tree8588
+Node: Queries9388
+Node: Non-sexp query syntax10505
+Node: General predicates12264
+Node: Ancestor/descendant predicates19251
+Node: Date/time predicates20379
+Node: Functions / Macros23503
+Node: Agenda-like views23801
+Ref: Function org-ql-block23963
+Node: Listing / acting-on results25224
+Ref: Caching25432
+Ref: Function org-ql-select26345
+Ref: Function org-ql-query28771
+Ref: Macro org-ql (deprecated)30545
+Node: Custom predicates30860
+Ref: Macro org-ql-defpred31084
+Node: Dynamic block34525
+Node: Links37249
+Node: Tips37936
+Node: Changelog38260
+Node: 07239037
+Node: 07139944
+Node: 0740753
+Node: 06343677
+Node: 06244208
+Node: 06144513
+Node: 0645081
+Node: 05248135
+Node: 05148435
+Node: 0548858
+Node: 04950389
+Node: 04850671
+Node: 04751020
+Node: 04651429
+Node: 04551837
+Node: 04452198
+Node: 04352557
+Node: 04252760
+Node: 04152921
+Node: 0453168
+Node: 03257269
+Node: 03157672
+Node: 0357869
+Node: 02361169
+Node: 02261403
+Node: 02161683
+Node: 0261888
+Node: 0165966
+Node: Notes66067
+Node: Comparison with Org Agenda searches66229
+Node: org-sidebar67118
+Node: License67397
End Tag Table
diff --git a/tests/test-org-ql.el b/tests/test-org-ql.el
index 5f9463f..9008179 100644
--- a/tests/test-org-ql.el
+++ b/tests/test-org-ql.el
@@ -33,6 +33,8 @@
(require 'org-ql-search)
(require 'org-ql-view)
+(require 'xr)
+
;;;; Variables
(defvar org-ql-test-buffer nil