Unknown error instead of "Entity does not exist error"
I recently tried inserting a large container using the crawler, but forgot to insert the data model first.
The server responded with:
Traceback (most recent call last):
File "/home/salexan/.local/bin/crawler2.0", line 33, in <module>
sys.exit(load_entry_point('newcrawler', 'console_scripts', 'crawler2.0')())
File "/home/salexan/Projekte/CaosDB/caosdb-newcrawler/src/newcrawler/crawl.py", line 780, in main
crawler.synchronize(commit_changes=True)
File "/home/salexan/Projekte/CaosDB/caosdb-newcrawler/src/newcrawler/crawl.py", line 330, in synchronize
return self._synchronize(self.updateList, commit_changes)
File "/home/salexan/Projekte/CaosDB/caosdb-newcrawler/src/newcrawler/crawl.py", line 631, in _synchronize
self.execute_inserts_in_list(to_be_inserted)
File "/home/salexan/Projekte/CaosDB/caosdb-newcrawler/src/newcrawler/crawl.py", line 584, in execute_inserts_in_list
db.Container().extend(to_be_inserted).insert()
File "/home/salexan/Projekte/CaosDB/caosdb-pylib/src/caosdb/common/models.py", line 3472, in insert
http_response = con.insert(
File "/home/salexan/Projekte/CaosDB/caosdb-pylib/src/caosdb/connection/connection.py", line 551, in insert
http_response = self._http_request(
File "/home/salexan/Projekte/CaosDB/caosdb-pylib/src/caosdb/connection/connection.py", line 575, in _http_request
return self._retry_http_request(method=method, path=path,
File "/home/salexan/Projekte/CaosDB/caosdb-pylib/src/caosdb/connection/connection.py", line 615, in _retry_http_request
_handle_response_status(http_response)
File "/home/salexan/Projekte/CaosDB/caosdb-pylib/src/caosdb/connection/connection.py", line 416, in _handle_response_status
raise HTTPServerError(body=body)
caosdb.exceptions.HTTPServerError: An unexpected server error has occurred.
SRID = e7d63ee6-9cf2-4d5c-94f7-dcd971fa9b28
Please report this server error to and include the SRID into your report.
... although, on the server-side things seemed pretty clear:
linkahead | RESPONSE: HTTPS/1.1 - Internal Server Error (500) - The server encountered an unexpected condition which prevented it from fulfilling the request
linkahead | RESPONSE ENTITY:<?xml version="1.0" encoding="UTF-8"?>
linkahead | <?xml-stylesheet type="text/xsl" href="https://localhost:10443/webinterface/1646744029/webcaosdb.xsl" ?>
linkahead | <Response username="admin" realm="PAM" srid="e7d63ee6-9cf2-4d5c-94f7-dcd971fa9b28" timestamp="1646744821061" baseuri="https://localhost:10443">
linkahead | <noscript>
linkahead | <h1>Please enable JavaScript!</h1>
linkahead | </noscript>
linkahead | <UserInfo username="admin" realm="PAM">
linkahead | <Roles>
linkahead | <Role>administration</Role>
linkahead | </Roles>
linkahead | </UserInfo>
linkahead | <Error code="0" description="An unexpected server error has occurred.">SRID = e7d63ee6-9cf2-4d5c-94f7-dcd971fa9b28
linkahead |
linkahead | Please report this server error to and include the SRID into your report.</Error>
linkahead | </Response>
linkahead |
linkahead | org.caosdb.server.database.exceptions.EntityDoesNotExistException: null
linkahead | at org.caosdb.server.database.backend.transaction.GetIDByName.execute(GetIDByName.java:69) ~[caosdb-server-0.8.0-SNAPSHOT-jar-with-dependencies.jar:?]
linkahead | at org.caosdb.server.database.BackendTransaction.executeTransaction(BackendTransaction.java:152) ~[caosdb-server-0.8.0-SNAPSHOT-jar-with-dependencies.jar:?]
linkahead | at org.caosdb.server.transaction.TransactionInterface.execute(TransactionInterface.java:49) ~[caosdb-server-0.8.0-SNAPSHOT-jar-with-dependencies.jar:?]
linkahead | at org.caosdb.server.jobs.Job.execute(Job.java:91) ~[caosdb-server-0.8.0-SNAPSHOT-jar-with-dependencies.jar:?]
linkahead | at org.caosdb.server.jobs.Job.retrieveValidIDByName(Job.java:293) ~[caosdb-server-0.8.0-SNAPSHOT-jar-with-dependencies.jar:?]
linkahead | at org.caosdb.server.jobs.Job.resolve(Job.java:556) ~[caosdb-server-0.8.0-SNAPSHOT-jar-with-dependencies.jar:?]
linkahead | at org.caosdb.server.jobs.core.Inheritance.run(Inheritance.java:144) ~[caosdb-server-0.8.0-SNAPSHOT-jar-with-dependencies.jar:?]
linkahead | at org.caosdb.server.jobs.ScheduledJob.run(ScheduledJob.java:47) ~[caosdb-server-0.8.0-SNAPSHOT-jar-with-dependencies.jar:?]
linkahead | at org.caosdb.server.jobs.Schedule.runJob(Schedule.java:83) ~[caosdb-server-0.8.0-SNAPSHOT-jar-with-dependencies.jar:?]
Obviously, that's an "entity does not exist error" which is not forwarded to the client correctly.