From mboxrd@z Thu Jan 1 00:00:00 1970 From: Achim Gratz Subject: Re: org-agenda-write taking very long (probably because of babel) Date: Sun, 10 Mar 2013 14:00:00 +0100 Message-ID: <87hakjo1f3.fsf@Rainer.invalid> References: <2013-02-27T17-53-25@devnull.Karl-Voit.at> Mime-Version: 1.0 Content-Type: text/plain Return-path: Received: from eggs.gnu.org ([208.118.235.92]:49247) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1UEfrb-0006kg-PT for emacs-orgmode@gnu.org; Sun, 10 Mar 2013 09:00:32 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1UEfra-0004nG-26 for emacs-orgmode@gnu.org; Sun, 10 Mar 2013 09:00:31 -0400 Received: from plane.gmane.org ([80.91.229.3]:37690) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1UEfrZ-0004nA-Rc for emacs-orgmode@gnu.org; Sun, 10 Mar 2013 09:00:29 -0400 Received: from list by plane.gmane.org with local (Exim 4.69) (envelope-from ) id 1UEfrs-0000kK-CK for emacs-orgmode@gnu.org; Sun, 10 Mar 2013 14:00:48 +0100 Received: from pd9eb5852.dip.t-dialin.net ([217.235.88.82]) by main.gmane.org with esmtp (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Sun, 10 Mar 2013 14:00:48 +0100 Received: from Stromeko by pd9eb5852.dip.t-dialin.net with local (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Sun, 10 Mar 2013 14:00:48 +0100 List-Id: "General discussions about Org-mode." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-orgmode-bounces+geo-emacs-orgmode=m.gmane.org@gnu.org Sender: emacs-orgmode-bounces+geo-emacs-orgmode=m.gmane.org@gnu.org To: emacs-orgmode@gnu.org Karl Voit writes: > Since my Org-mode update from today (from > 5d467d6f8affc0afe34922e885ac6e2492ddd091 Fri Feb 15 15:28:35 2013 > +0100) it takes very long to export the ics file. > > I guess this relates to ... > > org-babel-exp processing... [25 times] > > ... which also pops up some babel result graphics which did not > happen before. > > Was there a change in the default settings or is this a bug? I have worked with Karl to try and find what caused this change in behaviour and it wasn't anything to do with my patch or even recently, but the switch from the old to the new exporter framework for producing the iCalendar files. The patch in question is buried in commit 0a01e52aa1: --8<---------------cut here---------------start------------->8--- ------------------------------ lisp/org-agenda.el ------------------------------ index 809287b..e9a9efc 100644 @@ -2361,11 +2361,11 @@ (defun org-agenda-mode () ["Phases of the Moon" org-agenda-phases-of-moon (org-agenda-check-type nil 'agenda 'timeline)] ["Sunrise/Sunset" org-agenda-sunrise-sunset (org-agenda-check-type nil 'agenda 'timeline)] ["Holidays" org-agenda-holidays (org-agenda-check-type nil 'agenda 'timeline)] ["Convert" org-agenda-convert-date (org-agenda-check-type nil 'agenda 'timeline)] "--" - ["Create iCalendar File" org-export-icalendar-combine-agenda-files t]) + ["Create iCalendar File" org-icalendar-combine-agenda-files t]) "--" ["Undo Remote Editing" org-agenda-undo org-agenda-undo-list] "--" ("MobileOrg" ["Push Files and Views" org-mobile-push t] @@ -3347,18 +3347,12 @@ (defun org-agenda-write (file &optional open nosettings agenda-bufname) (concat (file-name-sans-extension file) ".ps")) (expand-file-name file)) (delete-file (concat (file-name-sans-extension file) ".ps")) (message "PDF written to %s" file)) ((string-match "\\.ics\\'" file) - (require 'org-icalendar) - (let ((org-agenda-marker-table - (org-create-marker-find-array - (org-agenda-collect-markers))) - (org-icalendar-verify-function 'org-check-agenda-marker-table) - (org-combined-agenda-icalendar-file file)) - (apply 'org-export-icalendar 'combine - (org-agenda-files nil 'ifmode)))) + (require 'ox-icalendar) + (org-icalendar-export-current-agenda (expand-file-name file))) (t (let ((bs (buffer-string))) (find-file file) (erase-buffer) (insert bs) --8<---------------cut here---------------end--------------->8--- So, it seems that the old code did something to prevent source block execution, while the new one does not handle this situation specially. I know next to nothing about agendas or iCalendar export, so I would appreciate if someone more knowledgeable could have a look. Regards, Achim. -- +<[Q+ Matrix-12 WAVE#46+305 Neuron microQkb Andromeda XTk Blofeld]>+ Factory and User Sound Singles for Waldorf Q+, Q and microQ: http://Synth.Stromeko.net/Downloads.html#WaldorfSounds