Issue with repo sync :( (new one)

7,796 views
Skip to first unread message

christian starling

unread,
Jan 3, 2012, 2:29:50 AM1/3/12
to Android Building
Hey, i actually got past the error with being sutck at 99% but now im
stuck here:

Fetching projects: 100% (228/228), done.
Checking out files: 100% (18905/18905), done. files: 23%
(4359/18905)
Checking out files: 100% (4664/4664), done.
Checking out files: 100% (9386/9386), done.out files: 0% (2/9386)
Checking out files: 100% (5365/5365), done.
Checking out files: 100% (292/292), done.g out files: 5% (16/292)
Checking out files: 100% (41/41), done.ing out files: 4% (2/41)
Syncing work tree: 35% (80/228) fatal: This operation must be run in
a work tree
Traceback (most recent call last):
File "/home/christian/Documents/yum/.repo/repo/main.py", line 366,
in <module>
_Main(sys.argv[1:])
File "/home/christian/Documents/yum/.repo/repo/main.py", line 346,
in _Main
result = repo._Run(argv) or 0
File "/home/christian/Documents/yum/.repo/repo/main.py", line 137,
in _Run
result = cmd.Execute(copts, cargs)
File "/home/christian/Documents/yum/.repo/repo/subcmds/sync.py",
line 443, in Execute
project.Sync_LocalHalf(syncbuf)
File "/home/christian/Documents/yum/.repo/repo/project.py", line
975, in Sync_LocalHalf
self._InitWorkTree()
File "/home/christian/Documents/yum/.repo/repo/project.py", line
1758, in _InitWorkTree
raise GitError("cannot initialize work tree")
error.GitError: cannot initialize work tree


Does anyone know why this is? I would really like to learn to build,
but i cant if it dosent work! :D :(

Magnus Bäck

unread,
Jan 3, 2012, 2:40:42 PM1/3/12
to Android Building
On Tuesday, January 03, 2012 at 08:29 CET,
christian starling <chrisp...@gmail.com> wrote:

Can you run please

repo --trace sync -l

to reproduce the error with some more diagnostic output (the -l option
skips the network fetch and only runs the local checkout operation)?
I'm hoping to find out what git is giving you problem. Once that is
known we can narrow the debugging efforts.

You'd probably have better luck posting this on the repo-discuss list
which specifically deals with Repo and Gerrit issues.

--
Magnus B�ck Opinions are my own and do not necessarily
SW Configuration Manager represent the ones of my employer, etc.
Sony Ericsson

Christian Starling

unread,
Jan 4, 2012, 12:08:13 PM1/4/12
to android-...@googlegroups.com
I got this issue fixed actually :) But now im having an issue that i have tried and tried to fix and its not working, i really need help with it, im trying to build the source for a device but im getting this error...
make: *** No rule to make target `hardware/qcom/gps/loc_api/libloc_api-rpc/inc-20000/loc_api_cb.h', needed by `out/target/product/espresso/obj/include/libloc_api-rpc/inc/loc_api_cb.h'.  Stop.


--
Magnus Bäck                   Opinions are my own and do not necessarily

SW Configuration Manager      represent the ones of my employer, etc.
Sony Ericsson

--
You received this message because you are subscribed to the "Android Building" mailing list.
To post to this group, send email to android-...@googlegroups.com
To unsubscribe from this group, send email to
android-buildi...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-building?hl=en

Jean-Baptiste Queru

unread,
Jan 4, 2012, 12:29:19 PM1/4/12
to android-...@googlegroups.com
Please work with the maintainers of that specific code. That device
isn't supported in AOSP.

JBQ

--
Jean-Baptiste M. "JBQ" Queru
Software Engineer, Android Open-Source Project, Google.

Questions sent directly to me that have no reason for being private
will likely get ignored or forwarded to a public forum with no further
warning.

Vivek

unread,
Aug 2, 2013, 1:25:36 AM8/2/13
to android-...@googlegroups.com, chrisp...@gmail.com
Hi Christian,
How did you fix below error:

1758, in _InitWorkTree
    raise GitError("cannot initialize work tree")
error.GitError: cannot initialize work tree

I am getting the same error.
Thanks.

Magnus Bäck

unread,
Aug 2, 2013, 2:42:53 PM8/2/13
to android-...@googlegroups.com
On Friday, August 02, 2013 at 01:25 EDT,
Vivek <vivek...@gmail.com> wrote:

> How did you fix below error:
> 1758, in _InitWorkTree
> raise GitError("cannot initialize work tree")
> error.GitError: cannot initialize work tree
>
> I am getting the same error.

Can you please run

repo --trace sync -l

as suggested in my previous response in this thread?

--
Magnus Bäck
ba...@google.com

Vivek Arora

unread,
Aug 5, 2013, 2:28:35 AM8/5/13
to android-...@googlegroups.com
Magnus,

Below is the error log after using "repo --trace sync -l"

: cd /home/avivek/Linaro/android/device/linaro/pandaboard
: git read-tree --reset -u -v HEAD
: load refs /home/avivek/Linaro/android/.repo/projects/device/linaro/snowball.git

: cd /home/avivek/Linaro/android/device/linaro/snowball
: git read-tree --reset -u -v HEAD
: load refs /home/avivek/Linaro/android/.repo/projects/device/linaro/vexpress.git

: cd /home/avivek/Linaro/android/device/linaro/vexpress
: git read-tree --reset -u -v HEAD
: load refs /home/avivek/Linaro/android/.repo/projects/device/sample.git

: cd /home/avivek/Linaro/android/device/sample
: git read-tree --reset -u -v HEAD
: load refs /home/avivek/Linaro/android/.repo/projects/device/samsung/maguro.git

: cd /home/avivek/Linaro/android/device/samsung/maguro
: git read-tree --reset -u -v HEAD
: load refs /home/avivek/Linaro/android/.repo/projects/device/samsung/proprietary-open.git

: cd /home/avivek/Linaro/android/device/samsung/proprietary-open
: git read-tree --reset -u -v HEAD
fatal: failed to unpack tree object HEAD

Traceback (most recent call last):
  File "/home/avivek/Linaro/android/.repo/repo/main.py", line 414, in <module>
    _Main(sys.argv[1:])
  File "/home/avivek/Linaro/android/.repo/repo/main.py", line 390, in _Main

    result = repo._Run(argv) or 0
  File "/home/avivek/Linaro/android/.repo/repo/main.py", line 138, in _Run
    result = cmd.Execute(copts, cargs)
  File "/home/avivek/Linaro/android/.repo/repo/subcmds/sync.py", line 630, in Execute
    project.Sync_LocalHalf(syncbuf)
  File "/home/avivek/Linaro/android/.repo/repo/project.py", line 1060, in Sync_LocalHalf
    self._InitWorkTree()
  File "/home/avivek/Linaro/android/.repo/repo/project.py", line 1991, in _InitWorkTree

    raise GitError("cannot initialize work tree")
error.GitError: cannot initialize work tree


--

--
You received this message because you are subscribed to the "Android Building" mailing list.
To post to this group, send email to android-...@googlegroups.com
To unsubscribe from this group, send email to
android-buildi...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-building?hl=en

---
You received this message because you are subscribed to a topic in the Google Groups "Android Building" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/android-building/4hezYWTdHm4/unsubscribe.
To unsubscribe from this group and all its topics, send an email to android-buildi...@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.



Magnus Bäck

unread,
Aug 5, 2013, 9:27:09 AM8/5/13
to android-...@googlegroups.com
On Monday, August 05, 2013 at 02:28 EDT,
Vivek Arora <vivek...@gmail.com> wrote:

> Below is the error log after using "repo --trace sync -l"

[...]

> : cd /home/avivek/Linaro/android/device/samsung/proprietary-open
> : git read-tree --reset -u -v HEAD
> fatal: failed to unpack tree object HEAD

Okay, now we know the underlying Git error and the affected git. Try
nuking the worktree and the git itself and resync:

rm -rf ~/Linaro/android/device/samsung/proprietary-open \
~/Linaro/android/.repo/projects/device/samsung/proprietary-open.git
repo sync

[...]

--
Magnus Bäck
ba...@google.com

Vivek Arora

unread,
Aug 6, 2013, 12:18:30 AM8/6/13
to android-...@googlegroups.com
Thanks Magnus for your response, but it returns me the same Traceback:

avivek@avivek:~/Linaro$ rm -rf ~/Linaro/android/device/samsung/proprietary-open   ~/Linaro/android/.repo/projects/device/samsung/proprietary-open.git
avivek@avivek:~/Linaro$ repo sync

Traceback (most recent call last):
  File "/home/avivek/Linaro/.repo/repo/main.py", line 414, in <module>
    _Main(sys.argv[1:])
  File "/home/avivek/Linaro/.repo/repo/main.py", line 390, in _Main

    result = repo._Run(argv) or 0
  File "/home/avivek/Linaro/.repo/repo/main.py", line 122, in _Run
    copts, cargs = cmd.OptionParser.parse_args(argv)
  File "/home/avivek/Linaro/.repo/repo/command.py", line 67, in OptionParser
    self._Options(self._optparse)
  File "/home/avivek/Linaro/.repo/repo/subcmds/sync.py", line 152, in _Options
    self.jobs = self.manifest.default.sync_j
  File "/home/avivek/Linaro/.repo/repo/manifest_xml.py", line 292, in default
    self._Load()
  File "/home/avivek/Linaro/.repo/repo/manifest_xml.py", line 327, in _Load
    b = m.GetBranch(m.CurrentBranch).merge
  File "/home/avivek/Linaro/.repo/repo/project.py", line 573, in CurrentBranch
    b = self.work_git.GetHead()
  File "/home/avivek/Linaro/.repo/repo/project.py", line 2090, in GetHead
    raise NoManifestException(path)
error.NoManifestException: /home/avivek/Linaro/.repo/manifests/.git/HEAD




--
Magnus Bäck
ba...@google.com

Magnus Bäck

unread,
Aug 6, 2013, 2:41:16 PM8/6/13
to android-...@googlegroups.com
On Tuesday, August 06, 2013 at 00:18 EDT,
Vivek Arora <vivek...@gmail.com> wrote:

> Thanks Magnus for your response, but it returns me the same Traceback:

> avivek@avivek:~/Linaro$ rm -rf
> ~/Linaro/android/device/samsung/proprietary-open
> ~/Linaro/android/.repo/projects/device/samsung/proprietary-open.git
> avivek@avivek:~/Linaro$ repo sync
> Traceback (most recent call last):

[...]

> File "/home/avivek/Linaro/.repo/repo/project.py", line 2090, in GetHead
> raise NoManifestException(path)
> error.NoManifestException: /home/avivek/Linaro/.repo/manifests/.git/HEAD

Well, this is a completely different error. It appears your manifest git
it hosed too. Unless you have a very bad connection I suggest you wipe
what you've got and start over again.

--
Magnus Bäck
ba...@google.com

Abhishek Upadhyay

unread,
May 11, 2016, 9:59:38 AM5/11/16
to Android Building, chrisp...@gmail.com
Hi Christian Starling, i got same error 
"fatal: failed to unpack tree object HEAD Traceback (most recent call last)
GitError("cannot initialize work tree")
error.GitError: cannot initialize work tree"

Do you have solution for that please help me out . You said that you fixed it. 

Abhishek Upadhyay

unread,
May 19, 2016, 1:04:00 AM5/19/16
to Android Building, chrisp...@gmail.com
Reply all
Reply to author
Forward
0 new messages