Skip to content

fix: dont warn when no remote tags exist - #102

Merged
mrcjkb merged 2 commits into
lumen-oss:mainfrom
teto:teto/dont-warn-on-empty-tags
Jul 27, 2026
Merged

fix: dont warn when no remote tags exist#102
mrcjkb merged 2 commits into
lumen-oss:mainfrom
teto:teto/dont-warn-on-empty-tags

Conversation

@teto

@teto teto commented Jul 27, 2026

Copy link
Copy Markdown
Member

My logs were full of scary warnings "Could not parse latest tag from
..".

turns out if a remote repo has no tags, we were trying to decode an
empty string parser.parse_git_latest_semver_tag(sc.stdout or "").
I special cased the empty-string (ie, no remote tags) so it appears as a debug level.

The test was not necessary but I added it while debugging and it doesn't hurt to have it.

I still have illegitimate failures I intend to fix as follow up

INFO | 2026-07-27 19:04:31.403 | ...m/start/rocks.nvim/lua/rocks/operations/helpers/init.lua:164 | Installed: menu -> scm
INFO | 2026-07-27 19:04:31.403 | /home/teto/plugins/rocks-git.nvim/lua/rocks-git/git.lua:38 | { "git", "ls-remote", "--tags", "https://github.com/elanmed/fzf-lua-frecency.nvim.git" }
WARN | 2026-07-27 19:04:31.817 | /home/teto/plugins/rocks-git.nvim/lua/rocks-git/git.lua:262 | Usign url https://github.com/elanmed/fzf-lua-frecency.nvim.git
DEBUG | 2026-07-27 19:04:31.818 | /home/teto/plugins/rocks-git.nvim/lua/rocks-git/git.lua:267 | No tag for https://github.com/elanmed/fzf-lua-frecency.nvim.git
INFO | 2026-07-27 19:04:31.821 | /home/teto/plugins/rocks-git.nvim/lua/rocks-git/git.lua:38 | { "git", "checkout", "ref: refs/remotes/up/master", "--force", "--recurse-submodules" }
ERROR | 2026-07-27 19:04:31.849 | /home/teto/plugins/rocks-git.nvim/lua/rocks-git/git.lua:180 | { "Could not checkout HEAD branch", "ref: refs/remotes/up/master", {
    code = 1,
    signal = 0,
    stderr = "erreur : le spécificateur de chemin 'ref: refs/remotes/up/master' ne correspond à aucun fichier connu de git\n",
    stdout = ""
  } }

teto added 2 commits July 27, 2026 19:11
My logs were full of scary warnings "Could not parse latest tag from
..".

turns out if a remote repo has no tags, we were trying to decode an
empty string `parser.parse_git_latest_semver_tag(sc.stdout or "")`.
I special cased the empty-string (ie, no remote tags) so it appears as a debug level.

ok
@teto
teto force-pushed the teto/dont-warn-on-empty-tags branch from df0f2a4 to 8a1add7 Compare July 27, 2026 17:11
@mrcjkb
mrcjkb merged commit 9a87db5 into lumen-oss:main Jul 27, 2026
3 checks passed
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

Successfully merging this pull request may close these issues.

2 participants