Skip to content
This repository has been archived by the owner on Feb 14, 2025. It is now read-only.

Generate stub files from API docstrings and disseminate them via Conda #23

Open
FilippoOggionni opened this issue Jan 13, 2022 · 4 comments
Assignees
Labels
documentation Improvements or additions to documentation

Comments

@FilippoOggionni
Copy link
Member

While autocomplete is working on different IDEs (see tudat-team/tudatpy#22), we could also think of generating our own stub files for tudatpy - we already have the content from the API reference - and disseminate them through conda.

Low priority for now but it should not be difficult to implement, as we can simply reuse the content written for the API.

See tudat-team/tudatpy#22 for more details.

@FilippoOggionni FilippoOggionni added the documentation Improvements or additions to documentation label Jan 13, 2022
@FilippoOggionni FilippoOggionni self-assigned this Jan 13, 2022
@DominicDirkx
Copy link
Member

Is this still relevant? With the autocomplete working, perhaps we can close this.

@FilippoOggionni
Copy link
Member Author

I think this is still relevant. For now, we have the autocomplete working, but the next step would be the have all the documentation currently in the API reference website also available locally. This can be done by using the content of the API docstring to generate stubs and disseminate them through conda. Not super important, but it would be elegant to have it locally as well 🙂

@Pocket-titan
Copy link

Just commenting to say autocomplete/intellisense for tudatpy doesn't work out-of-the-box in VSCode at the moment, but I was able to generate usable type stubs using pybind11-stubgen (pip install pybind11-stubgen && pybind11-stubgen tudatpy in conda environment, then copy stubs over to package location using cp -RT). They are not perfect and there are some errors, but might be helpful for any future implementers.

@DominicDirkx
Copy link
Member

Thanks! @alfonsoSR and @alopezrivera have been working on this, perhaps they can give an update?

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
documentation Improvements or additions to documentation
Projects
None yet
Development

No branches or pull requests

3 participants