-
Notifications
You must be signed in to change notification settings - Fork 61
small fix to #255 #257
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
small fix to #255 #257
Conversation
Codecov Report
@@ Coverage Diff @@
## master #257 +/- ##
==========================================
+ Coverage 86.44% 86.51% +0.06%
==========================================
Files 19 19
Lines 3047 3047
Branches 815 815
==========================================
+ Hits 2634 2636 +2
+ Misses 258 256 -2
Partials 155 155
Continue to review full report at Codecov.
|
FYI this warning showed up when I ran
|
Yeah, I agree that we probably want |
Got it. |
so the problem is with this simple line of code that it gives various errors or warning depending on the type of object:
any idea if there is a way to avoid all the warnings without checking the type of |
I don't think you can avoid it. What are all of the cases that you're trying to catch? If you want exactly the empty string, then |
the catch22 is that this arises for numpy, but numpy is not a dependency of pydra |
so we would even have to test if numpy can be imported first. but may not be a bad thing to do. |
alternatively, we can follow @effigies suggestion and check if something is the specific object first. I tried to do it when working on the pr, but I wasn't sure what is the best way of checking if something is a string or a path (all types of python paths). Any idea? I could use |
just ignored what i said, we are using |
Types of changes
Summary
small fix of is _existing_file
Checklist
(we are using
black
: you canpip install pre-commit
,run
pre-commit install
in thepydra
directoryand
black
will be run automatically with each commit)Acknowledgment