remove experimental ontology support (#2300)

* remove experimental ontology support

* lint

* remove ontologies from unit tests

* additional test changes
This commit is contained in:
Bruce Martin
2021-07-14 07:23:38 -07:00
committed by GitHub
parent 45a8984223
commit e334fbe96e
35 changed files with 28 additions and 269 deletions
@@ -3,7 +3,7 @@ import { Colors } from "@blueprintjs/core";
import { AnnotationsHelpers } from "../../util/stateManager";
export function isLabelErroneous(label, metadataField, ontology, schema) {
export function isLabelErroneous(label, metadataField, schema) {
/*
return false if this is a LEGAL/acceptable category name or NULL/empty string,
or return an error type.
@@ -12,10 +12,9 @@ export function isLabelErroneous(label, metadataField, ontology, schema) {
/* allow empty string */
if (label === "") return false;
/* check for label syntax errors, but allow terms in ontology */
const termInOntology = ontology?.termSet.has(label) ?? false;
/* check for label syntax errors */
const error = AnnotationsHelpers.annotationNameIsErroneous(label);
if (error && !termInOntology) return error;
if (error) return error;
/* disallow duplicates */
const { obsByName } = schema.annotations;