-
Notifications
You must be signed in to change notification settings - Fork 14
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Invalid read syntax: "#" #28
Comments
Could you share a backtrace of the error occurring, please? |
|
|
Thanks, I'm a little busy, but I'll take a look when I have time. Your PR may be a good fix, but there may be a better way that would fix the issue more generally. |
Same issue here. Debugger entered--Lisp error: (invalid-read-syntax "#")
burly--frameset-restore(#s(url :type "emacs+burly+frames" :user nil :password nil :host nil :portspec nil :filename "?%5Bframeset%201%20%2824672%207294%20797875%200%29..." :target nil :attributes nil :fullness nil :silent nil :use-cookies t :asynchronous t))
burly-open-url("emacs+burly+frames:?%5Bframeset%201%20%2824672%207...")
burly-bookmark-handler(("Burly: test" (url . "emacs+burly+frames:?%5Bframeset%201%20%2824672%207...") (handler . burly-bookmark-handler)))
bookmark-handle-bookmark("Burly: test")
bookmark--jump-via("Burly: test" pop-to-buffer-same-window)
bookmark-jump("Burly: test")
burly-open-bookmark("Burly: test")
funcall-interactively(burly-open-bookmark "Burly: test")
#<subr command-execute>(burly-open-bookmark record nil nil)
ad-Advice-command-execute(#<subr command-execute> burly-open-bookmark record)
apply(ad-Advice-command-execute #<subr command-execute> (burly-open-bookmark record))
command-execute(burly-open-bookmark record)
counsel-M-x-action("burly-open-bookmark")
#f(compiled-function (x) #<bytecode 0x976502685a2fa82>)("burly-open-bookmark")
ivy-call()
#<subr ivy-read>("M-x " ("burly-open-bookmark" "burly-bookmark-frames" "kubel" "centaur-update" "transient-posframe-mode" "ivy-posframe-mode" "org-tree-slide-mode" "list-packages" "all-the-icons-insert" "list-processes" "copyit-file-pathname" "package-reinstall" "rainbow-mode" "customize-group" "eldoc-mode" "find-pdf-file" "centaur-find-pdf-file" "counsel-find-file" "calc" "esup" "centaur-update-packages" "hydra-ivy/ivy-call" "doom-modeline-mode" "tooltip-mode" "all-the-icons-ivy-rich-mode" "counsel-company" "company-box-mode" "toggle-debug-on-error" "lsp-update-server" "ivy-rich-mode" "lsp-install-server" "org-roam-server-mode" "lsp-pyright-format-buffer" "all-the-icons-ivy-rich-kill-buffer" "save-buffer-gbk-as-utf8" "display-battery-mode" "lsp-mode" "flycheck-posframe-mode" "describe-char" "checkdoc" "lsp-organize-imports" "org-capture" "org-toggle-link-display" "persp-mode" "all-the-icons-reset" "counsel-major" "package-install" "treemacs-load-theme" "grip-mode" "count-words" ...) :predicate counsel--M-x-externs-predicate :require-match t :history counsel-M-x-history :action counsel-M-x-action :keymap (keymap (67108908 . counsel--info-lookup-symbol) (67108910 . counsel-find-symbol)) :initial-input nil :caller counsel-M-x :sort t)
ivy-posframe--read(#<subr ivy-read> "M-x " ("burly-open-bookmark" "burly-bookmark-frames" "kubel" "centaur-update" "transient-posframe-mode" "ivy-posframe-mode" "org-tree-slide-mode" "list-packages" "all-the-icons-insert" "list-processes" "copyit-file-pathname" "package-reinstall" "rainbow-mode" "customize-group" "eldoc-mode" "find-pdf-file" "centaur-find-pdf-file" "counsel-find-file" "calc" "esup" "centaur-update-packages" "hydra-ivy/ivy-call" "doom-modeline-mode" "tooltip-mode" "all-the-icons-ivy-rich-mode" "counsel-company" "company-box-mode" "toggle-debug-on-error" "lsp-update-server" "ivy-rich-mode" "lsp-install-server" "org-roam-server-mode" "lsp-pyright-format-buffer" "all-the-icons-ivy-rich-kill-buffer" "save-buffer-gbk-as-utf8" "display-battery-mode" "lsp-mode" "flycheck-posframe-mode" "describe-char" "checkdoc" "lsp-organize-imports" "org-capture" "org-toggle-link-display" "persp-mode" "all-the-icons-reset" "counsel-major" "package-install" "treemacs-load-theme" "grip-mode" "count-words" ...) :predicate counsel--M-x-externs-predicate :require-match t :history counsel-M-x-history :action counsel-M-x-action :keymap (keymap (67108908 . counsel--info-lookup-symbol) (67108910 . counsel-find-symbol)) :initial-input nil :caller counsel-M-x :sort t)
apply(ivy-posframe--read #<subr ivy-read> ("M-x " ("burly-open-bookmark" "burly-bookmark-frames" "kubel" "centaur-update" "transient-posframe-mode" "ivy-posframe-mode" "org-tree-slide-mode" "list-packages" "all-the-icons-insert" "list-processes" "copyit-file-pathname" "package-reinstall" "rainbow-mode" "customize-group" "eldoc-mode" "find-pdf-file" "centaur-find-pdf-file" "counsel-find-file" "calc" "esup" "centaur-update-packages" "hydra-ivy/ivy-call" "doom-modeline-mode" "tooltip-mode" "all-the-icons-ivy-rich-mode" "counsel-company" "company-box-mode" "toggle-debug-on-error" "lsp-update-server" "ivy-rich-mode" "lsp-install-server" "org-roam-server-mode" "lsp-pyright-format-buffer" "all-the-icons-ivy-rich-kill-buffer" "save-buffer-gbk-as-utf8" "display-battery-mode" "lsp-mode" "flycheck-posframe-mode" "describe-char" "checkdoc" "lsp-organize-imports" "org-capture" "org-toggle-link-display" "persp-mode" "all-the-icons-reset" "counsel-major" "package-install" "treemacs-load-theme" "grip-mode" "count-words" ...) :predicate counsel--M-x-externs-predicate :require-match t :history counsel-M-x-history :action counsel-M-x-action :keymap (keymap (67108908 . counsel--info-lookup-symbol) (67108910 . counsel-find-symbol)) :initial-input nil :caller counsel-M-x :sort t))
#f(advice-wrapper :around #<subr ivy-read> ivy-posframe--read)("M-x " ("burly-open-bookmark" "burly-bookmark-frames" "kubel" "centaur-update" "transient-posframe-mode" "ivy-posframe-mode" "org-tree-slide-mode" "list-packages" "all-the-icons-insert" "list-processes" "copyit-file-pathname" "package-reinstall" "rainbow-mode" "customize-group" "eldoc-mode" "find-pdf-file" "centaur-find-pdf-file" "counsel-find-file" "calc" "esup" "centaur-update-packages" "hydra-ivy/ivy-call" "doom-modeline-mode" "tooltip-mode" "all-the-icons-ivy-rich-mode" "counsel-company" "company-box-mode" "toggle-debug-on-error" "lsp-update-server" "ivy-rich-mode" "lsp-install-server" "org-roam-server-mode" "lsp-pyright-format-buffer" "all-the-icons-ivy-rich-kill-buffer" "save-buffer-gbk-as-utf8" "display-battery-mode" "lsp-mode" "flycheck-posframe-mode" "describe-char" "checkdoc" "lsp-organize-imports" "org-capture" "org-toggle-link-display" "persp-mode" "all-the-icons-reset" "counsel-major" "package-install" "treemacs-load-theme" "grip-mode" "count-words" ...) :predicate counsel--M-x-externs-predicate :require-match t :history counsel-M-x-history :action counsel-M-x-action :keymap (keymap (67108908 . counsel--info-lookup-symbol) (67108910 . counsel-find-symbol)) :initial-input nil :caller counsel-M-x :sort t)
apply(#f(advice-wrapper :around #<subr ivy-read> ivy-posframe--read) ("M-x " ("burly-open-bookmark" "burly-bookmark-frames" "kubel" "centaur-update" "transient-posframe-mode" "ivy-posframe-mode" "org-tree-slide-mode" "list-packages" "all-the-icons-insert" "list-processes" "copyit-file-pathname" "package-reinstall" "rainbow-mode" "customize-group" "eldoc-mode" "find-pdf-file" "centaur-find-pdf-file" "counsel-find-file" "calc" "esup" "centaur-update-packages" "hydra-ivy/ivy-call" "doom-modeline-mode" "tooltip-mode" "all-the-icons-ivy-rich-mode" "counsel-company" "company-box-mode" "toggle-debug-on-error" "lsp-update-server" "ivy-rich-mode" "lsp-install-server" "org-roam-server-mode" "lsp-pyright-format-buffer" "all-the-icons-ivy-rich-kill-buffer" "save-buffer-gbk-as-utf8" "display-battery-mode" "lsp-mode" "flycheck-posframe-mode" "describe-char" "checkdoc" "lsp-organize-imports" "org-capture" "org-toggle-link-display" "persp-mode" "all-the-icons-reset" "counsel-major" "package-install" "treemacs-load-theme" "grip-mode" "count-words" ...) :predicate counsel--M-x-externs-predicate :require-match t :history counsel-M-x-history :action counsel-M-x-action :keymap (keymap (67108908 . counsel--info-lookup-symbol) (67108910 . counsel-find-symbol)) :initial-input nil :caller counsel-M-x :sort t))
ivy-read("M-x " ("burly-open-bookmark" "burly-bookmark-frames" "kubel" "centaur-update" "transient-posframe-mode" "ivy-posframe-mode" "org-tree-slide-mode" "list-packages" "all-the-icons-insert" "list-processes" "copyit-file-pathname" "package-reinstall" "rainbow-mode" "customize-group" "eldoc-mode" "find-pdf-file" "centaur-find-pdf-file" "counsel-find-file" "calc" "esup" "centaur-update-packages" "hydra-ivy/ivy-call" "doom-modeline-mode" "tooltip-mode" "all-the-icons-ivy-rich-mode" "counsel-company" "company-box-mode" "toggle-debug-on-error" "lsp-update-server" "ivy-rich-mode" "lsp-install-server" "org-roam-server-mode" "lsp-pyright-format-buffer" "all-the-icons-ivy-rich-kill-buffer" "save-buffer-gbk-as-utf8" "display-battery-mode" "lsp-mode" "flycheck-posframe-mode" "describe-char" "checkdoc" "lsp-organize-imports" "org-capture" "org-toggle-link-display" "persp-mode" "all-the-icons-reset" "counsel-major" "package-install" "treemacs-load-theme" "grip-mode" "count-words" ...) :predicate counsel--M-x-externs-predicate :require-match t :history counsel-M-x-history :action counsel-M-x-action :keymap (keymap (67108908 . counsel--info-lookup-symbol) (67108910 . counsel-find-symbol)) :initial-input nil :caller counsel-M-x)
counsel-M-x()
funcall-interactively(counsel-M-x)
#<subr command-execute>(counsel-M-x nil nil nil)
ad-Advice-command-execute(#<subr command-execute> counsel-M-x)
apply(ad-Advice-command-execute #<subr command-execute> counsel-M-x)
command-execute(counsel-M-x) |
@seagle0128 Are you also using posframe, like @tumashu is? |
@alphapapa Yes. I saw @tumashu fixed this in tumashu@8a94e91. |
@seagle0128 Thanks. Should |
I am posframe's maintainer, I think posframe should not be saved and restored, all posframes are only managed by posframe-show, |
@tumashu Thanks, I would tend to agree. Two questions, then:
|
for speed reason, most posframes only be hide, instead of delete, so it will be saved by burly |
posframe is a child-frame, so #24 seem to be a good idea |
Hi, I also see this error:
To my knowledge I don't use postframe so it could be a different error? |
You have to go deeper in the backtrace to find the culprit. When you check the (really) long line with the frameset in this comment you see in the middle this particular frame-local parameter:
It is when Burly tries to restore the |
This comment was marked as resolved.
This comment was marked as resolved.
It would be easier if you tried to get a smaller reproducing case instead of your real usage one I guess. Anyway, this comment still applies, it's not "posframe" that's the issue, the issue is that a variable with a The url encoding for |
Thanks for the hint. I used |
I can only reiterate that. Trying to maintain a list of known problematic cases isn't practical (and leads to frustration when the user goes to restore a bookmark and finds only then that it isn't going to work, on account of some previously-unknown case); what's necessary is to prevent such unreadable syntax being stored in bookmarks in the first place, so that the problem cannot occur. |
Hm, would it be feasible to try to read back the bookmark expression after generating it and catch the exception and convert it into a user friendly error, so the bookmark is not even stored and the user gets a hint about what might be causing the problem? This idea comes from a very vague understanding what's happening here, so it's likely not possible this way at all. |
Maybe we can use |
All, please try this branch and let me know if it fixes the problem: https://github.com/alphapapa/burly.el/compare/wip/readablep |
@TauPan @phil-s @tumashu @seagle0128 @sauvala @gagbo Please try this branch and let me know if it fixes the problem: https://github.com/alphapapa/burly.el/compare/wip/readablep If it does, I'll push it to master and make a new release. |
That seems to work, except... I managed to crash Emacs while I was testing, by running I don't believe the saved bookmark would have changed between tests, so I'm not sure what to make of that -- I haven't seen Emacs crash in a long time, but it's not obvious that it was anything to do with the issue at hand. Edit: And now I've reproduced it. Not consistently, but I've made Emacs 28.2 segfault twice now. I'll need to report this upstream... I can only presume something happening in |
@phil-s Thanks. That's very strange indeed. Please link the bug report here when you file it. Now I'm not sure what to do about this. I don't want to release code that could make Emacs crash, which is much worse than signaling an error. |
@phil-s Can you reproduce the crash on 29.1? |
Ah, my apologies, this fell completely off my radar. I stopped using burly once I realised that Ement.el's Notifications buffer enabled me to eliminate the use-case I'd had for wanting to bookmark and restore a complex arrangement of chat room buffers. I'll try to test it again sometime soon. Feel free to bug me about it if I forget again. |
I hope I'm not clouding the issue here but I'm seeing similar behavior though the way I'm getting there is a bit different. I have a bookmark set to open 2-window set with "elfeed-summary" and "ytdl-list" buffers. Here's the stack trace:
Out of curiosity I opened up ~/.emacs.d/bookmarks and the entry for "elfeed + downloads" has a ton of data in it and a lot of it it is probably wise to treat as private so I'm unable to share. I'm open to some debugging if it will help. thx |
@nrvale0 I guess you'll need to look at what data the Generally I would expect that the |
I will try each of them individually and report back. |
I think read will have problem when we have like (cursor-color . "#dcdccc")
The text was updated successfully, but these errors were encountered: