Simple file.py -> file.md use case #241
-
Hi there, I'm still using pydoc-markdown version 2.1.0.post1 for my
A while back it seemed that this use-case had broken with the newer versions and and it seems pydoc-markdown does more than I want it to. I just want a simple conversion for a file like the old behavior. Is this possible with the newer versions? The reason I ask, is I started utilizing type-hinting and version 2.1.0.post1 doesn't seem to like type annotations:
I'm on python 3.8 and I updated my yapf library to the latest release. It seems like lib2to3 may be the culprit, but I'm not sure if the newer versions of pydoc-markdown call lib2to3 in a different way or if I can monkey patch the old version of pydoc-markdown to support type hints. Any help would be appreciated, thanks! |
Beta Was this translation helpful? Give feedback.
Replies: 2 comments
-
I was able to get something similar by using this command line in the latest version (4.5.0)
However the conversion is not the same as the older versions. For example, in the older version if I indented lines with four spaces in the docstrings I would consistently get raw monospaced code blocks. With the new version it doesn't reliably render these code blocks. I didn't see in the documentation where I could configure the behavior of the markdown renderer. Could someone please point me in the right direction? |
Beta Was this translation helpful? Give feedback.
-
I'm getting closer. I was able to approximate the old behavior with the following command-line:
Basically it looks like I had to override the default configuration which includes the "smart" processor. In my case I want to hardcode the processor to |
Beta Was this translation helpful? Give feedback.
I'm getting closer. I was able to approximate the old behavior with the following command-line:
Basically it looks like I had to override the default configuration which includes the "smart" processor. In my case I want to hardcode the processor to
pydocmd
. I'll keep playing with it, but I think I'm getting the hang of it now.