-
Notifications
You must be signed in to change notification settings - Fork 1
Fix firstbuy 1175 #578
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 firstbuy 1175 #578
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Pull request overview
Updates tokenized-community “first buy” (kind 1175) linking to be based on a per-user reset baseline, and adjusts query dependency expansion and tests accordingly. Also includes small validation/model cleanups and a NIP-11 metrics fix.
Changes:
- Add a new DB trigger + backfill migration to link kind=1175 actions to the latest matching
community_token_position_resetevent viafirst_1175_address. - Update TC dependency query building and tests to reflect the new
first_1175_addresssemantics. - Minor improvements: add kind 4175 validator (Consent), fix “Definition” spelling in constants, and update disk-usage analyzer usage in NIP-11.
Reviewed changes
Copilot reviewed 9 out of 10 changed files in this pull request and generated 3 comments.
Show a summary per file
| File | Description |
|---|---|
validation/validate.go |
Rename CommongTags→CommonTags, add NoExpiration() helper, add validator for CustomIONKindConsent. |
server/http/nip11/nip11.go |
Update AnalyzeDir call signature and fix hardlink stats update target for command storage. |
model/model.go |
Add CustomIONKindConsent constant; fix Defination→Definition spelling in repost kind name. |
model/filter.go |
Update repost-kind mapping to use corrected constant name. |
database/query/query_where_builder.go |
Adjust 1175→31175 dependency expansion to pull referenced first_1175_address events; update corrected constant usage. |
database/query/query_tc_test.go |
Update tests to insert reset events and validate new linking behavior. |
database/query/query.go |
Update allowed kinds list to use corrected constant name. |
database/query/ddl/00020_events_link_first_1175_by_user.sql |
New migration: trigger + index + backfill for linking actions to reset baseline. |
go.mod / go.sum |
Dependency updates (notably gdu, ants, klauspost/compress, x/sys, etc.). |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
No description provided.