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

Does anyone use unseen? #659

Open
max-sixty opened this issue Oct 12, 2024 · 2 comments
Open

Does anyone use unseen? #659

max-sixty opened this issue Oct 12, 2024 · 2 comments

Comments

@max-sixty
Copy link
Collaborator

Unseen — Accept all new (previously unseen) — allows automatically accepting snapshots which don't yet exist. I can't see it being that helpful — generally I either want to review any snapshots, or I'm running with --accept and will review in git.

There's some logic from ages ago that looks wrong,

insta/insta/src/runtime.rs

Lines 520 to 525 in ce2b3fd

// TODO: this seems to be making `unseen` be true when there is an
// existing snapshot file; which seems wrong??
let unseen = self
.snapshot_file
.as_ref()
.map_or(false, |x| fs::metadata(x).is_ok());
, and rather than fix & test it, I might propose deprecating it. To the extent it is indeed wrong, even less likely that people are using the option.

That said, very possibly others find this useful?

@xamgore
Copy link

xamgore commented Oct 17, 2024

The only way to know for sure, is deprecating the feature and printing this URL into terminals :))

@max-sixty
Copy link
Collaborator Author

Funny you should suggest that: #668 :)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants