{"thread":{"id":"25645","subject":"error: git checkout-index: unable to write file","startedAt":"2010-11-04T19:00:07Z","lastAt":"2010-11-04T19:22:39Z","messageCount":2,"participants":["Jonathan Nieder","Jeff King"],"isPatch":false,"patchVersion":null,"patchTotal":null},"messages":[{"id":"155194","messageId":"20101104190007.GA17101@burratino","threadId":"25645","inReplyTo":null,"subject":"error: git checkout-index: unable to write file","fromName":"Jonathan Nieder","fromEmail":"jrnieder@gmail.com","sentAt":"2010-11-04T19:00:07Z","receivedAt":"2010-11-04T19:00:07Z","isPatch":false,"sender":{"key":"jrnieder@gmail.com","avatar":"https://avatars.githubusercontent.com/u/281595?v=4"},"body":"Hi gitsters,\n\nJust tried cloning an enormous repo to /tmp (which uses tmpfs)\nand got\n\n error: git checkout-index: unable to write file webkit/tools/test_shell/resources/textAreaResizeCorner.png\n error: git checkout-index: unable to write file webkit/tools/test_shell/run_all_tests.cc\n error: git checkout-index: unable to write file webkit/tools/test_shell/simple_appcache_system.cc\n error: git checkout-index: unable to write file webkit/tools/test_shell/simple_appcache_system.h\n\n[etc].\n\nMaybe we can do better?  It seems non-ideal in a few ways:\n\n 1) it is not checkout-index but read-tree -m that prints the message\n 2) errno is forgotten\n 3) I would prefer if \"git clone\" errored out quickly for ENOSPC instead\n    of continuing to fill in the cracks with what small files it can\n    find.  Though I suppose the current behavior is better for errors\n    like EPERM and ENAMETOOLONG, so I can't complain much.\n"},{"id":"155196","messageId":"20101104192238.GA2381@sigill.intra.peff.net","threadId":"25645","inReplyTo":"20101104190007.GA17101@burratino","subject":"Re: error: git checkout-index: unable to write file","fromName":"Jeff King","fromEmail":"peff@peff.net","sentAt":"2010-11-04T19:22:39Z","receivedAt":"2010-11-04T19:22:39Z","isPatch":false,"sender":{"key":"peff@peff.net","avatar":"https://avatars.githubusercontent.com/u/45925?v=4"},"body":"On Thu, Nov 04, 2010 at 02:00:07PM -0500, Jonathan Nieder wrote:\n\n> Maybe we can do better?  It seems non-ideal in a few ways:\n> \n>  1) it is not checkout-index but read-tree -m that prints the message\n\nI would prefer that it print out \"clone\" if anything. But those \"git\ncheckout-index\" bits appear to be hard-coded in entry.c, probably from\nsome long-ago cut and paste. Yuck.\n\nProbably it should just be:\n\n   (\"error: unable to write %s: %s\", file, strerror(errno))\n\n>  2) errno is forgotten\n\nYup, that is poor.\n\n>  3) I would prefer if \"git clone\" errored out quickly for ENOSPC instead\n>     of continuing to fill in the cracks with what small files it can\n>     find.  Though I suppose the current behavior is better for errors\n>     like EPERM and ENAMETOOLONG, so I can't complain much.\n\nI'm not sure that the \"try to get whatever files you can out\" is ever\nparticularly useful, since the result is a broken repository. But if we\ndo subscribe to the theory that such a thing may be useful, I think it\ncan also be useful with ENOSPC. Consider a repository with a bunch of\nsmall files and one giant file. If the giant file fails, you might want\nto still be able to read the other stuff.\n\nAgain, that is assuming such a partial checkout is even useful. You can\nalways still pick things manually out of the index or the object db if\nyou really want to see them.\n\n-Peff\n"}]}