PistoiaHELM / HELMWebEditor

Web browser based editor for drawing HELM macromolecules.
MIT License
20 stars 10 forks source link

Can't create a new monomer #220

Open ClairePA opened 6 years ago

ClairePA commented 6 years ago

I click on the + button to create a new monomer and the dialogue box appears. I enter information and click save.

I see the following error message.

image

AnneMund commented 6 years ago

409 indicates a conflict, so it seems that the MonomerService (erroneously) detects that the same monomer structure has been entered before.

ClairePA commented 6 years ago

I just tried with several different structures including one that definitely has not been used before. I also changed the ID to symbols that have also definitely not been used before and I still get a 409 error. Any ideas?

image

AnneMund commented 6 years ago

I've tried to track down this bug; there is a more detailed error message available via the swagger page that is not displayed in the WebEditor. The exact error message is that no smiles could be generated: grafik

I've tried the exact same structure in my local debugging environment and cannot reproduce it there, which makes tracking it down a lot harder, unfortunately.

AnneMund commented 6 years ago

Okay, this is strange; I've tried it again with the MonomerService deployed on a local docker instance and I'm getting different behaviour than the test server; Docker here at quattro: grafik

Test site at Scilligence: grafik

@scilligence Have you changed any chemistry settings, by any chance? Or is there some other configuration which could differ between the systems?

ClairePA commented 6 years ago

Additional point - can the webeditor display the full error code to help debugging?

ClairePA commented 6 years ago

Retested using the webeditor on the new Pistoia Docker image http://webeditor.openhelm.org:8000/hwe/examples/MonomerLibApp.htm and I get the same 409 error.

AnneMund commented 6 years ago

This is getting really strange; I've pulled the docker file that is in use for the openhelm.org test site and deployed it at our docker host: grafik

But again, if I use the exact same input on this system as well as the openhelm.org site, I get different behaviour. It works on our docker host: grafik

ClairePA commented 6 years ago

Really odd. So you see the problem on http://webeditor.openhelm.org:8000/hwe/examples/MonomerLibApp.htm but not on yours despite the fact that they should be the same?

AnneMund commented 6 years ago

Yes, with the exact same docker image and input. I had to do the screenshots, because I still feel like "this should not happen".

ClairePA commented 6 years ago

The webservices issues have been fixed and we have the latest version of the webservices and webeditor at http://webeditor.openhelm.org:8000/hwe/examples/App.htm.

This is now exclusively a webeditor problem. I create the following monomer image

On clicking save in the webeditor, I get the following message: image

scilligence commented 6 years ago

I cannot reproduce the "Expected ';'" error above, but did get this error message:

"Monomer has no Smiles; Smiles could not be generated from Molfile and R-Groups"

Markus -

Is there any change in the Monomer Web Service requiring SMILES now? SMILES can be generated from the input Molfile on the server side.

scilligence commented 6 years ago

Just upgrade web services to latest versions, but the problem is not fixed:

Monomerservice 1.1.5 https://oss.sonatype.org/content/repositories/releases/org/pistoiaalliance/helm/helm2-monomerservice/1.1.5/helm2-monomerservice-1.1.5.war Webservice 3.0.2 https://oss.sonatype.org/content/repositories/releases/org/pistoiaalliance/helm/helm2-webservice/3.0.2/helm2-webservice-3.0.2.war

image

ClairePA commented 6 years ago

Hi Tony, could you try it again with the natural analogue as - instead of x. The webservices are expecting x.

I think there could be another issue, but lets sort out one thing at a time. Using - as the natural analogue will show you the parsing error.

Can you make the next HELM team meeting, so we can go through the issues together? I think we need to do this in order to identify where the problems are.

scilligence commented 6 years ago

Tried using - as natural analogue, and I got the same error message.

ClairePA commented 6 years ago

Hmm, I think this is why we need to talk it through. I get the parsing error when using -, so we need to check the other parameters and sort this out together.

ClairePA commented 6 years ago

OK, I have done a side-by-side comparison between 54.83.135.171 and webeditor.openhelm.org and there is still a difference between the set-ups. Both use the same monomerservice and webservice versions. I used this example monomer (with no SMILES to check that SMILES can be generated correctly): { "symbol": "1113test", "name": "1113test", "molfile": "Untitled Document-1\n ChemDraw11261810222D\n\n 8 8 0 0 0 0 0 0 0 0999 V2000\n -1.0717 0.0000 0.0000 C 0 0 0 0 0 0 0 0 0 0 0 0\n -1.0717 -0.8250 0.0000 C 0 0 0 0 0 0 0 0 0 0 0 0\n -0.3572 -1.2375 0.0000 C 0 0 0 0 0 0 0 0 0 0 0 0\n 0.3572 -0.8250 0.0000 C 0 0 0 0 0 0 0 0 0 0 0 0\n 0.3572 0.0000 0.0000 C 0 0 0 0 0 0 0 0 0 0 0 0\n -0.3572 0.4125 0.0000 C 0 0 0 0 0 0 0 0 0 0 0 0\n -0.3572 1.2375 0.0000 R1 0 0 0 0 0 0 0 0 0 0 0 0\n 1.0717 0.4125 0.0000 I 0 0 0 0 0 0 0 0 0 0 0 0\n 1 2 2 0 \n 2 3 1 0 \n 3 4 2 0 \n 4 5 1 0 \n 5 6 2 0 \n 6 1 1 0 \n 6 7 1 0 \n 5 8 1 0 \nM END\n", "rgroups": [ { "id": 0, "alternateId": "R1-H", "label": "R1", "capGroupName": "H", "capGroupSMILES": "[*:1][H]" } ], "smiles": "", "polymerType": "CHEM", "createDate": "Mon Sep 17 16:11:56 UTC 2018", "naturalAnalog": "-", "monomerType": "Undefined" }

When I use the PUT method at http://webeditor.openhelm.org:8000/HELM2MonomerService/, I get a successful 200 response.

If I try the same input at http://54.83.135.171//HELM2MonomerService/ I get 409, image

so there is something different about the setups. Full details about how we set our test server up are in the Docker file at https://github.com/PistoiaHELM/pistoiahelm.github.com/tree/master/docker. Please check against the Scilligence environment.

Despite the fact that the backend at http://webeditor.openhelm.org:8000/HELM2MonomerService/ works, trying to create the same monomer through http://webeditor.openhelm.org:8000/hwe/examples/MonomerLibApp.htm still generates an error.

scilligence commented 6 years ago

Is there a way we can check the versions of the two installations?

ClairePA commented 6 years ago

Yes, The version number for the HELM2monomer service is visible in the Swagger page http://webeditor.openhelm.org:8000/HELM2MonomerService/ for our dev server:

image

and the version number for the HELM2monomerservice is available using the Swagger page at http://webeditor.openhelm.org:8000/WebService/HowToUse.html for our dev server:

image

image

but the installation at http://54.83.135.171/ seems to use the right versions, so there must be some other difference. It is really odd. Is there something different about the monomer store? The Dockerfile https://github.com/PistoiaHELM/pistoiahelm.github.com/tree/master/docker shows our precise set up.