Skip to content

Commit

Permalink
[lock-tidy] Put warning behind feature flag (#2171)
Browse files Browse the repository at this point in the history
## Summary

`--tidy-lockfile` is not reliable, so put this warning behind a feature
flag until it is fixed.

## How was it tested?

Ran `devbox install` with missing outputs in lockfile, did not see
error.
  • Loading branch information
mikeland73 authored Jun 25, 2024
1 parent ac28b01 commit 4409115
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 1 deletion.
6 changes: 6 additions & 0 deletions internal/boxcli/featureflag/tidywarning.go
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
// Copyright 2024 Jetify Inc. and contributors. All rights reserved.
// Use of this source code is governed by the license in the LICENSE file.

package featureflag

var TidyWarning = disable("TIDY_WARNING")
3 changes: 2 additions & 1 deletion internal/devpkg/package.go
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,7 @@ import (

"github.com/pkg/errors"
"github.com/samber/lo"
"go.jetpack.io/devbox/internal/boxcli/featureflag"
"go.jetpack.io/devbox/internal/boxcli/usererr"
"go.jetpack.io/devbox/internal/cachehash"
"go.jetpack.io/devbox/internal/debug"
Expand Down Expand Up @@ -746,7 +747,7 @@ func (p *Package) GetStorePaths(ctx context.Context, w io.Writer) ([]string, err
return storePathsForPackage, err
}

if p.IsDevboxPackage {
if featureflag.TidyWarning.Enabled() && p.IsDevboxPackage {
// No fast path, we need to query nix.
ux.FHidableWarning(ctx, w, MissingStorePathsWarning, p.Raw)
}
Expand Down

0 comments on commit 4409115

Please sign in to comment.