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

"Identifier issues" report at bottom of Dashboard doesn't work from OpenSearch #635

Open
sfisher opened this issue May 17, 2024 · 1 comment
Assignees
Labels
bug Something isn't working OpenSearch

Comments

@sfisher
Copy link
Contributor

sfisher commented May 17, 2024

This is a super confusing page and code and the data we have in OpenSearch made it hard to discover if it was working.

Items with "issues" have to do with "hasIssues" and "linkIsBroken" in the search table originally.

If you select "ALL" from the list then the "issues" section of the page always tells you that you have no issues. You have to select one of the groups or owners for issues to show up correctly. This is apparently how the page is designed and is how the "working" version does things against the database.

I eventually finally found some issues in the normal database development version by selecting an items such as "Bulyon1" from the list and it shows issues in normal development.

How to be sure the data should show these errors in our OpenSearch index by:

  • Note some error items and manually ingest them into opensearch if needed to be sure we have "error" data. like below
python manage.py shell

import impl.open_search_doc as open_search_doc
from ezidapp.models.identifier import Identifier
open_s = open_search_doc.OpenSearchDoc(identifier=Identifier.objects.get(identifier='ark:/28722/k2kh0pq17'))
my_dict = open_s.dict_for_identifier()
open_s.index_document()

I put in some "error" items manually from the bulyon1 group and they still don't show up.

Also the "crossref" errors may be similar. I put in these error items for crossref.

doi:10.5070/P20W2R
doi:10.5070/P2PG6B
doi:10.5070/D6110000
doi:10.5070/L2319067
doi:10.21425/F5FBG12712
doi:10.21425/F5FBG12711

Need to troubleshoot why errors are still not showing up.

@sfisher sfisher self-assigned this May 17, 2024
@sfisher sfisher added bug Something isn't working OpenSearch labels May 17, 2024
@sfisher
Copy link
Contributor Author

sfisher commented May 21, 2024

This was much easier to fix today when I came back to it and was a combination of a few things:

  1. Not using the keyword property for exact matches.
  2. Some missing logic in the "reasons" listing since it wasn't clear if we needed that logic when I first started.
  3. Incorrect method call that was missing the parameter (hit) but wasn't raising an error. I guess the logic was just checking that the method existed rather than calling it.

I spent hours and hours trying to meticulously trace through 3 or 4 files of code which was convoluted on Friday, but it turned out to be small differences in how search was handled and Python not raising errors.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working OpenSearch
Projects
None yet
Development

No branches or pull requests

1 participant