Kungsgeten / org-brain

Org-mode wiki + concept-mapping
MIT License
1.73k stars 104 forks source link

loading data file loop #75

Closed krydos closed 6 years ago

krydos commented 6 years ago

Hi :) thanks for the great package 👍

In my *Messages* buffer I see:

Mark set [4 times]
Loading /Users/me/Dropbox/org-brain/.org-brain-data.el (source)...done
Mark set [4 times]
Loading /Users/me/Dropbox/org-brain/.org-brain-data.el (source)...done
Mark set [4 times]
Loading /Users/me/Dropbox/org-brain/.org-brain-data.el (source)...done
Mark set [4 times]
Loading /Users/me/Dropbox/org-brain/.org-brain-data.el (source)...done
Mark set [4 times]
Loading /Users/me/Dropbox/org-brain/.org-brain-data.el (source)...done
Mark set [4 times]
Loading /Users/me/Dropbox/org-brain/.org-brain-data.el (source)...done
Mark set [4 times]
Loading /Users/me/Dropbox/org-brain/.org-brain-data.el (source)...done
Mark set [4 times]
Loading /Users/me/Dropbox/org-brain/.org-brain-data.el (source)...done
Mark set [4 times]
Loading /Users/me/Dropbox/org-brain/.org-brain-data.el (source)...done
Mark set [4 times]

and keeps printing. It's pretty annoying since it writes it to minibuffer and when I use it (minibuffer) it is getting override with one of that message above and I have to C-g in order to continue my work with minibuffer. It happens once per 3-5 seconds. I can't understand what is the trigger. There is trigger for sure since it doesn't happen initially...

What I've found is org-brain--vis-pinned function is trying to load data file. Sure I can pass another parameter to load function to avoid Loading...done message but it doesn't seems like a solution. It would be great to know why is this loop is running... moreover I don't know how to remove Mark set message which is triggered by one of save-excursion calls.

Could you please help me understand and fix this issue?

Kungsgeten commented 6 years ago

Glad you like the package! My guess is that you don't have any pinned entries? If I remember correctly, loading the pinned entries is something of a hack. I'll look into it. Meanwhile you can pin an entry (shortcut n while visualizing) and see if that solves your problem.

krydos commented 6 years ago

Thanks for the quick answer. You were right about pined entries. I've adde one and Loading...done message is gone. Now only Mark set message exists but it doesn't break minibuffer so it's great.

Anyway it still works wierd. I don't really know how to explain it without a screenshot so here is my small brain:

screen shot 2017-12-25 at 22 32 40

As you can see my cursor is at Vue.js entry. But in couple of seconds (time period is pretty the same as in my previous post, 3-5 seconds) it jumps to Framework7.io.

It works just perfect when I've unloaded and then loaded the package again.

Kungsgeten commented 6 years ago

That used to happen to me a lot in the past, but haven't occurred recently. I think it has something to do with buffers being different from the file on disc, but I'm not sure.

Kungsgeten commented 6 years ago

The loading data file loop should be solved now, and so should setting the mark during org-brain-visualize. Not sure if it fixes the jumping though. If it continues being a problem, please open another issue.

krydos commented 6 years ago

Thank you @Kungsgeten