owlcollab / owlcollab/owltools

Error when saving as functional syntax

Open
#148 1 comment 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
Java
Stars
115
Forks
34
PR merge metrics
No merged PRs in 30d

Description

Trying to convert this file to functional syntax works with Protege but not with with OWLtools CLI

https://github.com/VirtualFlyBrain/VFB_owl/blob/master/src/owl/fbbt_vfb_ind_prc_nr.owl

owltools fbbt_vfb_ind_prc_nr.owl -o -f ofn vfb.ofn
=>
Feb 11, 2016 4:11:23 PM org.semanticweb.owlapi.util.CollectionFactory sortOptionally
WARNING: Misbehaving triple comparator, leaving triples unsorted: [ ... < long list of triples> ]
java.lang.IllegalArgumentException: Comparison method violates its general contract!
at java.util.ComparableTimSort.mergeLo(ComparableTimSort.java:740)
at java.util.ComparableTimSort.mergeAt(ComparableTimSort.java:477)
at java.util.ComparableTimSort.mergeCollapse(ComparableTimSort.java:402)
at java.util.ComparableTimSort.sort(ComparableTimSort.java:209)
at java.util.Arrays.sort(Arrays.java:1312)
at java.util.Arrays.sort(Arrays.java:1506)
at java.util.ArrayList.sort(ArrayList.java:1454)
at java.util.Collections.sort(Collections.java:141)
at org.semanticweb.owlapi.util.CollectionFactory.sortOptionally(CollectionFactory.java:111)
at org.coode.owlapi.functionalrenderer.OWLObjectRenderer.writeAxioms(OWLObjectRenderer.java:342)
at org.coode.owlapi.functionalrenderer.OWLObjectRenderer.visit(OWLObjectRenderer.java:265)
at uk.ac.manchester.cs.owl.owlapi.OWLOntologyImpl.accept(OWLOntologyImpl.java:1516)
at org.coode.owlapi.functionalrenderer.OWLFunctionalSyntaxOntologyStorer.storeOntology(OWLFunctionalSyntaxOntologyStorer.java:90)
at org.semanticweb.owlapi.util.AbstractOWLOntologyStorer.store(AbstractOWLOntologyStorer.java:182)
at org.semanticweb.owlapi.util.AbstractOWLOntologyStorer.storeOntology(AbstractOWLOntologyStorer.java:126)
at uk.ac.manchester.cs.owl.owlapi.OWLOntologyManagerImpl.saveOntology(OWLOntologyManagerImpl.java:1001)
at owltools.io.ParserWrapper.saveOWL(ParserWrapper.java:226)
at owltools.cli.CommandRunner.runSingleIteration(CommandRunner.java:3062)
at owltools.cli.CommandRunnerBase.run(CommandRunnerBase.java:76)
at owltools.cli.CommandRunnerBase.run(CommandRunnerBase.java:68)
at owltools.cli.CommandLineInterface.main(CommandLineInterface.java:12)

Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Reproduce the failure with the linked ontology and the shown owltools command, then inspect OWLObjectRenderer.writeAxioms and the OWL API sorting stack in the trace. Use ParserWrapper.java and CommandRunner.java as entry points; done means the conversion completes and writes vfb.ofn without the comparator exception.

Written by the indexing model from the issue text.

Assessment

Tech stack
java
Domain
cli
Issue type
Bug
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
45/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.