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

Fix duplicate discovery results #3515

Merged
merged 5 commits into from
Oct 23, 2024

Conversation

woutslakhorst
Copy link
Member

fixes #3455 (third time is a charm)

This time using sub select and group by.
Also changed wildcard behaviour (IS NOT NULL)

@gerardsn
Copy link
Member

e2e fails on postgres

nodeA-backend-1  | time="2024-10-23T12:42:48Z" level=warning msg="Query failed (took 216.704µs): UPDATE \"discovery_presentation\" SET \"validated\"=true WHERE id = 'f2912007-3dfe-4cfd-bc0e-9be29acc8246'" error="failed to encode args[0]: unable to encode true into binary format for int2 (OID 21): cannot find encode plan" module=Storage
nodeA-backend-1  | time="2024-10-23T12:42:48Z" level=error msg="failed to update validated flag for presentation (id: f2912007-3dfe-4cfd-bc0e-9be29acc8246)" error="failed to encode args[0]: unable to encode true into binary format for int2 (OID 21): cannot find encode plan" module=Discovery

I think the second error is unrelated to this issue, so needs to be checked after this fix works for postgres

@woutslakhorst
Copy link
Member Author

woutslakhorst commented Oct 23, 2024

e2e fails on postgres

nodeA-backend-1  | time="2024-10-23T12:42:48Z" level=warning msg="Query failed (took 216.704µs): UPDATE \"discovery_presentation\" SET \"validated\"=true WHERE id = 'f2912007-3dfe-4cfd-bc0e-9be29acc8246'" error="failed to encode args[0]: unable to encode true into binary format for int2 (OID 21): cannot find encode plan" module=Storage
nodeA-backend-1  | time="2024-10-23T12:42:48Z" level=error msg="failed to update validated flag for presentation (id: f2912007-3dfe-4cfd-bc0e-9be29acc8246)" error="failed to encode args[0]: unable to encode true into binary format for int2 (OID 21): cannot find encode plan" module=Discovery

I think the second error is unrelated to this issue, so needs to be checked after this fix works for postgres

I added a search which then fails because the registration is not validated. Lucky find though.... 2 birds one stone

@woutslakhorst woutslakhorst merged commit 3ac99ee into master Oct 23, 2024
9 checks passed
@woutslakhorst woutslakhorst deleted the fix/3455_duplicate_discovery_results branch October 23, 2024 13:12
rolandgroen added a commit that referenced this pull request Nov 1, 2024
* master: (72 commits)
  PKI add ValidateStrict (#3531)
  PEX: Return capture group for matched patterns (#3526)
  Schedule CodeQL twice a week (#3525)
  change cron schedule (#3524)
  Add gh action for CodeQL schedule (#3523)
  Bump github.com/lestrrat-go/jwx/v2 from 2.1.1 to 2.1.2 (#3520)
  docs: v6 release date (#3519)
  status codes for discovery client (#3513)
  Require SQL connection string in strictmode (#3517)
  Fix duplicate discovery results (#3515)
  Bump github.com/chromedp/chromedp from 0.11.0 to 0.11.1 (#3514)
  fix duplicate search results for wildcard param (#3512)
  Bump github.com/Azure/azure-sdk-for-go/sdk/security/keyvault/azkeys (#3511)
  remove network migration and optimize network event retry (#3510)
  secure outgoing http client with max connections (#3508)
  make gen-mocks (#3509)
  Bump github.com/Azure/azure-sdk-for-go/sdk/azcore from 1.15.0 to 1.16.0 (#3506)
  fix invalid keyReference migration objects (#3504)
  Bump go.uber.org/mock from 0.4.0 to 0.5.0 (#3507)
  Bump github.com/nats-io/nats-server/v2 from 2.10.21 to 2.10.22 (#3505)
  ...

# Conflicts:
#	vcr/test.go
#	vdr/legacy_integration_test.go
#	vdr/vdr.go
#	vdr/vdr_test.go
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

Successfully merging this pull request may close these issues.

Duplicate discovery results when searching without query
2 participants