Skip to content

uncomment apply_absolute_date#7032

Merged
acwhite211 merged 7 commits into
v7_11_0from
issue-7021
Jul 16, 2025
Merged

uncomment apply_absolute_date#7032
acwhite211 merged 7 commits into
v7_11_0from
issue-7021

Conversation

@acwhite211

@acwhite211 acwhite211 commented Jul 11, 2025

Copy link
Copy Markdown
Collaborator

Fixes #7021

Uncomment apply_absolute_date line in the execution.py file. Looks like this line was commented out during development and needed to be added back it. This is to fix the issue of querying for collection objects based on the timestampCreated field in relative mode all records are returned, despite the timestamp created not falling within the designated range.

Checklist

  • Self-review the PR after opening it to make sure the changes look good and
    self-explanatory (or properly documented)
  • Add relevant issue to release milestone
  • Add pr to documentation list
  • Add automated tests
  • Add a reverse migration if a migration is present in the PR

Testing instructions

  • Create a specify query in the CO QB viewer. Set the query to filter by the "Timestamp created" and set some condition on that filter. See that the CO query results are limited and not returning all COs.
  • Go through testing instructions from: Add series tool in query builder #4952

@github-project-automation github-project-automation Bot moved this to 📋Back Log in General Tester Board Jul 11, 2025
@CarolineDenis
CarolineDenis requested a review from a team July 11, 2025 17:24
@acwhite211
acwhite211 marked this pull request as ready for review July 11, 2025 17:41
@acwhite211
acwhite211 requested a review from a team July 11, 2025 17:41

@emenslin emenslin left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

  • Create a specify query in the CO QB viewer. Set the query to filter by the "Timestamp created" and set some condition on that filter. See that the CO query results are limited and not returning all COs.
  • Go through testing instructions from: #4952

Running into a similar issue as #4952 (review), if you check series, delete catalog number, then query series is still checked and you cannot check distinct and the count is incorrect.

07-11_13.15.mp4

Also I was able to replicate this issue #4952 (review) where if you check series then disable catalog number it throws an error.

07-11_13.46.mp4

Specify 7 Crash Report - 2025-07-11T18_46_43.554Z.txt

Other than those two issues everything else looks good

@github-project-automation github-project-automation Bot moved this from 📋Back Log to Dev Attention Needed in General Tester Board Jul 11, 2025
@acwhite211

Copy link
Copy Markdown
Collaborator Author

The first issue of removing catalog number and rerunning the query seems to be a front-end issue where the front-end is still putting smushed=True in the request. I remember that we solved this issue, so it's odd that it is happening again, I'm investigating the issue. The second issue of unselecting the catalog number is also causing the same issue.

@acwhite211

Copy link
Copy Markdown
Collaborator Author

@emenslin I fixed the issues that you found with removing the catalog number field in series queries. Good for retesting, thanks!

@emenslin emenslin left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Series checkbox not working properly for both new queries and saved queries. In a new query you can't seem to check the series checkbox, if you check it and try to query it unchecks:

07-14_12.59.mp4

With a saved query you cannot uncheck series:

07-14_13.02.mp4

@acwhite211
acwhite211 requested a review from emenslin July 14, 2025 18:32
@acwhite211

Copy link
Copy Markdown
Collaborator Author

Thanks @emenslin, made some changes to the logic to fix that issue. Looks like it's behaving correctly now. Should be good now to retest, thanks.

Comment thread specifyweb/frontend/js_src/lib/components/QueryBuilder/Wrapped.tsx Outdated
Comment thread specifyweb/frontend/js_src/lib/components/QueryBuilder/Wrapped.tsx Outdated

@emenslin emenslin left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

  • Create a specify query in the CO QB viewer. Set the query to filter by the "Timestamp created" and set some condition on that filter. See that the CO query results are limited and not returning all COs.
  • Go through testing instructions from: #4952

Looks good, all previous issues seem to be fixed!

@emenslin
emenslin requested a review from a team July 15, 2025 14:16
@CarolineDenis
CarolineDenis requested a review from pashiav July 15, 2025 15:51

@lexiclevenger lexiclevenger left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Testing instructions

  • Create a specify query in the CO QB viewer. Set the query to filter by the "Timestamp created" and set some condition on that filter. See that the CO query results are limited and not returning all COs.
  • Go through testing instructions from: #4952

No issues with the series checkbox, but it looks like the results are inaccurate and include records with timestamps outside the conditions:

Screen.Recording.2025-07-15.at.12.05.31.PM.mov

https://kufishtissue20240124copy-issue-7021.test.specifysystems.org/specify/query/188/
KU Fish Voucher Collection
spfishadmin

@bhumikaguptaa
bhumikaguptaa self-requested a review July 15, 2025 17:32

@bhumikaguptaa bhumikaguptaa left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

  • Create a specify query in the CO QB viewer. Set the query to filter by the "Timestamp created" and set some condition on that filter. See that the CO query results are limited and not returning all COs.
  • Go through testing instructions from: #4952

All of the testing instructions works as expected, but I ran into a separate issue with the series box : #7086

@acwhite211

Copy link
Copy Markdown
Collaborator Author

Thanks for noticing that @lexiclevenger! Looks like this is an issue in main and other older version of Specify. I created a new issue #7088, so we'll ignore that issue for this PR. Thanks!

@acwhite211
acwhite211 requested a review from lexiclevenger July 15, 2025 18:27

@lexiclevenger lexiclevenger left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@acwhite211 In that case, looks good!

@acwhite211
acwhite211 merged commit c9a4a44 into v7_11_0 Jul 16, 2025
14 checks passed
@acwhite211
acwhite211 deleted the issue-7021 branch July 16, 2025 14:01
@github-project-automation github-project-automation Bot moved this from Dev Attention Needed to ✅Done in General Tester Board Jul 16, 2025
@acwhite211 acwhite211 mentioned this pull request Jul 21, 2025
4 tasks
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

Status: ✅Done

Development

Successfully merging this pull request may close these issues.

Querying (relative) timestampCreated for Collection Object returns all records

5 participants