Closed ispringle closed 1 year ago
Weird! Lemme see if I can get this to happen on my copy. From there I can see about writing tests.
Okay I was able to write a test for it. I'm gonna start looking through my books to see if I can fix it. Thank you!
Thanks!
Thank you for catching this. Please pull the latest commit and see if it fixes the issue.
This is still happening for me:
* Calculation TODO
** Input
3+4+5+6
** Evaluation
from orgmunge import Org
calcfile = Org("test.org")
calcfile.write("test.org")
And then the error above when reparsing it again as it puts two newlines at the top:
* Calculation TODO
** Input
3+4+5+6
** Evaluation
Great library though. I'm looking forward to building a calculator on top of it.
If you'd like I can fork and write a pull request with a failing test for the above scenario.
Interesting... If you have a failing test ready it would be greatly appreciated.
I'm excited to see any software you build on top of orgmunge! Have a great rest of your day/night!
No problem: https://github.com/durableOne/orgmunge/pull/10
Really happy that this library exists.
Thank you for providing a test case @crdoconnor, I got it to pass now. Please pull the changes and see if it works for you.
Thanks a lot :)
Great library though. I'm looking forward to building a calculator on top of it.
That was exactly my hope: that this would open the door for people to build other things on top of it.
I have been getting the following error when there is not a top-level heading:
Below are a few minimal, orgfile which will produce this above error:
The error is because the parse method is returning
None
when there is no top-level heading. I was trying to figure out how come that is and what to do to resolve this, but I cannot make head or tail of this yacc/ply grammar.