-
Notifications
You must be signed in to change notification settings - Fork 3
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
Factorize base engine run into one function #19
Conversation
To unify treatment of multiple runs necessary between LatexConverter and PDFLatexConverter, factor the run loop into a separate function that is called from generate_pdf.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
TBH, I dislike the use of function ref. If you need to inject dependency, there should be a better way than using a variable of function ref.
Why not name _latex_run and _pdflatex_run as _base_run?
Anyhow, it is too hard for me to read this in browser, and also want to study with a bit of time so merge this, and I'd like to make some surface level changes.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks for the refactor the ugly part. I dislike the use of _base_runner = _latex_run
. It seems more straightforward use it as override functions
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I changed _base_runner part.
Great, thanks for that!!! I was contemplating a similar change, but again - wasn't sure about the original intention of naming the functions, so I kept them. The way it is now is much cleaner, thanks! |
To unify treatment of multiple runs necessary between LatexConverter and PDFLatexConverter, factor the run loop into a separate function that is called from generate_pdf.