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
Add an 'include-read'
event
#11657
Add an 'include-read'
event
#11657
Conversation
I'm leaning towards the generated docname approach -- would appreciate your opinion @mgeier, as this solves the 'docname can be None' issue, but introduces docnames that don't work with A |
# Conflicts: # CHANGES
I think inventing a string (like If a string is returned, I would expect that string to be the document name. I'm fine with returning |
A good point -- I've also re-visited the original issue (#10678) and have thusly changed my mind -- this PR now introduces a new I assume this would work for your purposes? A |
That sounds much cleaner!
Yes, sure, an additional event will not break anything if I don't use it, right? My extension |
I don't know if anyone needs this, but you could pass the parent document name to the event handler? |
Good shout! |
Thanks @AA-Turner, this is a good solution! |
closes #11648, #11643, #11620
cc: @mgeier @lmoureaux
The easy option would be to set the docname to
self.env.docname
(the current document being read), but this might throw off extensions that expect to only have"source-read"
called exactly once per document.Please test / let me know thoughts!
A