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

Add lightning argument parser #246

Merged
merged 13 commits into from
Sep 23, 2020
Merged

Conversation

nateraw
Copy link
Contributor

@nateraw nateraw commented Sep 22, 2020

Before submitting

  • Was this discussed/approved via a Github issue? (no need for typos and docs improvements)
  • Did you read the contributor guideline, Pull Request section?
  • Did you make sure to update the docs?
  • Did you write any new necessary tests?

What does this PR do?

Copy code over from #3537 to proof out the idea here before implementing directly in lightning.

PR review

Anyone in the community is free to review the PR once the tests have passed.
If we didn't discuss your PR in Github issues there's a high chance it will not be merged.

Did you have fun?

Make sure you had fun coding 🙃

@mergify mergify bot requested a review from Borda September 22, 2020 22:18
@codecov
Copy link

codecov bot commented Sep 22, 2020

Codecov Report

Merging #246 into master will increase coverage by 0.17%.
The diff coverage is 96.15%.

Impacted file tree graph

@@            Coverage Diff             @@
##           master     #246      +/-   ##
==========================================
+ Coverage   88.31%   88.49%   +0.17%     
==========================================
  Files          70       71       +1     
  Lines        3407     3485      +78     
==========================================
+ Hits         3009     3084      +75     
- Misses        398      401       +3     
Flag Coverage Δ
#cpu 32.36% <20.77%> (-0.27%) ⬇️
#pytest 32.36% <20.77%> (-0.27%) ⬇️
#unittests 87.74% <96.15%> (+0.19%) ⬆️

Flags with carried forward coverage won't be shown. Click here to find out more.

Impacted Files Coverage Δ
pl_bolts/utils/arguments.py 96.15% <96.15%> (ø)

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update c2cdad7...0649e89. Read the comment docs.

@pep8speaks
Copy link

pep8speaks commented Sep 22, 2020

Hello @nateraw! Thanks for updating this PR.

Line 58:97: E231 missing whitespace after ','
Line 78:103: E231 missing whitespace after ','

Comment last updated at 2020-09-23 01:10:58 UTC

@nateraw nateraw marked this pull request as ready for review September 23, 2020 00:11
@nateraw
Copy link
Contributor Author

nateraw commented Sep 23, 2020

windows build is broken for unrelated reason it seems. we'll fix that in separate PR

pl_bolts/utils/arguments.py Show resolved Hide resolved
tests/utils/test_arguments.py Show resolved Hide resolved
Copy link
Contributor

@teddykoker teddykoker left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nice work Nate!

@nateraw nateraw merged commit c60e142 into Lightning-Universe:master Sep 23, 2020
@Borda Borda added the enhancement New feature or request label Sep 23, 2020
else:
root_cls = cls

blacklisted_args = ["self", "args", "kwargs"]
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

this shall be taken from the Function/method footprint

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.

5 participants