Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

refactor: use specific error for agpl and prebuilds#17591

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 ourterms of service andprivacy statement. We’ll occasionally send you account related emails.

Already on GitHub?Sign in to your account

Merged

Conversation

evgeniy-scherbina
Copy link
Contributor

@evgeniy-scherbinaevgeniy-scherbina commentedApr 28, 2025
edited
Loading

Follow-up PR to#17458
Addresses this discussion:#17458 (comment)

@evgeniy-scherbinaevgeniy-scherbina marked this pull request as ready for reviewApril 28, 2025 18:38
Copy link
Contributor

@dannykoppingdannykopping left a comment

Choose a reason for hiding this comment

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

LGTM with a couple nits

!errors.Is(err,prebuilds.ErrAGPLDoesNotSupportPrebuilds) {
!errors.Is(err,prebuilds.ErrAGPLDoesNotSupportPrebuiltWorkspaces) {
api.Logger.Error(ctx,"failed to claim prebuilt workspace",slog.Error(err),
slog.F("workspace_name",req.Name),slog.F("template_version_preset_id",req.TemplateVersionPresetID))
Copy link
Contributor

@dannykoppingdannykoppingApr 28, 2025
edited
Loading

Choose a reason for hiding this comment

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

I should've been more clear, sorry. I meant we should log when the error is of one of the expected types.

Copy link
ContributorAuthor

Choose a reason for hiding this comment

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

  1. maybe let's log in both cases? Because if unexpected error is happened it also make sense to log? Or it will be logged on another level because handler failed?
  2. do you want to log it with error or warning? BecauseErrNoClaimablePrebuiltWorkspaces is not an actual error? It can be normal situation.

Copy link
Contributor

Choose a reason for hiding this comment

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

Sounds reasonable. Warning for expected cases, error for unexpected 👍

Copy link
ContributorAuthor

Choose a reason for hiding this comment

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

@dannykopping it became too wordy, but I guess it's okay?

Copy link
Contributor

@dannykoppingdannykopping left a comment

Choose a reason for hiding this comment

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

LGTM, thanks!

@evgeniy-scherbinaevgeniy-scherbina merged commita78f0fc intomainApr 28, 2025
29 checks passed
@evgeniy-scherbinaevgeniy-scherbina deleted the yevhenii/512-claim-prebuild-follow-up-2 branchApril 28, 2025 20:37
@github-actionsgithub-actionsbot locked and limited conversation to collaboratorsApr 28, 2025
Sign up for freeto subscribe to this conversation on GitHub. Already have an account?Sign in.

Reviewers

@dannykoppingdannykoppingdannykopping approved these changes

Labels

None yet

Projects

None yet

Milestone

No milestone

Development

Successfully merging this pull request may close these issues.

2 participants

@evgeniy-scherbina@dannykopping

[8]ページ先頭

©2009-2025 Movatter.jp