all messages for Guix-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
From: Leo Famulari <leo@famulari.name>
To: Alex Kost <alezost@gmail.com>
Cc: guix-devel@gnu.org
Subject: Re: Version numbers for VCS snapshots
Date: Sun, 21 Feb 2016 17:52:56 -0500	[thread overview]
Message-ID: <20160221225256.GA21678@jasmine> (raw)
In-Reply-To: <87bn7axw0w.fsf@gmail.com>

On Sun, Feb 21, 2016 at 12:17:19PM +0300, Alex Kost wrote:
> Leo Famulari (2016-02-21 07:35 +0300) wrote:
> 
> > On Thu, Jan 21, 2016 at 10:05:36PM +0100, Ludovic Courtès wrote:
> [...]
> >> I prefer 7!  This is how Git usually truncates SHA1s, so it can’t be wrong.
> >
> > I stumbled across this email earlier, which reminded me of this
> > discussion about hash lengths:
> > https://lkml.org/lkml/2010/10/28/287
> >
> > There are currently 13 7-character hash collisions in Guix's git repo:
> >
> > $ git rev-list --objects --all | cut -c1-7 | sort | uniq -dc
> >       2 0d2b24c
> >       2 11e0632
> >       2 1f3ab8d
> >       2 229bd6c
> >       2 7c4a7b7
> >       2 9ff8b63
> >       2 aa27b56
> >       2 c10c562
> >       2 d96cdce
> >       2 dab4329
> >       2 dc27d1c
> >       2 ea119a2
> >       2 f56cc27
> 
> Hm, when I tried "git rev-list --objects --all" I got some ridiculous
> number of lines (I pressed C-c C-c after about 78000 lines).  Does this
> command really do what you wanted?  (I'm sorry I didn't RTFM well enough
> to understand what it does).

It lists the objects in the repository, so not just commits. I'm not
presenting this as evidence that something is wrong with our repo, just
that 7 characters is not enough to unambiguously refer to things in git
repos of projects our size. For example, with `git show`.

It's more of an informational link than a call to action. Although I am
updating all of our uses of git-reference to use the method we agreed
upon upthread, before any of those upstream repos grow too large for the
identifiers we are currently using.

> 
> I'm not sure if the following command is correct to find such
> collisions, but it gives nothing (i.e., no collisions):
> 
>   git log --oneline | cut -c1-7 | sort | uniq -dc

Indeed, we only have about 10000 commits. 6 characters is where we get
collisions in our log.

> 
> -- 
> Alex

  reply	other threads:[~2016-02-21 22:53 UTC|newest]

Thread overview: 28+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-01-09 21:26 New CLI syntax for package version Ludovic Courtès
2016-01-09 22:52 ` Andreas Enge
2016-01-10  8:32 ` Ricardo Wurmus
2016-01-11  3:37   ` Christopher Allan Webber
2016-01-11 15:48     ` Eric Bavier
2016-01-12  7:50 ` Ricardo Wurmus
2016-01-12  9:26   ` Version numbers for VCS snapshots Ludovic Courtès
2016-01-21  4:51     ` Ben Woodcroft
2016-01-21  6:22       ` Leo Famulari
2016-01-21  9:40         ` Ricardo Wurmus
2016-01-21 18:44           ` Leo Famulari
2016-01-21 21:05             ` Ludovic Courtès
2016-02-21  4:35               ` Leo Famulari
2016-02-21  9:17                 ` Alex Kost
2016-02-21 22:52                   ` Leo Famulari [this message]
2016-02-22  0:09                     ` Christopher Allan Webber
2016-02-23 11:53                       ` Ludovic Courtès
2016-01-21  9:44       ` Ricardo Wurmus
2016-01-21 21:25         ` Ludovic Courtès
2016-01-21 22:02           ` Ricardo Wurmus
2016-01-23 22:00             ` Ludovic Courtès
2016-01-23 22:07               ` Ricardo Wurmus
2016-01-24 23:12                 ` Ludovic Courtès
2016-01-21 22:08           ` Eric Bavier
2016-01-21 22:23             ` Jookia
2016-01-22  9:35           ` Andy Wingo
2016-01-22 12:31             ` Ricardo Wurmus
2016-01-23 21:51             ` Ludovic Courtès

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20160221225256.GA21678@jasmine \
    --to=leo@famulari.name \
    --cc=alezost@gmail.com \
    --cc=guix-devel@gnu.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this external index

	https://git.savannah.gnu.org/cgit/guix.git

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.