Skip to content

scientific-python/docstub

docstub

Note

In early development! Docstub is not feature-complete or thoroughly tested yet. Its behavior, configuration or command line interface may change significantly between releases.

docstub is a command-line tool to generate Python stub files. It extracts necessary type information from NumPyDoc style docstrings.

Many packages in the scientific Python ecosystem already describe expected parameter and return types in their docstrings. Docstub aims to take advantage of these and help with the adoption of type annotations. It does so by supporting widely used readable conventions such as array of dtype or iterable of int(s) which are translated into valid type annotations.

Getting started & quick links

Specific guides:

Our release notes (latest) are in docs/release_notes/.

Our project follows Scientific Python's Code of Conduct.

Acknowledgements

Thanks to docs2stubs by which this project was heavily inspired and influenced.

And thanks to CZI for supporting this work with an EOSS grant.

About

Generate Python stub files from docstrings

Resources

License

Code of conduct

Contributing

Security policy

Stars

Watchers

Forks

Contributors 5

Languages