-
Notifications
You must be signed in to change notification settings - Fork 27
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
Return type annotation for Problem and Domain transformers. Fixed requirements type annotation in DomainTransformer. #102
Return type annotation for Problem and Domain transformers. Fixed requirements type annotation in DomainTransformer. #102
Conversation
…uirements type annotation
Codecov ReportAll modified and coverable lines are covered by tests ✅
❗ Your organization needs to install the Codecov GitHub app to enable full functionality. Additional details and impacted files@@ Coverage Diff @@
## main #102 +/- ##
==========================================
+ Coverage 88.10% 88.35% +0.24%
==========================================
Files 25 25
Lines 1791 1794 +3
Branches 332 333 +1
==========================================
+ Hits 1578 1585 +7
+ Misses 154 149 -5
- Partials 59 60 +1
Flags with carried forward coverage won't be shown. Click here to find out more.
|
Thanks for the fixes here! You can find more details on the blocking error here: https://github.com/AI-Planning/pddl/actions/runs/7240077134/job/19740335600?pr=102 |
Hi @MichaelJFishman, thank you very much for this PR 🙂 I would like to push some commits to this PR. Could you please "Allow edits from maintainers"? (see this link) |
Thanks for the commits! It looks like "Allow edits from maintainers" is already enabled on this PR. Are you still unable to edit it? Edit: @marcofavorito |
This commit updates the __call__ method of both DomainParser and ProblemParser classes in such a way that sys.tracebacklimit is not overwritten to 'None' if it has been already set by the caller.
Confirmed, thanks :) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM, thanks @MichaelJFishman !
Proposed changes
A few type annotations. I didn't add any annotations to
parse_problem
andparse_domain
, because I didn't want toDomain
andProblem
imports to the__init__.py
.Fixes
Adds return type annotation for Problem and Domain transformers, by specifying that type parameter when subclassing
Transformer
. Also annotated thatDomain.__call__
andProblem.__call__
returnDomain
andProblem
, respectively.Fixed
_requirements
type annotation inDomainTransformer
.Types of changes
What types of changes does your code introduce?
Put an
x
in the boxes that applyChecklist
Put an
x
in the boxes that apply.I ran the tests and got the following output. I can't tell from this where mypy/evaluation failed.