crates icon indicating copy to clipboard operation
crates copied to clipboard

Differences in MINOR and PATCH parts are not reported

Open rimutaka opened this issue 3 years ago • 10 comments

A new version alert is not displayed if the difference is in MINOR or PATCH numbers only. It seems that only MAJOR version differences result in displaying the latest version number.

E.g., urlencoding has the following versions available:

1.3.3(docs)
1.2.0
1.1.1
1.1.0
1.0.0
0.2.0
0.1.1

Using urlencoding = "1.0.0" through to urlencoding = "1.3.3" prints a green tick and no latest version alert. image

Dropping to urlencoding = "0.2" displays X 1.3.3 next to it. image

Is this a bug or how it should work?

I would expect anything below urlencoding = "1.3.3" to have the latest version alert printed next to it.

Desktop (please complete the following information):

  • OS: Ubuntu 20
  • Version v0.5.9

rimutaka avatar May 19 '21 23:05 rimutaka

I agree. At least it could be an option whether or not minor/patch differences trigger the latest version alert.

phoekz avatar Jul 29 '21 11:07 phoekz

This looks like a regression, because I remember this used to work correctly, even when minor versions change.

koutheir avatar Jul 29 '21 13:07 koutheir

This regression makes this extension useless half of the time.

koutheir avatar Oct 24 '21 03:10 koutheir

This is working as expected. As much as wi know cargo works like that and extension works as they described. Please take a look at #86.

serayuzgur avatar Oct 25 '21 17:10 serayuzgur

So this seems to be the behavior by design, even if it was not like this before. I understand, but it still makes this extension useless half of the time though, whereas it was very useful before.

koutheir avatar Oct 25 '21 18:10 koutheir

I wouldn't go as far as saying the extension is useless, but I think it would be more consistent if it warned about any new versions not compatible with the set pattern. E.g.

TOML CRATES WARNING
1 1.3.3
1.3 1.3.3
1.2 1.3.3 X
1.3.1 1.3.3 X

In other words, if there is a newer version that would not be automatically downloaded by cargo update I'd like to be warned about it.

@serayuzgur , do you think it's a breaking change and we'll need a configuration setting for it to tun on/off? Would you consider a PR or prefer to do it yourself? I have no experience with VSCode extension, but happy to give it a try.

rimutaka avatar Oct 26 '21 21:10 rimutaka

I wouldn't go as far as saying the extension is useless,...

I said the extension is useless half of the time, because that is half of the time the reason I open Cargo.toml with this extension activated, that is, to figure out if I need to upgrade some code in order to use a newer version of a dependency which is not semver-compatible. Dependencies that are semver-compatible are not interesting to me because they will always be automatically upgraded via my frequent cargo updates.

Again, I understand that this behavior is by design. Still, this makes the extension way less useful to me. I didn't mean to offend anybody, I simply stated the result of this design decision on my own use case.

koutheir avatar Oct 26 '21 23:10 koutheir

think it's a breaking change and we'll need a configuration setting for it to tun on/off? Would you consider a PR or prefer to do it yourself? I have no experience with VSCode extension, but happy to give it a tr

I will check and implement it if it is simple to

serayuzgur avatar Jan 03 '22 09:01 serayuzgur

Hi, any progress on this?

Maybe add a less aggressive warning on this, maybe ⚠️ instead of ❌?

Christoph-AK avatar Feb 08 '22 14:02 Christoph-AK