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

New Types + Variable Resolver #272

Merged
merged 7 commits into from Jan 17, 2023
Merged

Conversation

ncilfone
Copy link
Contributor

What does this PR do?

  • Added support for new fundamental types: (1) file: this is an overload of a str that verifies file existence and (r/w) access (2) directory: this is an overload of a str that verifies directory existence, creation if not existing, and (r/w) access
  • Added support for resolving value definitions from references to other defined variables with the following syntax,${spock.var:SpockClass.defined_variable}. Closes Interpolation and Accessing environment variables and other resolvers inside the config.yaml similar to OmegaConf #243
  • Deprecated support for List of repeated @spock decorated classes.
  • Updated docs.
  • Fixes detecting cycles in graphs.
  • Fixes Nested List, Tuple error #260 and issues with Tuples enforcing len and checking type.
  • Bumped black support for 3.10.
  • Added pre-commit hooks.
  • Updated linter.

Checklist

  • Did you adhere to PEP-8 standards?
  • Did you run black and isort prior to submitting your PR?
  • Does your PR pass all existing unit tests?
  • Did you add associated unit tests for any additional functionality?
  • Did you provide code documentation (Google Docstring format) whenever possible, even for simple functions or classes?
  • Did you add necessary documentation to the website?

…ations. updated docs. Fixes detecting cycles in graphs. Fixes fidelity#260 and issues with Tuples enforcing len and checking type. bumped black support for 3.10. added pre-commit hooks. updated linter.
…ss). swapped to direct type declaration for file and directory as subclasses of str
@coveralls
Copy link

coveralls commented Jan 13, 2023

Pull Request Test Coverage Report for Build 3912745148

Warning: This coverage report may be inaccurate.

This pull request's base commit is no longer the HEAD commit of its target branch. This means it includes changes from outside the original pull request, including, potentially, unrelated coverage changes.

Details

  • 432 of 453 (95.36%) changed or added relevant lines in 11 files are covered.
  • 28 unchanged lines in 6 files lost coverage.
  • Overall coverage decreased (-0.8%) to 95.166%

Changes Missing Coverage Covered Lines Changed/Added Lines %
spock/backend/resolvers.py 74 75 98.67%
spock/utils.py 5 6 83.33%
spock/backend/typed.py 15 17 88.24%
spock/graph.py 164 168 97.62%
spock/backend/validators.py 81 94 86.17%
Files with Coverage Reduction New Missed Lines %
spock/backend/builder.py 1 99.11%
spock/graph.py 1 97.41%
spock/backend/resolvers.py 2 97.37%
spock/backend/saver.py 4 95.65%
spock/backend/utils.py 5 92.92%
spock/backend/payload.py 15 82.88%
Totals Coverage Status
Change from base Build 2511258184: -0.8%
Covered Lines: 2461
Relevant Lines: 2586

💛 - Coveralls

@ncilfone
Copy link
Contributor Author

@brianwarner Need reviewer approval for merge to master. Also can't cut a new release via a tag (which will trigger the build/push to pypi) since I don't have permissions. This should be the 3.0 release as there is a non backwards compat feature.

Any chance you've figured out Fidelity's view on outside collaborators being able to review/merge/release? Need a path to sustainability here as I've picked back up development... Trying to avoid forking spock and maintaining it outside of Fidelity OSS

@ncilfone ncilfone marked this pull request as draft January 13, 2023 16:31
@ncilfone ncilfone marked this pull request as ready for review January 17, 2023 13:46
@mmalouane mmalouane merged commit 8bd55a4 into fidelity:master Jan 17, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
3 participants