bugs/can't getgit-annexhttp://git-annex.branchable.com/bugs/can__39__t_get/git-annexikiwiki2014-01-18T15:43:00Zgit annex fix starts fixing but then spits bulk of errorshttp://git-annex.branchable.com/bugs/can__39__t_get/comment_1_ef32287828481c161bd913c9db9052a5/Yaroslav2014-01-18T05:42:15Z2014-01-18T05:42:15Z
<p>probably related:</p>
<pre><code>fix books/Мои первые книжки/PDF/Благинина Е.А. - Лодочки (Мои первые книжки) - 1962.pdf ok
fix books/Мои первые книжки/PDF/Благинина Е.А. - Не мешайте мне трудиться (Мои первые книжки) - 1975.pdf fatal: This operation must be run in a work tree
ok
(Recording state in git...)
git-annex: user error (xargs ["-0","git","--git-dir=/home/yoh/annex/.git","add","--force","--"] exited 123)
fatal: This operation must be run in a work tree
failed
(Recording state in git...)
git-annex: user error (xargs ["-0","git","--git-dir=/home/yoh/annex/.git","add","--force","--"] exited 123)
fatal: This operation must be run in a work tree
failed
(Recording state in git...)
....
</code></pre>
repair seems to be also confusedhttp://git-annex.branchable.com/bugs/can__39__t_get/comment_2_31fe400f4bac516a5c1101612cb06a54/Yaroslav2014-01-18T05:47:02Z2014-01-18T05:47:02Z
<p>[[[
$> git annex repair <br />
Running git fsck ...
No problems found.
fatal: '/home/yoh/annex/.git' is outside repository
Had to delete the .git/annex/index file as it was corrupt.
No data was lost.
ok</p>
<p>$> ls
2enjoy/ 2read/ 2watch/ books/ hardware/ videos/
2listen/ 2review/ abooks/ docs/ pics/</p>
<p>$> git annex repair
Running git fsck ...
No problems found.
fatal: '/home/yoh/annex/.git' is outside repository
Had to delete the .git/annex/index file as it was corrupt.
No data was lost.
ok</p>
<p>$> git annex get 2read/ISNN2010__Tang.pdf
git-annex: Cannot mix --all or --unused with file names.</p>
<p>]]]</p>
could it be part/reason of the problemhttp://git-annex.branchable.com/bugs/can__39__t_get/comment_3_87d123c04815d38abb92f967829c3a23/Yaroslav2014-01-18T06:05:50Z2014-01-18T06:05:50Z
<p>not sure how that happened... definitely not me consciously! <img src="http://git-annex.branchable.com/smileys/smile4.png" alt=";-)" /> some commands are complaining that "You cannot run this command in a bare repository" which I thought is BS since it is not BARE! but then looked into .git/config and it does have core.bare = True ... yikes!..</p>
<p>This repository is also under assistant "control".</p>
<p>changing to bare=False seems to start 'get'ing things, git annex repair doesn't produce obscure errors.</p>
<p>git annex fix though now doesn't report any problems -- only 'ok', but none of those files mentioned 'ok' has a working symlink,,, but I guess that is a fluke after many upgrades -- just dropping everything locally and getting needed context after purging .git/annex/objects .</p>
<p>So I guess issue is resolved by discovering that repository was set to 'bare' mode somehow although it was not and seemed like working but not quite</p>
comment 4http://git-annex.branchable.com/bugs/can__39__t_get/comment_4_b99cff87dbe38f08f888200dfe7e2436/joeyh.name2014-01-18T15:43:00Z2014-01-18T15:42:59Z
<p>git-annex sets core.bare=true for direct mode, but it also then sets annex.direct=true and so does not treat it as a bare mode repository. If you had eg, manually tried to change annex.direct to false, and left it in bare mode, that would explain everything.</p>
<blockquote><p>git annex fix though now doesn't report any problems -- only 'ok', but none of those files mentioned 'ok' has a working symlink</p></blockquote>
<p>That is completely normal behavior; git annex fix does not care if the content is locally present or not; it just checks that the symlinks would point to it if it were present.</p>
<p>(Fixed the partial function in dropunused.)</p>