emacs-orgmode@gnu.org archives
 help / color / mirror / code / Atom feed
* Bug (?) in org-capture
@ 2010-10-14 14:40 Robert Goldman
  2010-10-14 15:14 ` Robert Goldman
  0 siblings, 1 reply; 4+ messages in thread
From: Robert Goldman @ 2010-10-14 14:40 UTC (permalink / raw)
  To: Org Mode

I was trying to experiment for the first time using org-capture together
with w3m today, and I get an error.

I invoke org-capture, and was pleased to find that it built me a buffer
just fine, and made an org link for the URL of the w3m buffer.  So far,
so good.

Unfortunately, when I try to save the buffer, either with C-c C-c or C-c
C-w, I get an error.

The error is in org-capture-bookmark-last-stored-position.  Here:

(defun org-capture-bookmark-last-stored-position ()
  "Bookmark the last-captured position."
  (let* ((where (org-capture-get :position-for-last-stored 'local))
    ....)

WHERE gets bound to NIL, the return of ORG-CAPTURE-GET, causing an error.

I'm quite prepared to believe that I have this horribly misconfigured,
since I really didn't configure it at all, but it's disappointing that
the buffer creation works so well without configuration, but leaves me
in this pickle.  It's also disappointing that the refile command doesn't
work --- any chance of hacking it so that it does something sensible (I
was thinking involving interactive selection) when org-capture is not
yet configured?

AFAICT the direct cause of the error is that org-capture-current-plist
is NIL, and the 'local spec in this call means that we consult that
instead of org-capture-plist.

At this point my ability to understand the code peters out, and I'm
afraid I don't have anything useful to say.

best,
r

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: Bug (?) in org-capture
  2010-10-14 14:40 Bug (?) in org-capture Robert Goldman
@ 2010-10-14 15:14 ` Robert Goldman
  2010-10-15  6:48   ` Carsten Dominik
  0 siblings, 1 reply; 4+ messages in thread
From: Robert Goldman @ 2010-10-14 15:14 UTC (permalink / raw)
  To: Org Mode

On 10/14/10 Oct 14 -9:40 AM, Robert Goldman wrote:
> I was trying to experiment for the first time using org-capture together
> with w3m today, and I get an error.
> 
> I invoke org-capture, and was pleased to find that it built me a buffer
> just fine, and made an org link for the URL of the w3m buffer.  So far,
> so good.
> 
> Unfortunately, when I try to save the buffer, either with C-c C-c or C-c
> C-w, I get an error.
> 
> The error is in org-capture-bookmark-last-stored-position.  Here:
> 
> (defun org-capture-bookmark-last-stored-position ()
>   "Bookmark the last-captured position."
>   (let* ((where (org-capture-get :position-for-last-stored 'local))
>     ....)
> 
> WHERE gets bound to NIL, the return of ORG-CAPTURE-GET, causing an error.
> 
> I'm quite prepared to believe that I have this horribly misconfigured,
> since I really didn't configure it at all, but it's disappointing that
> the buffer creation works so well without configuration, but leaves me
> in this pickle.  It's also disappointing that the refile command doesn't
> work --- any chance of hacking it so that it does something sensible (I
> was thinking involving interactive selection) when org-capture is not
> yet configured?
> 
> AFAICT the direct cause of the error is that org-capture-current-plist
> is NIL, and the 'local spec in this call means that we consult that
> instead of org-capture-plist.
> 
> At this point my ability to understand the code peters out, and I'm
> afraid I don't have anything useful to say.

Sorta never mind --- I figured out what the problem was.  Somehow the
default file for org-capture was ~/org//notes.org not ~/org/notes.org,
so there was really a "file not found" error here.

So this is, in a sense, user error.

That said, if it's not too much trouble, maybe reporting a file not
found error for this would be more helpful than crashing in this way.

On the other hand, this might be tricky to find and handle, so maybe
it's not worth the trouble.

best,
r

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: Re: Bug (?) in org-capture
  2010-10-14 15:14 ` Robert Goldman
@ 2010-10-15  6:48   ` Carsten Dominik
  2010-10-15 19:23     ` Robert Goldman
  0 siblings, 1 reply; 4+ messages in thread
From: Carsten Dominik @ 2010-10-15  6:48 UTC (permalink / raw)
  To: rpgoldman; +Cc: Org Mode

Hi Robert,

I cannot reproduce this error.  If I set my default notes file to "~/ 
org//notes.org"
things seem to work just fine.

- Carsten


On Oct 14, 2010, at 5:14 PM, Robert Goldman wrote:

> On 10/14/10 Oct 14 -9:40 AM, Robert Goldman wrote:
>> I was trying to experiment for the first time using org-capture  
>> together
>> with w3m today, and I get an error.
>>
>> I invoke org-capture, and was pleased to find that it built me a  
>> buffer
>> just fine, and made an org link for the URL of the w3m buffer.  So  
>> far,
>> so good.
>>
>> Unfortunately, when I try to save the buffer, either with C-c C-c  
>> or C-c
>> C-w, I get an error.
>>
>> The error is in org-capture-bookmark-last-stored-position.  Here:
>>
>> (defun org-capture-bookmark-last-stored-position ()
>> "Bookmark the last-captured position."
>> (let* ((where (org-capture-get :position-for-last-stored 'local))
>>   ....)
>>
>> WHERE gets bound to NIL, the return of ORG-CAPTURE-GET, causing an  
>> error.
>>
>> I'm quite prepared to believe that I have this horribly  
>> misconfigured,
>> since I really didn't configure it at all, but it's disappointing  
>> that
>> the buffer creation works so well without configuration, but leaves  
>> me
>> in this pickle.  It's also disappointing that the refile command  
>> doesn't
>> work --- any chance of hacking it so that it does something  
>> sensible (I
>> was thinking involving interactive selection) when org-capture is not
>> yet configured?
>>
>> AFAICT the direct cause of the error is that org-capture-current- 
>> plist
>> is NIL, and the 'local spec in this call means that we consult that
>> instead of org-capture-plist.
>>
>> At this point my ability to understand the code peters out, and I'm
>> afraid I don't have anything useful to say.
>
> Sorta never mind --- I figured out what the problem was.  Somehow the
> default file for org-capture was ~/org//notes.org not ~/org/notes.org,
> so there was really a "file not found" error here.
>
> So this is, in a sense, user error.
>
> That said, if it's not too much trouble, maybe reporting a file not
> found error for this would be more helpful than crashing in this way.
>
> On the other hand, this might be tricky to find and handle, so maybe
> it's not worth the trouble.
>
> best,
> r
>
> _______________________________________________
> Emacs-orgmode mailing list
> Please use `Reply All' to send replies to the list.
> Emacs-orgmode@gnu.org
> http://lists.gnu.org/mailman/listinfo/emacs-orgmode

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: Re: Bug (?) in org-capture
  2010-10-15  6:48   ` Carsten Dominik
@ 2010-10-15 19:23     ` Robert Goldman
  0 siblings, 0 replies; 4+ messages in thread
From: Robert Goldman @ 2010-10-15 19:23 UTC (permalink / raw)
  To: Carsten Dominik; +Cc: Org Mode

On 10/15/10 Oct 15 -1:48 AM, Carsten Dominik wrote:
> Hi Robert,
> 
> I cannot reproduce this error.  If I set my default notes file to
> "~/org//notes.org"
> things seem to work just fine.

I will see if I can figure out why this happened for me.  I may not be
able to do so, though --- it occurred when I had a half-configured
org-capture, and now I have org-capture really working.  It's not always
easy to go back to the buggy state!

Thank you very much for org-capture, BTW --- I really like the ability
to dispatch on key combinations, in particular, since I find that the
more I use org-capture, the more opportunities I see to get more value
out of it.

best,
r

^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2010-10-15 19:23 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2010-10-14 14:40 Bug (?) in org-capture Robert Goldman
2010-10-14 15:14 ` Robert Goldman
2010-10-15  6:48   ` Carsten Dominik
2010-10-15 19:23     ` Robert Goldman

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).