Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

I cannot apply Complex Decision #1523

Open
yroskov opened this issue Nov 22, 2024 · 3 comments
Open

I cannot apply Complex Decision #1523

yroskov opened this issue Nov 22, 2024 · 3 comments

Comments

@yroskov
Copy link

yroskov commented Nov 22, 2024

Trying to apply to fix authorstrigns here https://www.checklistbank.org/catalogue/3/dataset/1101/workbench?facet=rank&facet=issue&facet=status&facet=nomStatus&facet=nameType&facet=field&facet=authorship&facet=authorshipYear&facet=extinct&facet=environment&facet=origin&issue=unparsable%20name&limit=100&offset=0

Decisions are not visible for some names.

image

org.apache.ibatis.exceptions.PersistenceException: 
### Error updating database.  Cause: org.postgresql.util.PSQLException: ERROR: duplicate key value violates unique constraint "decision_dataset_key_subject_dataset_key_subject_id_key"
  Detail: Key (dataset_key, subject_dataset_key, subject_id)=(3, 1101, 1304651) already exists.
### The error may exist in life/catalogue/db/mapper/DecisionMapper.xml
### The error may involve life.catalogue.db.mapper.DecisionMapper.create-Inline
### The error occurred while setting parameters
### SQL: INSERT INTO decision (id,       dataset_key,           subject_dataset_key,     subject_id,     subject_name,     subject_authorship,     subject_rank,     subject_code,     subject_status,     subject_parent,     note,     modified,     modified_by,     mode,     name,     status,     extinct,     keep_original_name,     temporal_range_start,     temporal_range_end,     environments        , original_subject_id, created_by )     VALUES (nextval('decision_3_id_seq'),       ?,     ?,     ?,     ?,     ?,     ?::RANK,     ?::NOMCODE,     ?::TAXONOMICSTATUS,     ?,     ?,     now(),     ?,     ?::EDITORIALDECISION_MODE,     ?::jsonb,     ?::TAXONOMICSTATUS,     ?,     ?,     ?,     ?,     ?    , ?, ? )
### Cause: org.postgresql.util.PSQLException: ERROR: duplicate key value violates unique constraint "decision_dataset_key_subject_dataset_key_subject_id_key"
  Detail: Key (dataset_key, subject_dataset_key, subject_id)=(3, 1101, 1304651) already exists.
@yroskov
Copy link
Author

yroskov commented Nov 22, 2024

Geoff says: The decision does exist but isn't displayed by the frontend:

http://api.checklistbank.org/dataset/3/decision?name=Allodiopsis%20hispida&subjectdatsetKey=1101

@gdower gdower transferred this issue from CatalogueOfLife/backend Jan 16, 2025
@mdoering
Copy link
Member

Yes, they do exist thats why you see that error. I would prefer if the UI would show that more gracefully though and explain that there is a decision already. I can see the decisions now, seems to be some sort of caching issue. Though I can see that the main Varnish cache is not involved, the requests bypasses varnish and the response http header says uncacheable:

Image

@mdoering
Copy link
Member

@yroskov I assume it is not working for you as well?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants