Skip to content

Guestbook ID over 127 could not be assigned to a Dataset via the API - #12592

Open
stevenwinship wants to merge 1 commit into
developfrom
12556-can-not-set-guestbook-with-id-over-127
Open

Guestbook ID over 127 could not be assigned to a Dataset via the API#12592
stevenwinship wants to merge 1 commit into
developfrom
12556-can-not-set-guestbook-with-id-over-127

Conversation

@stevenwinship

Copy link
Copy Markdown
Contributor

What this PR does / why we need it: Guestbook ID over 127 could not be assigned to a Dataset via the API

Which issue(s) this PR closes:#12556

Special notes for your reviewer:

Suggestions on how to test this: See issue for how to reproduce.
Create Datataverse. Create over 200 Guestbooks. Create Dataset under Dataverse. Try to assign a Guestbook with id over 127 to the Dataset.

Does this PR introduce a user interface change? If mockups are available, please link/include them here:

Is there a release notes update needed for this change?: included

Additional documentation:

@stevenwinship stevenwinship self-assigned this Aug 7, 2026
@github-actions github-actions Bot added Feature: API GREI Re-arch Issues related to the GREI Dataverse rearchitecture Size: 3 A percentage of a sprint. 2.1 hours. SPA These changes are required for the Dataverse SPA Type: Bug a defect labels Aug 7, 2026
@stevenwinship stevenwinship moved this to In Progress 💻 in IQSS Dataverse Project Aug 7, 2026
@stevenwinship
stevenwinship force-pushed the 12556-can-not-set-guestbook-with-id-over-127 branch from 2d3e61f to 0b2888e Compare August 7, 2026 19:49
@stevenwinship stevenwinship changed the title Guestbook ID over 127 could not be assigned to a Dataset Guestbook ID over 127 could not be assigned to a Dataset via the API Aug 7, 2026
@stevenwinship stevenwinship added this to the 6.12 milestone Aug 7, 2026
@stevenwinship stevenwinship added the FY27 Sprint 3 FY27 Sprint 3 (2026-07-29 - 2026-08-12) label Aug 7, 2026
@coveralls

coveralls commented Aug 7, 2026

Copy link
Copy Markdown

Coverage Status

Coverage is 25.01%12556-can-not-set-guestbook-with-id-over-127 into develop. No base build found for develop.

@github-actions

This comment has been minimized.

1 similar comment
@github-actions

This comment has been minimized.

@github-actions

github-actions Bot commented Aug 7, 2026

Copy link
Copy Markdown

Test Results

404 tests  ±0   389 ✅ ±0   25m 47s ⏱️ - 11m 13s
 55 suites ±0    15 💤 ±0 
 55 files   ±0     0 ❌ ±0 

Results for commit b8b68a6. ± Comparison against base commit e28af3f.

♻️ This comment has been updated with latest results.

@stevenwinship stevenwinship moved this from In Progress 💻 to Ready for Review ⏩ in IQSS Dataverse Project Aug 10, 2026
@stevenwinship stevenwinship removed their assignment Aug 10, 2026
@stevenwinship
stevenwinship force-pushed the 12556-can-not-set-guestbook-with-id-over-127 branch from 0b2888e to ffe0582 Compare August 11, 2026 15:35
@github-actions

This comment has been minimized.

@stevenwinship
stevenwinship force-pushed the 12556-can-not-set-guestbook-with-id-over-127 branch from ffe0582 to 8d8e544 Compare August 11, 2026 17:18
@github-actions

This comment has been minimized.

@stevenwinship
stevenwinship force-pushed the 12556-can-not-set-guestbook-with-id-over-127 branch from 23e3adf to 73ebe99 Compare August 11, 2026 18:56
@github-actions

This comment has been minimized.

@qqmyers qqmyers self-assigned this Aug 12, 2026
@cmbz cmbz added the FY27 Sprint 4 FY27 Sprint 4 (2026-08-12 - 2026-08-26) label Aug 12, 2026
@stevenwinship
stevenwinship force-pushed the 12556-can-not-set-guestbook-with-id-over-127 branch from 73ebe99 to 175f551 Compare August 13, 2026 13:37
@github-actions

This comment has been minimized.

@stevenwinship
stevenwinship force-pushed the 12556-can-not-set-guestbook-with-id-over-127 branch from 175f551 to b8b68a6 Compare August 14, 2026 19:14
@sonarqubecloud

Copy link
Copy Markdown

@github-actions

Copy link
Copy Markdown

📦 Pushed preview images as

ghcr.io/gdcc/dataverse:12556-can-not-set-guestbook-with-id-over-127
ghcr.io/gdcc/configbaker:12556-can-not-set-guestbook-with-id-over-127

🚢 See on GHCR. Use by referencing with full name as printed above, mind the registry name.

final List<Guestbook> guestbooks = dataset.getOwner().getAvailableGuestbooks();
for (Guestbook gb : guestbooks) {
if (gb.getId() == guestbook.getId()) {
if (gb.getId().equals(guestbook.getId())) {

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

This appears to work and FWIW: it's something my IDE flagged as suspicious, suggesting Object.equals() as a null-safe approach. Since this use is getting real db objects guaranteed not to be null, .equals seems fine.

Out of scope- this loop seems to iterate over all available guestbooks just to assure this guestbook is allowed. I think that could be found more cheaply by looking at guestbook.getDataverse() and seeing if that's one of the recursive dataset.getOwner() s.

Since this is straight forward and I also QAed it ( using SELECT setval('guestbook_id_seq', 129, true); to cause my second guestbook to have id 130 rather than creating that many guestbooks), I'll put this in QA and see at standup if that's sufficient to merge it.

@github-project-automation github-project-automation Bot moved this from In Review 🔎 to Ready for QA ⏩ in IQSS Dataverse Project Aug 18, 2026
@qqmyers qqmyers moved this from Ready for QA ⏩ to QA ✅ in IQSS Dataverse Project Aug 18, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Feature: API FY27 Sprint 3 FY27 Sprint 3 (2026-07-29 - 2026-08-12) FY27 Sprint 4 FY27 Sprint 4 (2026-08-12 - 2026-08-26) GREI Re-arch Issues related to the GREI Dataverse rearchitecture Size: 3 A percentage of a sprint. 2.1 hours. SPA These changes are required for the Dataverse SPA Type: Bug a defect

Projects

Status: QA ✅

Development

Successfully merging this pull request may close these issues.

Users cannot apply guestbooks with guestbookID greater than 127

4 participants