Skip to content
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

exclude passed to {func} from docments by passing verbose=False to delegates #464

Merged
merged 1 commit into from
Aug 14, 2022

Conversation

seeM
Copy link
Contributor

@seeM seeM commented Aug 14, 2022

@seeM seeM added the enhancement New feature or request label Aug 14, 2022
@review-notebook-app
Copy link

Check out this pull request on  ReviewNB

See visual diffs & provide feedback on Jupyter Notebooks.


Powered by ReviewNB

@seeM seeM changed the title exclude passed to {func} from docments by passing verbose=True to delegates exclude passed to {func} from docments by passing verbose=False to delegates Aug 14, 2022
@seeM seeM force-pushed the delegates-docments-verbose branch from ff77f6c to db13d78 Compare August 14, 2022 00:27
@jph00
Copy link
Contributor

jph00 commented Aug 14, 2022

There isn't really enough docs here (and there's no PR description) for me to know what's going on, so I don't have anything intelligent to say about this, sorry @seeM ! Maybe you could add some more docs to the notebook to explain this?

@seeM
Copy link
Contributor Author

seeM commented Aug 14, 2022

@jph00 Sorry about that! I want to use delegates to a private function without affecting show_doc. Specifically, I wanted to remove all of the "passed to apply_defaults" in nbdev_create_config's docs:

image

The approach taken here was to add a verbose argument to delegates, which is set in a dict at from_func.__delopts__. Later, docments uses that value to decide whether to include "passed to to.__name__" or not.

I documented the arg on delegates but in hindsight "# Include to in docments?" isn't very informative. I also added a small example to the docments nb but it might've gotten lost among the other smaller doc changes I made there - or does it need to be made more informative too?

image

As always, I'm very happy to change/improve/scrap any of this :) don't hold back!

@jph00
Copy link
Contributor

jph00 commented Aug 14, 2022

OK great all clear! :)

@jph00 jph00 merged commit 101c4f6 into AnswerDotAI:master Aug 14, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants