Add import statements to tutorials
Feature request
- A description of the feature you would like to have
I suggest to add the import statements to the tutorial sections.
- If relevant, the context that you are in. What are you trying to achieve?
I am a new user of pdfminer.six (wohoo) and I tried to follow the tutorial, but had a hard time as the import statements are missing.
eg here https://pdfminersix.readthedocs.io/en/latest/tutorial/highlevel.html
I certainly have found the excellent API documentation later, but it took some time.
Also, when I had a look in the source code of the docs, I saw that there is a test setup directive included in order to make the doc tests pass.
.. testsetup::
import sys
from pdfminer.high_level import extract_text_to_fp, extract_text
So, doc tests need import statements, humans (at least beginners) need import statements, why not include them in the tutorial sections?
I'd like to create a PR if you are ok with my suggestion.
Thanks for the tip! :+1: