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

feat!: keep original deployed ticker for brc20 tokens #349

Merged
merged 1 commit into from
Jul 30, 2024

Conversation

rafaelcr
Copy link
Collaborator

Conserves original case of deployed ticker for BRC-20 tokens and uses it for predicate payloads.

Fixes #348

@rafaelcr rafaelcr requested a review from tippenein July 30, 2024 04:57
Copy link

codecov bot commented Jul 30, 2024

@rafaelcr rafaelcr had a problem deploying to Development-mainnet-blue July 30, 2024 05:24 — with GitHub Actions Failure
@tippenein
Copy link

Not sure I understand the motivation here? Why do we need to keep a separate display value? It doesn't seem like a db change

@rafaelcr
Copy link
Collaborator Author

@tippenein basically, in the BRC-20 indexing rules there's a rule that says that token processing should be done case insensitive. This means that if a token is deployed with the name PEPE, further operations that are done for pepe should apply to the same token.

However, the original case of the ticker name (PEPE in this case) should be respected when displaying the token in the API, which is why we'll now save both the original display name and the lowercase name which we currently use as the primary key and foreign key in all of our BRC-20 tables.

We could store only the original case and always lowercase before processing token operations, but that would make the code a bit harder to maintain and more prone to errors.

@rafaelcr rafaelcr merged commit 39774a9 into develop Jul 30, 2024
5 of 6 checks passed
@rafaelcr rafaelcr deleted the fix/brc20-caps branch July 30, 2024 16:02
github-actions bot pushed a commit that referenced this pull request Sep 20, 2024
## [3.0.0-beta.1](v2.2.5...v3.0.0-beta.1) (2024-09-20)

### ⚠ BREAKING CHANGES

* support brc20 activity on scan blocks command (#350)
* keep original deployed ticker for brc20 tokens (#349)

### Features

* add prometheus monitoring ([#356](#356)) ([f35e1d0](f35e1d0))
* keep original deployed ticker for brc20 tokens ([#349](#349)) ([39774a9](39774a9))
* support a separate storage directory for observers.sqlite ([#354](#354)) ([7a65fdf](7a65fdf))
* support brc20 activity on scan blocks command ([#350](#350)) ([caacff7](caacff7))
* wait for bitcoind to be at chain tip before starting service ([#364](#364)) ([d4b67bb](d4b67bb))

### Bug Fixes

* also check config when looking for brc20 db connection ([#347](#347)) ([d80388b](d80388b))
* only create brc-20 db connection and cache if required ([#357](#357)) ([5692426](5692426))
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
Archived in project
Development

Successfully merging this pull request may close these issues.

keep case-sensitive BRC-20 ticker names for display
2 participants