[Bug 36381] New: "not a tree object" error from Jenkins
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=36381 Bug ID: 36381 Summary: "not a tree object" error from Jenkins Change sponsored?: --- Product: Koha Version: unspecified Hardware: All OS: All Status: NEW Severity: major Priority: P5 - low Component: Test Suite Assignee: chris@bigballofwax.co.nz Reporter: jonathan.druart@gmail.com QA Contact: testopia@bugs.koha-community.org "not a tree object" warning on Jenkins. It's like the test are not run inside a git repository: koha_1 | error: object directory /srv/jenkins/workspace/Koha_Source/.git/objects does not exist; check .git/objects/info/alternates koha_1 | error: Could not read 3288f3a2129207626916d7a7b49f580c16d097a1 koha_1 | Nothing to critique at t/00-testcritic.t line 18. koha_1 | [18:52:15] t/00-testcritic.t ........................................................... koha_1 | Dubious, test returned 25 (wstat 6400, 0x1900) koha_1 | No subtests run In this case we have t/00-testcritic.t that is failing. But even on green runs we see: koha_1 | error: object directory /srv/jenkins/workspace/Koha_Source/.git/objects does not exist; check .git/objects/info/alternates koha_1 | fatal: not a tree object koha_1 | [18:17:56] t/00-testcritic.t And lot of other "not a tree object" error (I guess everytime we run 'git' commands from tests). -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=36381 --- Comment #1 from Jonathan Druart <jonathan.druart@gmail.com> ---
From #koha-bots, earlier this year
[08:43:33] <Joubu> So I was looking at: https://jenkins.koha-community.org/job/Koha_Master/2796/consoleText [08:43:35] <ashimema> haha, no worries [08:43:36] <Joubu> the last one [08:43:37] <Joubu> and noticed:. [08:43:43] <Joubu> koha_1 | error: object directory /srv/jenkins/workspace/Koha_Source/.git/objects does not exist; check .git/objects/info/alternates [08:43:46] <Joubu> koha_1 | fatal: not a tree object [08:44:00] <Joubu> and I thought it was because or Koha_Source not existing at the beginning of the run [09:02:29] <Joubu> Does `git ls-tree -d --name-only HEAD` work? [09:02:55] <Joubu> it should return the list of the directories at the root of Koha [09:03:56] <ashimema> yup [09:04:02] <ashimema> looks present and correct [09:04:10] <Joubu> ok good [09:04:57] <Joubu> so, Koha_Master is currently running and git command works correctly. We will wait for the end of the run, where the "not a tree object" errors appear [09:05:36] <Joubu> if they do not appear, it means Koha_Source is not correct (corrupt, or bare repo?) on the nodes where the errors pop up [09:06:48] <Joubu> look at this one: [09:06:54] <Joubu> https://jenkins.koha-community.org/job/Koha_23.05_U22/155/consoleText on Docker_7 [09:07:05] <Joubu> => no "not a tree" errors [09:07:21] <Joubu> the next run https://jenkins.koha-community.org/job/Koha_23.05_U22/156/consoleText on Docker_15 [09:07:26] <Joubu> => lot of "not a tree" errors [09:07:55] <ashimema> I think jake recloned a bunch yesterday afternoon using github instead of gittea [09:08:45] <Joubu> this last run of from 2024-02-07 19:27:28. [09:14:07] <Joubu> ashimema: There is a current run on Docker_15 [09:14:43] <Joubu> the errors didn't appear yet but it would be interesting to inspect the clone there [09:14:54] <Joubu> and run `git ls-tree -d --name-only HEAD` [09:16:35] <ashimema> all looks good there too [09:17:38] <Joubu> hum ok, weird [09:17:56] <Joubu> let's see if the errors appear then -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=36381 Jonathan Druart <jonathan.druart@gmail.com> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |martin.renvoize@ptfs-europe | |.com, tomascohen@gmail.com -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=36381 --- Comment #2 from Jonathan Druart <jonathan.druart@gmail.com> --- Not getting this error on Docker_7 but the warning error: unable to normalize alternate object path: /srv/jenkins/workspace/Koha_Source/.git/objects Indeed: /srv/jenkins/workspace/xxx_test$ grep -r Koha_Source .git .git/objects/info/alternates:/srv/jenkins/workspace/Koha_Source/.git/objects The tests are not failing but there warnings is not expected. I have tried to: 1. Remove "Honor refspec on initial clone" 2. Remove "Shallow clone" None removed the warning. -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=36381 --- Comment #3 from Jonathan Druart <jonathan.druart@gmail.com> --- (Not sure it's related to the "not a tree object" error however) -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=36381 --- Comment #4 from Katrin Fischer <katrin.fischer@bsz-bw.de> --- The testcritic failed again, more eyes/brains on this problem welcome. -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=36381 --- Comment #5 from Jonathan Druart <jonathan.druart@gmail.com> --- (In reply to Katrin Fischer from comment #4)
The testcritic failed again, more eyes/brains on this problem welcome.
Koha_Master/2823 on Docker_15 -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=36381 --- Comment #6 from Jonathan Druart <jonathan.druart@gmail.com> --- I run out of ideas, we need somebody else to look into this. -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=36381 --- Comment #7 from Jonathan Druart <jonathan.druart@gmail.com> --- This is happening all the time with Docker_15 (last one is Koha_Master/2827) It's coming from the 'git ls-tree' calls t/00-testcritic.t:my @files = map { chomp; $_ } `git ls-tree -r HEAD --name-only`; # only files part of git t/Makefile.t:my @files = `git ls-tree HEAD|tr -s '\t' ' '|cut -d' ' -f4`; xt/check_makefile.t:my @dirs = `git ls-tree -d --name-only HEAD`; My guess is that it's coming from PTFS-e's nodes. -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=36381 --- Comment #8 from Tomás Cohen Arazi <tomascohen@gmail.com> --- Have we been able to reproduce one of this errors/warnings locally? It certainly comes from the fact Jenkins is making a shallow clone from a directory. The tip of the iceberg is the 'Koha_Source', as that name shouldn't be mentioned at all on the Jenkins runs: the clone is named as the task. Maybe it is a git version thing? -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=36381 --- Comment #9 from Jonathan Druart <jonathan.druart@gmail.com> --- (In reply to Tomás Cohen Arazi from comment #8)
Have we been able to reproduce one of this errors/warnings locally? It certainly comes from the fact Jenkins is making a shallow clone from a directory.
No, see comment 2. I have tried to remove that. -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=36381 --- Comment #10 from Jonathan Druart <jonathan.druart@gmail.com> --- Koha_Master_D12/819 Docker_10 koha_1 | error: unable to normalize alternate object path: /srv/jenkins/workspace/Koha_Source/.git/objects koha_1 | error: Could not read edda4e1bdb0943e43eb80faeb8b71de397327d04 koha_1 | Nothing to critique at t/00-testcritic.t line 18. koha_1 | [07:34:05] t/00-testcritic.t koha_1 | Dubious, test returned 25 (wstat 6400, 0x1900) koha_1 | No subtests run -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=36381 --- Comment #11 from Jonathan Druart <jonathan.druart@gmail.com> --- Koha_Master/2831 Docker_15 -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=36381 --- Comment #12 from Jonathan Druart <jonathan.druart@gmail.com> --- They all failed Koha_Master_U20/1160 Docker_13 Koha_Master_D10/1443 Docker_14 -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=36381 --- Comment #13 from Jonathan Druart <jonathan.druart@gmail.com> --- With the same id edda4e1bdb0943e43eb80faeb8b71de397327d04: % git show edda4e1bdb0943e43eb80faeb8b71de397327d04 tree edda4e1bdb0943e43eb80faeb8b71de397327d04 I am wondering if PTFS-e's nodes are not tracking gitlab which could be behind github/git.k-c.org? -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=36381 --- Comment #14 from Jonathan Druart <jonathan.druart@gmail.com> --- (In reply to Jonathan Druart from comment #13)
With the same id edda4e1bdb0943e43eb80faeb8b71de397327d04:
% git show edda4e1bdb0943e43eb80faeb8b71de397327d04 tree edda4e1bdb0943e43eb80faeb8b71de397327d04
I am wondering if PTFS-e's nodes are not tracking gitlab which could be behind github/git.k-c.org?
The trigger on (at least) U20 is on gitlab, so not sure this makes sense. -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=36381 Katrin Fischer <katrin.fischer@bsz-bw.de> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |katrin.fischer@bsz-bw.de --- Comment #15 from Katrin Fischer <katrin.fischer@bsz-bw.de> --- *** Bug 36903 has been marked as a duplicate of this bug. *** -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=36381 --- Comment #16 from Martin Renvoize <martin.renvoize@ptfs-europe.com> --- (In reply to Jonathan Druart from comment #13)
With the same id edda4e1bdb0943e43eb80faeb8b71de397327d04:
% git show edda4e1bdb0943e43eb80faeb8b71de397327d04 tree edda4e1bdb0943e43eb80faeb8b71de397327d04
I am wondering if PTFS-e's nodes are not tracking gitlab which could be behind github/git.k-c.org?
origin https://github.com/Koha-Community/Koha.git (fetch) So, no.. it's not that. -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=36381 Jonathan Druart <jonathan.druart@gmail.com> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |jake.deery@ptfs-europe.com --- Comment #17 from Jonathan Druart <jonathan.druart@gmail.com> --- Worked with Jake today to tackle this one down. The "not a tree object" / "Nothing to critique" appeared on PTFS-E nodes because the content of the repository had been removed at some point, only .git existed. A full new clone has been done and this error is now gone. The "error: object directory" / "Could not read" has been fixed by removing the "Honor refspec" from the job's config (unlike what I stated in comment 2. This change has been done on all Koha_Master* job. Not stables (yet). Before: https://snipboard.io/RCkJuS.jpg After : https://snipboard.io/vuVscO.jpg -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=36381 --- Comment #18 from Jonathan Druart <jonathan.druart@gmail.com> --- (In reply to Jonathan Druart from comment #17)
This change has been done on all Koha_Master* job. Not stables (yet).
And jobs within "security". -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=36381 --- Comment #19 from Jonathan Druart <jonathan.druart@gmail.com> --- Considering this done. However RMaints should update the jobs config on Jenkins. -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=36381 Jonathan Druart <jonathan.druart@gmail.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Resolution|--- |FIXED Status|NEW |RESOLVED --- Comment #20 from Jonathan Druart <jonathan.druart@gmail.com> --- (In reply to Jonathan Druart from comment #19)
Considering this done. However RMaints should update the jobs config on Jenkins.
Well actually I am not sure it's a good idea to let people edit the config of the jobs. It's something for "Continuous integration infrastructure maintainer", which is... nobody this cycle. -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=36381 Jonathan Druart <jonathan.druart@gmail.com> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |f.demians@tamil.fr, | |fridolin.somers@biblibre.co | |m, | |lucas@bywatersolutions.com, | |mtj@kohaaloha.com, | |wainuiwitikapark@catalyst.n | |et.nz --- Comment #21 from Jonathan Druart <jonathan.druart@gmail.com> --- (In reply to Jonathan Druart from comment #18)
(In reply to Jonathan Druart from comment #17)
This change has been done on all Koha_Master* job. Not stables (yet).
And jobs within "security".
Done now for all jobs marked as "Enabled" for 24.05, 23.11, 23.05 and 22.11. tl;dr; for RMaints: now the t/00-testcritic.t should no longer fail with "Nothing to critique". -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=36381 Jonathan Druart <jonathan.druart@gmail.com> changed: What |Removed |Added ---------------------------------------------------------------------------- See Also| |https://bugs.koha-community | |.org/bugzilla3/show_bug.cgi | |?id=39304 -- You are receiving this mail because: You are watching all bug changes.
participants (1)
-
bugzilla-daemon@bugs.koha-community.org