Repository navigation
Conversation
Mark a line item or shared pool that staff can trial from the admin page, though customers cannot (Size Analysis). getsentry then reads it from the package config instead of the deprecated line_item_category.
|
The latest Buf updates on your PR. Results from workflow ci / buf-checks (pull_request).
|
This branch has not been deployed
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Bottom line: Adds
can_admin_product_trialtoLineItemConfig(field 14) andSharedLineItemPool(field 12). It marks a product that staff can trial from the admin page but customers cannot, such as Size Analysis. Nothing reads the field yet. A getsentry follow-up starts to use it.LineItemDetails.line_item_category. That field is deprecated, and new code must not read it. The new field puts the rule in the package config, next tocan_product_trial.can_product_trialor what customers can start.LineItemTag. Packages already set who can trial a product. Tags tell what a product is.can_product_trialand all its readers. Instead, the field comments say to set at most one of the two fields.How the two fields work together
Customers check only
can_product_trial. Staff can start a trial when either field is set.can_product_trialcan_admin_product_trialThe self-serve rules refuse a trial when the organization did not finish a subscription trial, or when its sponsorship does not allow trials. Staff skip these rules (getsentry/getsentry#23112). Customers and staff both get one trial per product.
No pool needs the new field today. It is on pools too, so the two trial fields are on the same messages.
Compatibility
New fields only. The default is
false, so no package changes.buf lint,buf format,buf breaking,cargo check,cargo clippyand the Python tests pass.Cargo.lockmoves to 0.120.0, asmake build-rustdoes after each release.Consumer
getsentry/getsentry#23211, a follow-up to getsentry/getsentry#23112, uses the field. It needs a release with this change. It:
_ADMIN_ONLY_PRODUCT_TRIAL_CATEGORIES,Refs REVENG-719