Open lebensterben opened 1 year ago
Hi!
Very interestingly:
Indeed, this is a fascinating error. It would seem that the ...
elisions in an error message are being evaluated. The string ...
occurs nowhere in the unicode-fonts
repo.
For example, zeroing in on this snippet:
(defvar use-package--warning379 #'(lambda (keyword err) (let ((msg (format "%s/%s: %s" ... keyword ...))) (display-warning 'use-package msg :error))))
try this:
ESC : (format "%s/%s: %s" ... keyword ...)
RET
to duplicate the error
(void-variable \.\.\.)
I realize the version of Emacs did not change recently, but what version is it?
It's Emacs 28.1.
Scrolling to the right I now notice the \.\.\.
as an argument to set-fontest-font
.
(progn (set-fontset-font "fontset-default" nil (font-spec :name "Symbola:" :registry "iso10646-1")) (set-fontset-font "fontset-default" nil (font-spec :name "Quivira:" :registry "iso10646-1") nil 'append) (set-fontset-font "fontset-default" '(65792 . 65855) (font-spec :name "Noto Sans Symbols:" :registry "iso10646-1")) (set-fontset-font "fontset-default" '(65792 . 65855) (font-spec :name "Symbola:" :registry "iso10646-1") nil 'append) (set-fontset-font "fontset-default" '(65792 . 65855) (font-spec :name "Quivira:" :registry "iso10646-1") nil 'append) (set-fontset-font "fontset-default" '(128768 . 128895) (font-spec :name "Noto Sans Symbols:" :registry "iso10646-1")) (set-fontset-font "fontset-default" '(128768 . 128895) (font-spec :name "Symbola:" :registry "iso10646-1") nil 'append) (set-fontset-font "fontset-default" '(128768 . 128895) (font-spec :name "Quivira:" :registry "iso10646-1") nil 'append) (set-fontset-font "fontset-default" '(64256 . 64335) (font-spec :name "DejaVu Sans:width=condensed:" :registry "iso10646-1")) \.\.\.)
28.1 makes sense because I have a hazy suspicion this is an interaction with native compilation.
Couple of things that would be interesting to do. If you have rg
installed it would be simple to search for the \.\.\.
string in your ~/.emacs.d
directory:
cd ~/.emacs.d
rg -l '\\\.\\\.\\\.'
And you might also try turning off unicode-fonts-use-persistent-storage
in customize as a test. That makes startup slower. But the cache may be where the \.\.\.
are hiding.
@rolandwalker
Inside ~/.emacs.d/elpa,
𝛌> rg '\\\.\\\.\\\.'
28.1/develop/rtags-20211101.2149/rtags.el
3328: ((string-match "\.\.\." str)
28.1/develop/web-mode-20220810.1453/web-mode.el
6992: (when (and (eq (get-text-property exp-beg 'tag-attr-beg) 4) (web-mode-looking-at-p "\.\.\." (1+ exp-beg)))
The problem seems to has disappeared after I rebooted my system...
I also have this issue. The variable unicode-fonts--instructions
contains these \...
symbols.
unicode-fonts--instructions is a variable defined in unicode-fonts.el.
Value
(("fontset-default"
(set-fontset-font "fontset-default" nil
(font-spec :name "Symbola:" :registry "iso10646-1"))
(set-fontset-font "fontset-default"
'(65792 . 65855)
(font-spec :name "Symbola:" :registry "iso10646-1"))
(set-fontset-font "fontset-default"
'(128768 . 128895)
(font-spec :name "Symbola:" :registry "iso10646-1"))
(set-fontset-font "fontset-default"
'(64256 . 64335)
(font-spec :name "Arial Unicode MS:" :registry "iso10646-1"))
(set-fontset-font "fontset-default"
'(119296 . 119375)
(font-spec :name "Symbola:" :registry "iso10646-1"))
(set-fontset-font "fontset-default"
'(65856 . 65935)
(font-spec :name "Apple Symbols:" :registry "iso10646-1"))
(set-fontset-font "fontset-default"
'(65856 . 65935)
(font-spec :name "Symbola:" :registry "iso10646-1")
nil 'append)
(set-fontset-font "fontset-default"
'(65936 . 65999)
(font-spec :name "Symbola:" :registry "iso10646-1"))
(set-fontset-font "fontset-default"
'(1536 . 1791)
(font-spec :name "Courier New:" :registry "iso10646-1"))
\...))
Set
Documentation
Alist of code to set up fonts on a given system.
References
unicode-fonts--instructions is unused in unicode-fonts.el.
Find all references
Debugging
Forget
Source Code
;; Defined in ~/.emacs.d/.local/straight/repos/unicode-fonts/unicode-fonts.el
(defvar unicode-fonts--instructions nil "Alist of code to set up fonts on a given system.")
Symbol Properties
variable-documentation
"Alist of code to set up fonts on a given system."
See also https://github.com/doomemacs/doomemacs/issues/5671 .
I have it in this file .local/cache/pcache/unicode-fonts
:
.local/cache/pcache/unicode-fonts
7: :entries #s(hash-table size 65 test eql rehash-size 1.5 rehash-threshold 0.8125 data (checksum-f:fontset-default-w:ns-h:localhost-e:29.0.50-l:0.4.10 (pcache-entry "pcache-entry-599fe2b2" :timestamp 1669643622.72101 :ttl 7776000 :value "7f0bc2b84f32ccb156aefa6eb2d42164") instructions-f:fontset-default-w:ns-h:localhost-e:29.0.50-l:0.4.10 (pcache-entry "pcache-entry-599fe2ca" :timestamp 1669643622.723952 :ttl 7776000 :value '("fontset-default" (set-fontset-font "fontset-default" nil (font-spec :name "Symbola:" :registry "iso10646-1")) (set-fontset-font "fontset-default" '(65792 . 65855) (font-spec :name "Symbola:" :registry "iso10646-1")) (set-fontset-font "fontset-default" '(128768 . 128895) (font-spec :name "Symbola:" :registry "iso10646-1")) (set-fontset-font "fontset-default" '(64256 . 64335) (font-spec :name "Arial Unicode MS:" :registry "iso10646-1")) (set-fontset-font "fontset-default" '(119296 . 119375) (font-spec :name "Symbola:" :registry "iso10646-1")) (set-fontset-font "fontset-default" '(65856 . 65935) (font-spec :name "Apple Symbols:" :registry "iso10646-1")) (set-fontset-font "fontset-default" '(65856 . 65935) (font-spec :name "Symbola:" :registry "iso10646-1") nil 'append) (set-fontset-font "fontset-default" '(65936 . 65999) (font-spec :name "Symbola:" :registry "iso10646-1")) (set-fontset-font "fontset-default" '(1536 . 1791) (font-spec :name "Courier New:" :registry "iso10646-1")) \...)) checksum-f:fontset-startup-w:ns-h:localhost-e:29.0.50-l:0.4.10 (pcache-entry "pcache-entry-599fe2de" :timestamp 1669643622.863462 :ttl 7776000 :value "7f0bc2b84f32ccb156aefa6eb2d42164") instructions-f:fontset-startup-w:ns-h:localhost-e:29.0.50-l:0.4.10 (pcache-entry "pcache-entry-599fe2e2" :timestamp 1669643622.863474 :ttl 7776000 :value '("fontset-startup" (set-fontset-font "fontset-startup" nil (font-spec :name "Symbola:" :registry "iso10646-1")) (set-fontset-font "fontset-startup" '(65792 . 65855) (font-spec :name "Symbola:" :registry "iso10646-1")) (set-fontset-font "fontset-startup" '(128768 . 128895) (font-spec :name "Symbola:" :registry "iso10646-1")) (set-fontset-font "fontset-startup" '(64256 . 64335) (font-spec :name "Arial Unicode MS:" :registry "iso10646-1")) (set-fontset-font "fontset-startup" '(119296 . 119375) (font-spec :name "Symbola:" :registry "iso10646-1")) (set-fontset-font "fontset-startup" '(65856 . 65935) (font-spec :name "Apple Symbols:" :registry "iso10646-1")) (set-fontset-font "fontset-startup" '(65856 . 65935) (font-spec :name "Symbola:" :registry "iso10646-1") nil 'append) (set-fontset-font "fontset-startup" '(65936 . 65999) (font-spec :name "Symbola:" :registry "iso10646-1")) (set-fontset-font "fontset-startup" '(1536 . 1791) (font-spec :name "Courier New:" :registry "iso10646-1")) \...)) checksum-f:fontset-standard-w:ns-h:localhost-e:29.0.50-l:0.4.10 (pcache-entry "pcache-entry-599fe2f6" :timestamp 1669643623.005151 :ttl 7776000 :value "7f0bc2b84f32ccb156aefa6eb2d42164") instructions-f:fontset-standard-w:ns-h:localhost-e:29.0.50-l:0.4.10 (pcache-entry "pcache-entry-599fe8a8" :timestamp 1669643623.005166 :ttl 7776000 :value '("fontset-standard" (set-fontset-font "fontset-standard" nil (font-spec :name "Symbola:" :registry "iso10646-1")) (set-fontset-font "fontset-standard" '(65792 . 65855) (font-spec :name "Symbola:" :registry "iso10646-1")) (set-fontset-font "fontset-standard" '(128768 . 128895) (font-spec :name "Symbola:" :registry "iso10646-1")) (set-fontset-font "fontset-standard" '(64256 . 64335) (font-spec :name "Arial Unicode MS:" :registry "iso10646-1")) (set-fontset-font "fontset-standard" '(119296 . 119375) (font-spec :name "Symbola:" :registry "iso10646-1")) (set-fontset-font "fontset-standard" '(65856 . 65935) (font-spec :name "Apple Symbols:" :registry "iso10646-1")) (set-fontset-font "fontset-standard" '(65856 . 65935) (font-spec :name "Symbola:" :registry "iso10646-1") nil 'append) (set-fontset-font "fontset-standard" '(65936 . 65999) (font-spec :name "Symbola:" :registry "iso10646-1")) (set-fontset-font "fontset-standard" '(1536 . 1791) (font-spec :name "Courier New:" :registry "iso10646-1")) \...))))
By deleting ~/.emacs.d/.local/cache/pcache/
and restarting emacs, I fixed the issue. I had to do this twice though, the first time the problematic file was just recreated.
Perhaps this package should be installed with the native compilation disabled? (You can mention this in the readme as a warning.)
Hi,
I also had the same issue on Emacs 28.2 with native compilation, and I also fixed the issue by deleting the pcache/unicode-fonts
file.
I wasn't able to reproduce the issue when debugging the regeneration, but this is what I can share to you :
This is the diff between the old problematic cache and the new working one.
In the bad file, the function generating instructions-f:…
data was just able to generate ~10 fonts before stopping the list and adding the problematic \.\.\.
at the end.
In the new one, there are no less than 256 fonts (truncated in the diff)
Maybe this can help
Small note that https://github.com/rolandwalker/unicode-fonts/issues/36#issuecomment-1336049905 fixed the issue for me too. Thanks for that.
Looking at this. Great feedback. Maybe https://www.gnu.org/software/emacs/manual/html_node/elisp/Declare-Form.html in the right spot.
I'm using Doom Emacs and the issue of ...
is caused by the setting that print-length
is set to a non-nil
value.
Setting it to nil
will resolve the issue:
(setq print-length nil)
I seem to have fixed it in #38,where I filter non-cons objects before the eval
also @taquangtrung , setq print-length doesn't fix the problem on my end on 29.1. it doesn't change even with deleting the file and setting it.
void-variable
error while calling(unicode-fonts-setup)
.This happens on Emacs startup.
Very interestingly:
M-x unicode-fonts-setup
, it may fail with the same error a few times before it succeed. It seems that the result of running this command is non-deterministic.Below is the backtrace: