linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Linus Torvalds <torvalds@linux-foundation.org>
To: Linus Torvalds <torvalds@linux-foundation.org>,
	Eduardo Valentin <edubezval@gmail.com>,
	pr-tracker-bot@kernel.org, Rui Zhang <rui.zhang@intel.com>,
	ACPI Devel Maling List <linux-acpi@vger.kernel.org>,
	Linux PM <linux-pm@vger.kernel.org>,
	LKML <linux-kernel@vger.kernel.org>
Subject: Re: [GIT PULL] Thermal-SoC management fixes for v5.0-rc6
Date: Mon, 11 Feb 2019 14:04:08 -0800	[thread overview]
Message-ID: <CAHk-=wg9yvP3hGVRSnc=8qoj0g7_zt=_2FjmgSAu-0DViyFtaw@mail.gmail.com> (raw)
In-Reply-To: <20190211201619.GA8065@work>

On Mon, Feb 11, 2019 at 12:16 PM Konstantin Ryabitsev
<konstantin@linuxfoundation.org> wrote:
>
> Okay, so I need guidance on the proper behaviour here. As this request
> didn't use the magic wording for the commit-id (as generated by
> git-request-pull), we ended up trying to look up the remote. The remote
> specified was:
>
>   git://git.kernel.org/pub/scm/linux/kernel/git/evalenti/linux-soc-thermal fixes
>
> Since it's a short refname, we first try to look it up as a tag:

No, you don't do even that.

The name is "fixes". But you seem to match it with one of these:

> $ git ls-remote git://git.kernel.org/pub/scm/linux/kernel/git/evalenti/linux-soc-thermal fixes^{}
> a6d25f4c951b8b28f2eaec6f891ff834622532f2        refs/tags/omap-for-v3.10-rc1/fixes^{}
> 77319669af37a1cfc844b801e83343b37e3c7e13        refs/tags/omap/fixes^{}

*NEITHER* of which is a tag named "fixes". One is named
"omap-for-v3.10-rc1/fixes" and the other is a tag named "omap/fixes".

Notice?

What git will do is

 (a) Never *ever* match against a partial name.

     git matches against this list of patterns:

        "%.*s",
        "refs/%.*s",
        "refs/tags/%.*s",
        "refs/heads/%.*s",
        "refs/remotes/%.*s",
        "refs/remotes/%.*s/HEAD",

     so "fixes" can match "refs/heads/fixes" and "refs/tags/fixes" (or
a *remote* called "fixes"), but it can never match against
"refs/tags/omap/fixes".

 (b) If you have an actual ambiguous name, git will indeed pick the
first from that list (so tags before branches, but also HEAD before a
tag called HEAD), but it will generally also warn:

        warning: refname 'xyz' is ambiguous.

So using "ls-remote" the way you are actually gives *way* more matches
than it should. The ls-remote pattern is really just a grep pattern,
not an actual ref lookup.

So if you want to look up tag 'x', you really need to match on
'refs/tags/x' exactly.

But that does explain why you thought it matched.

Anyway, the _real_ merge for that pull request has now happened, and
is commit aa0c38cf39de.

              Linus

  reply	other threads:[~2019-02-11 22:04 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-02-10  4:17 [GIT PULL] Thermal-SoC management fixes for v5.0-rc6 Eduardo Valentin
2019-02-10  4:25 ` pr-tracker-bot
2019-02-11  3:19   ` Eduardo Valentin
2019-02-11 18:34     ` Linus Torvalds
2019-02-11 18:40       ` Konstantin Ryabitsev
2019-02-11 20:05         ` Konstantin Ryabitsev
2019-02-11 20:16       ` Konstantin Ryabitsev
2019-02-11 22:04         ` Linus Torvalds [this message]
2019-02-11 23:10           ` Konstantin Ryabitsev

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='CAHk-=wg9yvP3hGVRSnc=8qoj0g7_zt=_2FjmgSAu-0DViyFtaw@mail.gmail.com' \
    --to=torvalds@linux-foundation.org \
    --cc=edubezval@gmail.com \
    --cc=linux-acpi@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-pm@vger.kernel.org \
    --cc=pr-tracker-bot@kernel.org \
    --cc=rui.zhang@intel.com \
    /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.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).