Hi Ihor, * Ihor Radchenko <yanta...@posteo.net> [2024-03-25; 18:20 GMT]: > Gregor Zattler <telegr...@gmx.net> writes: > >> I did >> >> rm -rf *; git checkout -f; make repro >> >> in ~/src/org-mode. make repro is very quick. >> >> Then I tested again with the above mentioned clock >> table frame and emacs command line invocation: Same >> result. No backtrace. >> >> Am I missing something? > > Looks like some caller is intercepting errors, demoting them to messages. > > What happens if you run M-: (org-clock-sum) <RET> directly in the > problematic buffer?
on the clock table frame? 0 (#o0, #x0, ?\C-@) I don't know what that means. In the file.org_archive, with point on a clock line: Debugger entered--Lisp error: (wrong-type-argument fixnump nil) encode-time((0 nil nil nil nil nil nil -1 nil)) (float-time (encode-time (list 0 (org-element--property :minute-start timestamp nil nil) (org-element--property :hour-start timestamp nil nil) (org-element--property :day-start timestamp nil nil) (org-element--property :month-start timestamp nil nil) (org-element--property :year-start timestamp nil nil) nil -1 nil))) (let* ((timestamp (org-element--property :value element nil nil)) (ts (float-time (encode-time (list 0 (org-element--property :minute-start timestamp nil nil) (org-element--property :hour-start timestamp nil nil) (org-element--property :day-start timestamp nil nil) (org-element--property :month-start timestamp nil nil) (org-element--property :year-start timestamp nil nil) nil -1 nil)))) (te (float-time (encode-time (list 0 (org-element--property :minute-end timestamp nil nil) (org-element--property :hour-end timestamp nil nil) (org-element--property :day-end timestamp nil nil) (org-element--property :month-end timestamp nil nil) (org-element--property :year-end timestamp nil nil) nil -1 nil)))) (dt (- (if tend (min te tend) te) (if tstart (max ts tstart) ts)))) (if (> dt 0) (progn (setq t1 (+ t1 (floor dt 60)))))) (cond ((and (eq element-type 'clock) (match-end 2)) (let* ((timestamp (org-element--property :value element nil nil)) (ts (float-time (encode-time (list 0 ... ... ... ... ... nil -1 nil)))) (te (float-time (encode-time (list 0 ... ... ... ... ... nil -1 nil)))) (dt (- (if tend (min te tend) te) (if tstart (max ts tstart) ts)))) (if (> dt 0) (progn (setq t1 (+ t1 (floor dt 60))))))) ((match-end 4) (setq t1 (+ t1 (string-to-number (match-string 5)) (* 60 (string-to-number (match-string 4)))))) ((memq element-type '(headline inlinetask)) (if (and org-clock-report-include-clocking-task (eq (org-clocking-buffer) (current-buffer)) (eq (marker-position org-clock-hd-marker) (point)) tstart tend (>= (float-time org-clock-start-time) tstart) (<= (float-time org-clock-start-time) tend)) (progn (let ((time (floor ... 60))) (setq t1 (+ t1 time))))) (let* ((headline-forced (get-text-property (point) :org-clock-force-headline-inclusion)) (headline-included (or (null headline-filter) (save-excursion (let ... ...))))) (setq level (- (match-end 1) (match-beginning 1))) (if (>= level lmax) (progn (progn (setq ltimes (vconcat ltimes ...)) (setq lmax (* 2 lmax))))) (if (or (> t1 0) (> (aref ltimes level) 0)) (progn (if (or headline-included headline-forced) (progn (if headline-included ...) (setq time ...) (goto-char ...) (put-text-property ... ... ... time) (if headline-filter ...))) (setq t1 0) (let* ((l level) (--cl-var-- ...)) (while (<= l --cl-var--) (aset ltimes l 0) (setq l ...)) nil)))))) (let* ((element (let ((saved-match-data (match-data))) (unwind-protect (progn (org-element-at-point)) (set-match-data saved-match-data t)))) (element-type (org-element-type element))) (cond ((and (eq element-type 'clock) (match-end 2)) (let* ((timestamp (org-element--property :value element nil nil)) (ts (float-time (encode-time ...))) (te (float-time (encode-time ...))) (dt (- (if tend ... te) (if tstart ... ts)))) (if (> dt 0) (progn (setq t1 (+ t1 ...)))))) ((match-end 4) (setq t1 (+ t1 (string-to-number (match-string 5)) (* 60 (string-to-number (match-string 4)))))) ((memq element-type '(headline inlinetask)) (if (and org-clock-report-include-clocking-task (eq (org-clocking-buffer) (current-buffer)) (eq (marker-position org-clock-hd-marker) (point)) tstart tend (>= (float-time org-clock-start-time) tstart) (<= (float-time org-clock-start-time) tend)) (progn (let ((time ...)) (setq t1 (+ t1 time))))) (let* ((headline-forced (get-text-property (point) :org-clock-force-headline-inclusion)) (headline-included (or (null headline-filter) (save-excursion ...)))) (setq level (- (match-end 1) (match-beginning 1))) (if (>= level lmax) (progn (progn (setq ltimes ...) (setq lmax ...)))) (if (or (> t1 0) (> (aref ltimes level) 0)) (progn (if (or headline-included headline-forced) (progn ... ... ... ... ...)) (setq t1 0) (let* (... ...) (while ... ... ...) nil))))))) (while (re-search-backward re nil t) (let* ((element (let ((saved-match-data (match-data))) (unwind-protect (progn (org-element-at-point)) (set-match-data saved-match-data t)))) (element-type (org-element-type element))) (cond ((and (eq element-type 'clock) (match-end 2)) (let* ((timestamp (org-element--property :value element nil nil)) (ts (float-time ...)) (te (float-time ...)) (dt (- ... ...))) (if (> dt 0) (progn (setq t1 ...))))) ((match-end 4) (setq t1 (+ t1 (string-to-number (match-string 5)) (* 60 (string-to-number ...))))) ((memq element-type '(headline inlinetask)) (if (and org-clock-report-include-clocking-task (eq (org-clocking-buffer) (current-buffer)) (eq (marker-position org-clock-hd-marker) (point)) tstart tend (>= (float-time org-clock-start-time) tstart) (<= (float-time org-clock-start-time) tend)) (progn (let (...) (setq t1 ...)))) (let* ((headline-forced (get-text-property ... :org-clock-force-headline-inclusion)) (headline-included (or ... ...))) (setq level (- (match-end 1) (match-beginning 1))) (if (>= level lmax) (progn (progn ... ...))) (if (or (> t1 0) (> ... 0)) (progn (if ... ...) (setq t1 0) (let* ... ... nil)))))))) (save-excursion (goto-char (point-max)) (while (re-search-backward re nil t) (let* ((element (let ((saved-match-data ...)) (unwind-protect (progn ...) (set-match-data saved-match-data t)))) (element-type (org-element-type element))) (cond ((and (eq element-type 'clock) (match-end 2)) (let* ((timestamp ...) (ts ...) (te ...) (dt ...)) (if (> dt 0) (progn ...)))) ((match-end 4) (setq t1 (+ t1 (string-to-number ...) (* 60 ...)))) ((memq element-type '(headline inlinetask)) (if (and org-clock-report-include-clocking-task (eq ... ...) (eq ... ...) tstart tend (>= ... tstart) (<= ... tend)) (progn (let ... ...))) (let* ((headline-forced ...) (headline-included ...)) (setq level (- ... ...)) (if (>= level lmax) (progn ...)) (if (or ... ...) (progn ... ... ...))))))) (setq org-clock-file-total-minutes (aref ltimes 0))) (let* ((re (concat "^\\(\\*+\\)[ \11]\\|^[ \11]*" org-clock-string "[ \11]*\\(?:\\(\\[.*?\\]\\)-+\\(\\[.*?\\]\\)\\|=>[ \11]+\\([0-9]+\\):\\([0-9]+\\)\\)")) (lmax 30) (ltimes (make-vector lmax 0)) (level 0) (tstart (cond ((stringp tstart) (org-time-string-to-seconds tstart)) ((consp tstart) (float-time tstart)) (t tstart))) (tend (cond ((stringp tend) (org-time-string-to-seconds tend)) ((consp tend) (float-time tend)) (t tend))) (t1 0) time) (remove-text-properties (point-min) (point-max) (cons (or propname :org-clock-minutes) '(t :org-clock-force-headline-inclusion t))) (save-excursion (goto-char (point-max)) (while (re-search-backward re nil t) (let* ((element (let (...) (unwind-protect ... ...))) (element-type (org-element-type element))) (cond ((and (eq element-type ...) (match-end 2)) (let* (... ... ... ...) (if ... ...))) ((match-end 4) (setq t1 (+ t1 ... ...))) ((memq element-type '...) (if (and org-clock-report-include-clocking-task ... ... tstart tend ... ...) (progn ...)) (let* (... ...) (setq level ...) (if ... ...) (if ... ...)))))) (setq org-clock-file-total-minutes (aref ltimes 0)))) (progn (let* ((re (concat "^\\(\\*+\\)[ \11]\\|^[ \11]*" org-clock-string "[ \11]*\\(?:\\(\\[.*?\\]\\)-+\\(\\[.*?\\]\\)\\|=>[ \11]+\\([0-9]+\\):\\([0-9]+\\)\\)")) (lmax 30) (ltimes (make-vector lmax 0)) (level 0) (tstart (cond ((stringp tstart) (org-time-string-to-seconds tstart)) ((consp tstart) (float-time tstart)) (t tstart))) (tend (cond ((stringp tend) (org-time-string-to-seconds tend)) ((consp tend) (float-time tend)) (t tend))) (t1 0) time) (remove-text-properties (point-min) (point-max) (cons (or propname :org-clock-minutes) '(t :org-clock-force-headline-inclusion t))) (save-excursion (goto-char (point-max)) (while (re-search-backward re nil t) (let* ((element (let ... ...)) (element-type (org-element-type element))) (cond ((and ... ...) (let* ... ...)) ((match-end 4) (setq t1 ...)) ((memq element-type ...) (if ... ...) (let* ... ... ... ...))))) (setq org-clock-file-total-minutes (aref ltimes 0))))) (unwind-protect (progn (let* ((re (concat "^\\(\\*+\\)[ \11]\\|^[ \11]*" org-clock-string "[ \11]*\\(?:\\(\\[.*?\\]\\)-+\\(\\[.*?\\]\\)\\|=>[ \11]+\\([0-9]+\\):\\([0-9]+\\)\\)")) (lmax 30) (ltimes (make-vector lmax 0)) (level 0) (tstart (cond ((stringp tstart) (org-time-string-to-seconds tstart)) ((consp tstart) (float-time tstart)) (t tstart))) (tend (cond ((stringp tend) (org-time-string-to-seconds tend)) ((consp tend) (float-time tend)) (t tend))) (t1 0) time) (remove-text-properties (point-min) (point-max) (cons (or propname :org-clock-minutes) '(t :org-clock-force-headline-inclusion t))) (save-excursion (goto-char (point-max)) (while (re-search-backward re nil t) (let* ((element ...) (element-type ...)) (cond (... ...) (... ...) (... ... ...)))) (setq org-clock-file-total-minutes (aref ltimes 0))))) (if (or (not modified) (eq modified 'autosaved)) (progn (restore-buffer-modified-p modified)))) (let* ((modified (buffer-modified-p)) (buffer-undo-list t) (inhibit-read-only t) (inhibit-modification-hooks t)) (unwind-protect (progn (let* ((re (concat "^\\(\\*+\\)[ \11]\\|^[ \11]*" org-clock-string "[ \11]*\\(?:\\(\\[.*?\\]\\)-+\\(\\[.*?\\]\\)\\|=>[ \11]+\\([0-9]+\\):\\([0-9]+\\)\\)")) (lmax 30) (ltimes (make-vector lmax 0)) (level 0) (tstart (cond (... ...) (... ...) (t tstart))) (tend (cond (... ...) (... ...) (t tend))) (t1 0) time) (remove-text-properties (point-min) (point-max) (cons (or propname :org-clock-minutes) '(t :org-clock-force-headline-inclusion t))) (save-excursion (goto-char (point-max)) (while (re-search-backward re nil t) (let* (... ...) (cond ... ... ...))) (setq org-clock-file-total-minutes (aref ltimes 0))))) (if (or (not modified) (eq modified 'autosaved)) (progn (restore-buffer-modified-p modified))))) org-clock-sum() eval((org-clock-sum) t) #f(compiled-function () #<bytecode -0x88ae3ad503f545e>)() #f(compiled-function () #<bytecode -0x5db3e1955cb81d1>)() eval-expression((org-clock-sum) nil nil 127) funcall-interactively(eval-expression (org-clock-sum) nil nil 127) command-execute(eval-expression) seems to be somewhat truncated. Is there a way to get it unabbreviated? I tried to do --eval "(setq load-suffixes '(".el"))" ... but that gave an error. Any other ideas, or is this already helpful? Ciao; Gregor