* A small patch for org.el to fix error in clojure babel src block code ref
@ 2017-05-09 1:21 numbchild
2017-05-09 6:41 ` Nicolas Goaziou
0 siblings, 1 reply; 8+ messages in thread
From: numbchild @ 2017-05-09 1:21 UTC (permalink / raw)
To: Org-mode
[-- Attachment #1: Type: text/plain, Size: 736 bytes --]
Here is the original discussion we disscusses.
https://github.com/jkitchin/org-ref/issues/433
And Here is the patch:
#+BEGIN_SRC diff
modified lisp/org.el
@@ -9730,7 +9730,7 @@ active region."
(setq sfuns
(delq
nil (mapcar (lambda (f)
- (let (fs) (if (funcall f) (push f fs))))
+ (let (fs) (if (and (stringp f) (funcall f)) (push f fs))))
(org-store-link-functions)))
sfunsn (mapcar (lambda (fu) (symbol-name (car fu))) sfuns))
(or (and (cdr sfuns)
#+END_SRC
[stardiviner] <Hack this world!> GPG key ID: 47C32433
IRC(freeenode): stardiviner Twitter: @numbchild
Key fingerprint = 9BAA 92BC CDDD B9EF 3B36 CB99 B8C4 B8E5 47C3 2433
Blog: http://stardiviner.github.io/
[-- Attachment #2: Type: text/html, Size: 3014 bytes --]
^ permalink raw reply [flat|nested] 8+ messages in thread
* Re: A small patch for org.el to fix error in clojure babel src block code ref
2017-05-09 1:21 A small patch for org.el to fix error in clojure babel src block code ref numbchild
@ 2017-05-09 6:41 ` Nicolas Goaziou
2017-05-09 8:06 ` numbchild
2017-05-09 8:07 ` numbchild
0 siblings, 2 replies; 8+ messages in thread
From: Nicolas Goaziou @ 2017-05-09 6:41 UTC (permalink / raw)
To: numbchild@gmail.com; +Cc: Org-mode
Hello,
"numbchild@gmail.com" <numbchild@gmail.com> writes:
> Here is the original discussion we disscusses.
> https://github.com/jkitchin/org-ref/issues/433
>
> And Here is the patch:
>
> #+BEGIN_SRC diff
> modified lisp/org.el
> @@ -9730,7 +9730,7 @@ active region."
> (setq sfuns
> (delq
> nil (mapcar (lambda (f)
> - (let (fs) (if (funcall f) (push f fs))))
> + (let (fs) (if (and (stringp f) (funcall f)) (push f fs))))
> (org-store-link-functions)))
The change above doesn't make sense, does it?
If F is a string, it cannot be funcall'ed. Since
`org-store-link-functions' only contains functions, this patch is
basically skipping the whole variable.
Regards,
--
Nicolas Goaziou
^ permalink raw reply [flat|nested] 8+ messages in thread
* Re: A small patch for org.el to fix error in clojure babel src block code ref
2017-05-09 6:41 ` Nicolas Goaziou
@ 2017-05-09 8:06 ` numbchild
2017-05-09 8:07 ` numbchild
1 sibling, 0 replies; 8+ messages in thread
From: numbchild @ 2017-05-09 8:06 UTC (permalink / raw)
To: Nicolas Goaziou; +Cc: Org-mode
[-- Attachment #1: Type: text/plain, Size: 1282 bytes --]
Weird, but this patch does fixed my issue. When I `org-store-link` in
opened clojure babel src block will has this issue. But not in other
languages babel src blocks like Python, Ruby, C etc.
[stardiviner] <Hack this world!> GPG key ID: 47C32433
IRC(freeenode): stardiviner Twitter: @numbchild
Key fingerprint = 9BAA 92BC CDDD B9EF 3B36 CB99 B8C4 B8E5 47C3 2433
Blog: http://stardiviner.github.io/
On Tue, May 9, 2017 at 2:41 PM, Nicolas Goaziou <mail@nicolasgoaziou.fr>
wrote:
> Hello,
>
> "numbchild@gmail.com" <numbchild@gmail.com> writes:
>
> > Here is the original discussion we disscusses.
> > https://github.com/jkitchin/org-ref/issues/433
> >
> > And Here is the patch:
> >
> > #+BEGIN_SRC diff
> > modified lisp/org.el
> > @@ -9730,7 +9730,7 @@ active region."
> > (setq sfuns
> > (delq
> > nil (mapcar (lambda (f)
> > - (let (fs) (if (funcall f) (push f fs))))
> > + (let (fs) (if (and (stringp f) (funcall f)) (push f fs))))
> > (org-store-link-functions)))
>
> The change above doesn't make sense, does it?
>
> If F is a string, it cannot be funcall'ed. Since
> `org-store-link-functions' only contains functions, this patch is
> basically skipping the whole variable.
>
> Regards,
>
> --
> Nicolas Goaziou
>
[-- Attachment #2: Type: text/html, Size: 2361 bytes --]
^ permalink raw reply [flat|nested] 8+ messages in thread
* Re: A small patch for org.el to fix error in clojure babel src block code ref
2017-05-09 6:41 ` Nicolas Goaziou
2017-05-09 8:06 ` numbchild
@ 2017-05-09 8:07 ` numbchild
2017-05-09 10:51 ` Nicolas Goaziou
1 sibling, 1 reply; 8+ messages in thread
From: numbchild @ 2017-05-09 8:07 UTC (permalink / raw)
To: Nicolas Goaziou; +Cc: Org-mode
[-- Attachment #1: Type: text/plain, Size: 1221 bytes --]
Is there any other possible potential functions will have relation with
this issue?
[stardiviner] <Hack this world!> GPG key ID: 47C32433
IRC(freeenode): stardiviner Twitter: @numbchild
Key fingerprint = 9BAA 92BC CDDD B9EF 3B36 CB99 B8C4 B8E5 47C3 2433
Blog: http://stardiviner.github.io/
On Tue, May 9, 2017 at 2:41 PM, Nicolas Goaziou <mail@nicolasgoaziou.fr>
wrote:
> Hello,
>
> "numbchild@gmail.com" <numbchild@gmail.com> writes:
>
> > Here is the original discussion we disscusses.
> > https://github.com/jkitchin/org-ref/issues/433
> >
> > And Here is the patch:
> >
> > #+BEGIN_SRC diff
> > modified lisp/org.el
> > @@ -9730,7 +9730,7 @@ active region."
> > (setq sfuns
> > (delq
> > nil (mapcar (lambda (f)
> > - (let (fs) (if (funcall f) (push f fs))))
> > + (let (fs) (if (and (stringp f) (funcall f)) (push f fs))))
> > (org-store-link-functions)))
>
> The change above doesn't make sense, does it?
>
> If F is a string, it cannot be funcall'ed. Since
> `org-store-link-functions' only contains functions, this patch is
> basically skipping the whole variable.
>
> Regards,
>
> --
> Nicolas Goaziou
>
[-- Attachment #2: Type: text/html, Size: 2271 bytes --]
^ permalink raw reply [flat|nested] 8+ messages in thread
* Re: A small patch for org.el to fix error in clojure babel src block code ref
2017-05-09 8:07 ` numbchild
@ 2017-05-09 10:51 ` Nicolas Goaziou
2017-05-09 11:01 ` John Kitchin
0 siblings, 1 reply; 8+ messages in thread
From: Nicolas Goaziou @ 2017-05-09 10:51 UTC (permalink / raw)
To: numbchild@gmail.com; +Cc: Org-mode
"numbchild@gmail.com" <numbchild@gmail.com> writes:
> Is there any other possible potential functions will have relation with
> this issue?
According to the backtrace mentioned in the bug report, the culprit is
probably `org-label-store-link', which is probably one of the functions
returned by `org-store-link-functions'.
Since a consequence of your patch is to ignore all functions returned by
`org-store-link-functions', it "solves" the issue you're having, in
a way.
Anyway, there is no such function in Org code base, so you may want to
check where it is defined.
Regards,
^ permalink raw reply [flat|nested] 8+ messages in thread
* Re: A small patch for org.el to fix error in clojure babel src block code ref
2017-05-09 10:51 ` Nicolas Goaziou
@ 2017-05-09 11:01 ` John Kitchin
2017-05-09 11:14 ` John Kitchin
0 siblings, 1 reply; 8+ messages in thread
From: John Kitchin @ 2017-05-09 11:01 UTC (permalink / raw)
To: Nicolas Goaziou; +Cc: Org-mode
[-- Attachment #1: Type: text/plain, Size: 454 bytes --]
On Tue, May 9, 2017 at 6:51 AM, Nicolas Goaziou <mail@nicolasgoaziou.fr>
wrote:
> org-store-link-functions
That is a function in org-ref. I will check it out this morning. Thanks
for the pointer to the root of the issue!
John
-----------------------------------
Professor John Kitchin
Doherty Hall A207F
Department of Chemical Engineering
Carnegie Mellon University
Pittsburgh, PA 15213
412-268-7803
@johnkitchin
http://kitchingroup.cheme.cmu.edu
[-- Attachment #2: Type: text/html, Size: 1051 bytes --]
^ permalink raw reply [flat|nested] 8+ messages in thread
* Re: A small patch for org.el to fix error in clojure babel src block code ref
2017-05-09 11:01 ` John Kitchin
@ 2017-05-09 11:14 ` John Kitchin
2017-05-10 2:01 ` numbchild
0 siblings, 1 reply; 8+ messages in thread
From: John Kitchin @ 2017-05-09 11:14 UTC (permalink / raw)
To: Nicolas Goaziou; +Cc: Org-mode
[-- Attachment #1: Type: text/plain, Size: 1026 bytes --]
I think I have just fixed it. The offending command was trying to get an
org-element in the special edit buffer which wasn't in org-mode. Its not
clear why it worked in some codes and not others though!
John
-----------------------------------
Professor John Kitchin
Doherty Hall A207F
Department of Chemical Engineering
Carnegie Mellon University
Pittsburgh, PA 15213
412-268-7803
@johnkitchin
http://kitchingroup.cheme.cmu.edu
On Tue, May 9, 2017 at 7:01 AM, John Kitchin <jkitchin@andrew.cmu.edu>
wrote:
>
> On Tue, May 9, 2017 at 6:51 AM, Nicolas Goaziou <mail@nicolasgoaziou.fr>
> wrote:
>
>> org-store-link-functions
>
>
> That is a function in org-ref. I will check it out this morning. Thanks
> for the pointer to the root of the issue!
>
>
> John
>
> -----------------------------------
> Professor John Kitchin
> Doherty Hall A207F
> Department of Chemical Engineering
> Carnegie Mellon University
> Pittsburgh, PA 15213
> 412-268-7803 <(412)%20268-7803>
> @johnkitchin
> http://kitchingroup.cheme.cmu.edu
>
>
[-- Attachment #2: Type: text/html, Size: 2236 bytes --]
^ permalink raw reply [flat|nested] 8+ messages in thread
* Re: A small patch for org.el to fix error in clojure babel src block code ref
2017-05-09 11:14 ` John Kitchin
@ 2017-05-10 2:01 ` numbchild
0 siblings, 0 replies; 8+ messages in thread
From: numbchild @ 2017-05-10 2:01 UTC (permalink / raw)
To: John Kitchin; +Cc: Org-mode, Nicolas Goaziou
[-- Attachment #1: Type: text/plain, Size: 1455 bytes --]
Thanks for fixing, John.
[stardiviner] <Hack this world!> GPG key ID: 47C32433
IRC(freeenode): stardiviner Twitter: @numbchild
Key fingerprint = 9BAA 92BC CDDD B9EF 3B36 CB99 B8C4 B8E5 47C3 2433
Blog: http://stardiviner.github.io/
On Tue, May 9, 2017 at 7:14 PM, John Kitchin <jkitchin@andrew.cmu.edu>
wrote:
> I think I have just fixed it. The offending command was trying to get an
> org-element in the special edit buffer which wasn't in org-mode. Its not
> clear why it worked in some codes and not others though!
>
> John
>
> -----------------------------------
> Professor John Kitchin
> Doherty Hall A207F
> Department of Chemical Engineering
> Carnegie Mellon University
> Pittsburgh, PA 15213
> 412-268-7803 <(412)%20268-7803>
> @johnkitchin
> http://kitchingroup.cheme.cmu.edu
>
>
> On Tue, May 9, 2017 at 7:01 AM, John Kitchin <jkitchin@andrew.cmu.edu>
> wrote:
>
>>
>> On Tue, May 9, 2017 at 6:51 AM, Nicolas Goaziou <mail@nicolasgoaziou.fr>
>> wrote:
>>
>>> org-store-link-functions
>>
>>
>> That is a function in org-ref. I will check it out this morning. Thanks
>> for the pointer to the root of the issue!
>>
>>
>> John
>>
>> -----------------------------------
>> Professor John Kitchin
>> Doherty Hall A207F
>> Department of Chemical Engineering
>> Carnegie Mellon University
>> Pittsburgh, PA 15213
>> 412-268-7803 <(412)%20268-7803>
>> @johnkitchin
>> http://kitchingroup.cheme.cmu.edu
>>
>>
>
[-- Attachment #2: Type: text/html, Size: 3402 bytes --]
^ permalink raw reply [flat|nested] 8+ messages in thread
end of thread, other threads:[~2017-05-10 2:02 UTC | newest]
Thread overview: 8+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2017-05-09 1:21 A small patch for org.el to fix error in clojure babel src block code ref numbchild
2017-05-09 6:41 ` Nicolas Goaziou
2017-05-09 8:06 ` numbchild
2017-05-09 8:07 ` numbchild
2017-05-09 10:51 ` Nicolas Goaziou
2017-05-09 11:01 ` John Kitchin
2017-05-09 11:14 ` John Kitchin
2017-05-10 2:01 ` numbchild
Code repositories for project(s) associated with this public inbox
https://git.savannah.gnu.org/cgit/emacs/org-mode.git
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).