[InterMine Dev] ClassShadow.primaryIdentifier snafu

Sam Hokin shokin at ncgr.org
Fri Oct 9 19:17:00 BST 2020

Yes: since the "other mine" links presume that the other mine classes have the same attributes, we should impose that it only work 
for classes in the core model (which QTL obviously is not), which is what makes sense for "friendly" mines. (My mines are only 
partially friendly, sorta like a girl that's nice to you when her friends aren't around.)

So, I like the choice of "don't show friendly mines if this class does not have primaryIdentifier" or even better "don't show 
friendly mines if this class doesn't extend Annotatable." Issue on its way.

On 10/9/20 10:43 AM, daniela at intermine.org wrote:
> I think we can fix it....but we need a way to know which is the key field which can be used fo the other mine link OR decide to no 
> create the other mine link if there is not primary identifier
> Sam, could you please add a ticket for that?
> THAnKS!!!
> Have a nice weekend!
> Daniela
>> I used to use QTL.primaryIdentifer. :) I've moved a number of
>> "primaryIdentifier" attributes to "identifier" in accordance with my
>> new standard that things that don't extend Annotatable get
>> "identifier" instead. Plus, a lot of SO entries use "identifier", like
>> strain (http://semanticscience.org/resource/SIO_010055), which I
>> figure I'll keep consistent.
>> If you recall, Julie (or you?) initially wanted to use
>> Annotatable.identifier, but that would have broken all of the existing
>> BioEntity code. So Julie wisely didn't. I find it handy to keep track
>> of which keys belong to Annotatables and which do not.
>> On 10/9/20 5:13 AM, daniela at intermine.org wrote:
>>> Hi Sam,
>>> sorry for the issue.
>>> Initially I was thinking that the issue was related to some work I have done to create the Share link button.
>>> BUt after looking at the code it seems that the otherMinesLinks.jsp page uses the primaryIdentifer (se here 
>>> https://github.com/intermine/intermine/blob/dev/intermine/webapp/src/main/webapp/otherMinesLink.jsp#L32).
>>> In fact, if you look at the source code of the QTL report page, it seems it breaks on friendlyMines section.
>>> I will add a ticket for that.
>>> Not sure why it worked before??!!!
>>> Daniela
>>>> Hi Sam
>>>> Maybe related or not to your error, I have been having problems with a
>>>> class called SOTerm (which I changes to WBSOTerm at one point), where
>>>> the builddb process was complaining of a primaryIdentifier not present
>>>> when my first attribute was called just identifier. I changed to
>>>> primaryIdentifier and even after many clean installl etc commands, I
>>>> was still not able to create the class in the model, and when it’s
>>>> created it goes to the opposite name that I am setting on my additions
>>>> XML. I wean’t able to locate the root of the problem.
>>>> I am doing some more tests soon, and I plan to send to InterMine and the list.
>>>> Cheers
>>>> Paulo
>>>>> On Oct 8, 2020, at 11:33 AM, Sam Hokin <shokin at ncgr.org> wrote:
>>>>> I've got a bug in one of my mines that I simply cannot figure out. I have a class, which does not extend any other classes, 
>>>>> called QTL, and here's how it's declared in dbmodel/build/resources/main/genomic_model.xml:
>>>>> <class name="QTL" is-interface="true" term="http://purl.obolibrary.org/obo/SO:0001645">
>>>>>        <attribute name="lod" type="java.lang.Double"/>
>>>>>        <attribute name="likelihoodRatio" type="java.lang.Double"/>
>>>>>        <attribute name="intervalDescription" type="java.lang.String"/>
>>>>>        <attribute name="end" type="java.lang.Double"/>
>>>>>        <attribute name="identifier" type="java.lang.String"/>
>>>>>        <attribute name="start" type="java.lang.Double"/>
>>>>>        <reference name="organism" referenced-type="Organism"/>
>>>>>        <reference name="phenotype" referenced-type="Phenotype" reverse-reference="QTLs"/>
>>>>>        <reference name="geneticMap" referenced-type="GeneticMap" reverse-reference="QTLs"/>
>>>>>        <reference name="linkageGroup" referenced-type="LinkageGroup" reverse-reference="QTLs"/>
>>>>>        <collection name="dataSets" referenced-type="DataSet"/>
>>>>> </class>
>>>>> Note that is has an attribute called "identifier" and no attribute called "primaryIdentifier". This is my practice for classes 
>>>>> which don't extend Annotatable/BioEntity/SequenceFeature.
>>>>> But whenever I build the mine and look at a QTL report page, it stops after the header and I get the following in the Tomcat 
>>>>> localhost log (and no client-side error in the Javascript console):
>>>>> 08-Oct-2020 11:27:28.121 SEVERE [ajp-nio-8009-exec-193] org.apache.catalina.core.StandardWrapperValve.invoke Servlet.service() 
>>>>> for servlet [action] in context with path [/soymine] threw exception [An exception occurred processing [/layout.jsp] at line [93]
>>>>> 90:       <tiles:insert page="/contextHelp.jsp"/>
>>>>> 91:
>>>>> 92:       <tiles:get name="body"/>
>>>>> 93:
>>>>> 94: <script type="text/javascript">
>>>>> 95: jQuery(document).ready(function() {
>>>>> 96:   jQuery("p#contactUsLink").toggle();
>>>>> Stacktrace:] with root cause
>>>>>     javax.el.PropertyNotFoundException: Property [primaryIdentifier] not found on type [org.intermine.model.bio.QTLShadow]
>>>>> So this is a server-side error, but where on earth is this desired QTLShadow.primaryIdentifier property coming from? It looks 
>>>>> like it may be associated with a tile, but a grep of the entire mine tree shows no instance of QTL and primaryIdentifier. This 
>>>>> is really mysterious! Thanks in advance for tips!
>>>>> _______________________________________________
>>>>> dev mailing list
>>>>> dev at lists.intermine.org
>>>>> https://lists.intermine.org/mailman/listinfo/dev
>>>> _______________________________________________
>>>> dev mailing list
>>>> dev at lists.intermine.org
>>>> https://lists.intermine.org/mailman/listinfo/dev

More information about the dev mailing list