Skip to content

Link variables to methods (and back) #293

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

Open
ravwojdyla opened this issue Oct 1, 2020 · 0 comments
Open

Link variables to methods (and back) #293

ravwojdyla opened this issue Oct 1, 2020 · 0 comments
Labels
documentation Improvements or additions to documentation process + tools

Comments

@ravwojdyla
Copy link
Collaborator

ravwojdyla commented Oct 1, 2020

Follow up from #276.

#276 comes with doc links from methods to sgkit.variables.

We would like:

  • to have links between variables and methods both ways
  • the links available both in doc and runtime

Some approaches to explore:

  • use inspect/reflection to look at the signature and docstring as a heuristic to find links
  • add a decorator for "sgkit computation" methods that would require a set of variable_spec inputs and variable_spec outputs, note that it would not require the actual names of them just the specs. Having that it would be straightforward to generate links. Such decorator could also validate some best practices like: method returning a Dataset, merge parameter, keyword parameters etc
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
documentation Improvements or additions to documentation process + tools
Projects
None yet
Development

No branches or pull requests

1 participant