-
Notifications
You must be signed in to change notification settings - Fork 37
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
FeatureData[Taxonomy] discrepancies between Python and CLI #136
Comments
One of the reasons we didn't implement this initially is that metadata merging is also supported, and so we would either need to accept a tuple of metadata-like objects, or just stick with metadata. It is the current opinion of the framework that metadata is a primitive and so it is on the interface to get that from the user in some way. |
Fair enough, it was just confusing to see that this happened. Also, there were no examples in the documentation about this, so it took some fiddling to figure this out. |
Your code works but unfortunately calling I've messed this up before previously, and also ran into the case @ElDeveloper was originally reporting where I've expected the Artifact API to transparently turn an Perhaps |
This is really what I was expecting. I hadn't even considered that provenance would not be preserved, this probably warrants a warning(?) though it sounds a bit tough to figure out when to raise and when not to raise a warning. |
A warning would be better than the current behavior, but ideally you'd be able to call |
Removed `Metadata.from_artifact` in favor of `Artifact.view(Metadata)`, which now tracks the source artifact (important for provenance). Discussed with @ebolyen; there's no need to have two APIs that do the same thing, and using the view API is preferred since `Metadata` doesn't need to be special-cased. Related to discussion in qiime2/q2-feature-table#136 regarding `Artifact.view(Metadata)` not tracking the source artifact, which is now fixed.
#366) Removed `Metadata.from_artifact` in favor of `Artifact.view(Metadata)`, which now tracks the source artifact (important for provenance). Discussed with @ebolyen; there's no need to have two APIs that do the same thing, and using the view API is preferred since `Metadata` doesn't need to be special-cased. Related to discussion in qiime2/q2-feature-table#136 regarding `Artifact.view(Metadata)` not tracking the source artifact, which is now fixed.
Regarding I'm leaving this issue open because the original topic was about having |
When I filter features based on taxonomy information using the Python API, I get the following error:
Which makes sense because the artifact is not a subtype of metadata. Turns out I have to do view the artifact as Metadata in order for it to work as expected:
The main discrepancy comes from using this same action via the CLI, which works fine without any conversions etc:
The text was updated successfully, but these errors were encountered: