rust-itertools / itertools

Extra iterator adaptors, iterator methods, free functions, and macros.
https://docs.rs/itertools/
Apache License 2.0
2.72k stars 309 forks source link

Not all released versions have corresponding git tags #703

Closed obi1kenobi closed 1 year ago

obi1kenobi commented 1 year ago

I recently tried to look up the tag corresponding to the latest version of itertools, but found that unfortunately there is no tag for it.

I have a tool I've used in another repo that can query crates.io to get the git hashes corresponding to each release, and would be able to restore not just the most recent version's tag but also other historical tags that also happen to be missing. I previously successfully used it in cargo_metadata here: https://github.com/oli-obk/cargo_metadata/issues/184#issuecomment-1452918558

If I were to provide the git hashes my tool pulls from crates.io, would you be open to adding the missing tags?

(I also contributed a GitHub Action-based release process to cargo_metadata that automatically adds tags on cargo publish. If this is something you're interested in as well, it would be very easy for me to open a PR for that too — just let me know.)

jswrenn commented 1 year ago

Yes, I'd be delighted to add the missing tags if you can provide them. Most recent releases of itertools should have tags, since we use cargo release to manage releases (but I do think I botched one or two releases). In the future, I'll be more careful about adding tags.

obi1kenobi commented 1 year ago

No worries at all, and thank you! I'll send the list over soon.

obi1kenobi commented 1 year ago

There were two versions that had hashes in crates.io but didn't have tags in the repo:

[{
  "gitrev": "7554521d97d917da88fe49248332ea1f8919f6ec",
  "version": "0.8.1"
},
{
  "gitrev": "d61d12e808c8691eb0a672d3f9b65560be970a44",
  "version": "0.10.5"
}]

0.10.2 seems to have been a publish from a "dirty" git state so crates.io doesn't have a hash for it. Most of the older versions that lack tags seem to predate cargo including git hash information in the crate file, so this is as good as it's going to get unless we can find a different source.

jswrenn commented 1 year ago

Done!