Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Error detected while processing function <SNR>212_RefileAndClose[5]..dotoo#move_headline #62

Open
unknownbreaker opened this issue Feb 19, 2020 · 8 comments

Comments

@unknownbreaker
Copy link

I get an error when attempting to close out of the Notes template.

  1. I setup a dummy dotoo file dotootest.dotoo and then hit gC.
  2. Typed in random note and did :w. Saves OK.
  3. When doing :q, I get an error message.

image

@Gavinok
Copy link
Contributor

Gavinok commented Feb 19, 2020

What does the template look like?

1 similar comment
@Gavinok
Copy link
Contributor

Gavinok commented Feb 19, 2020

What does the template look like?

@dhruvasagar
Copy link
Owner

Are you sure you are on the latest ? I think I had pushed something that broke but had fixed it later. Can you confirm if you're facing this issue on the latest commit ? @unknownbreaker Thanks

@dhruvasagar
Copy link
Owner

Also can you confirm if the path ~/Documents/dotoo-files exists ? If not you should create that, or you can override the configuration g:dotoo#agenda#files, kindly refer to the inline vim help for more information

@cstsunfu
Copy link

I have this issue too. It not always occurs in my vim.
My configure is:

       let g:dotoo#agenda#files = ['/Users/sun/Documents/dotoo-files/*.dotoo']
       let g:dotoo#capture#refile = expand( '/Users/sun/Documents/dotoo-files/refile.dotoo')
       let g:dotoo#capture#templates = {
             \ 't': {
             \   'description': 'Todo',
             \   'lines': [
             \     '* TODO %?',
             \     'DEADLINE: [%(strftime(g:dotoo#time#datetime_format))]'
             \   ],
             \  'target': 'refile:Tasks'
             \ },
             \ 'n': {
             \   'description': 'Note',
             \   'lines': ['* %? :NOTE:'],
             \ },
             \ 'm': {
             \   'description': 'Meeting',
             \   'lines': ['* MEETING with %? :MEETING:'],
             \ },
             \ 'p': {
             \   'description': 'Phone call',
             \   'lines': ['* PHONE %? :PHONE:'],
             \ },
             \ 'h': {
             \   'description': 'Habit',
             \   'lines': [
             \     '* NEXT %?',
             \     'SCHEDULED: [%(strftime(g:dotoo#time#date_day_format)) +1m]',
             \     ':PROPERTIES:',
             \     ':STYLE: habit',
             \     ':REPEAT_TO_STATE: NEXT',
             \     ':END:'
             \   ]
             \ }
             \}

I think this issue maybe related to the temporary file. When I capture one todo item, this plugin will open one temporary file like "/private/var/folders/kw/_rs242hj7h5d2lx5344tww4c0000gp/T/nvim5N3yPI", but this file is readonly.

OS X & neovim v0.4.3

@dhruvasagar
Copy link
Owner

@cstsunfu Would you be able to answer my questions I stated above ?

@cstsunfu
Copy link

Yes, the path of g:dotoo#agenda#files exist on my system, and my plugin version is the newest.
This issue not always occurs in my vim. In the same environment, sometimes it works well, sometimes it's wrong, so I didn't know what triggers this issue.

PS: The temporary file is writable when I use :w to save, but when I use :q to quit the capture, this file will be readonly.

@dhruvasagar
Copy link
Owner

@cstsunfu I believe this should not be an issue with on the latest version of vim-dotoo. Kindly test again and let me know.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants