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

Missing sofa references are not checked and produce invalid XMIs #262

Open
Babyflum opened this issue Aug 18, 2022 · 0 comments
Open

Missing sofa references are not checked and produce invalid XMIs #262

Babyflum opened this issue Aug 18, 2022 · 0 comments

Comments

@Babyflum
Copy link

Is your feature request related to a problem? Please describe.
When executing code similar to the following:

annotation = SomeOtherType(feature=sub_annotation, ...)  
cas.add(annotation=annotation)  
cas.to_xmi("example.xmi")

the sub_annotation needs to be manually added to the cas (cas.add(annotation=sub_annotation)). If this isn't done, the resulting xmi is invalid because cassis won't set the sofa feature in the sub_annotation. However, there is no error message.

Describe the solution you'd like
cas.to_xmi() should be able to catch errors like this and determine if an xmi is invalid.

Describe alternatives you've considered
cas.typecheck() could also be used for this. Currently it only checks uima.cas.FSArray.

@reckart reckart added this to the Backlog milestone Jan 23, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants