9front - general discussion about 9front
 help / color / mirror / Atom feed
* [9front] git bug: spurious deletion of libmp/tests
@ 2024-07-26 23:37 ori
  0 siblings, 0 replies; only message in thread
From: ori @ 2024-07-26 23:37 UTC (permalink / raw)
  To: 9front


Short summary: If you sysupdated recently and your
/sys/src/libmp/test/ directory is empty, run:

	bind -a /dist/plan9front /
	git/revert /sys/src/libmp/test

If there are currently files in the directory, no
action is needed.

What happened:

There was a bug in git that could lead to files gettings
puriously removed on pull when deleting a different file
with the same prefix in some rare circumstances.

This was discovered when I deleted /sys/src/libmp/test.c,
which lead to the /sys/src/libmp/test/ directory getting
cleared out.

Specifically, git sorts the entries in directory structures
strangely, sorting directory entries as though they ended
with a '/'. Git/query was sorting them using strcmp.

This meant that when diffing the directory entries, it
would iterate them in the wrong sort order, which lead
to all mis-compared directory entries being emitted as
removed and then added.

The bug has been fixed, and test.c has been put back
until people get a chance to update git and fix it.



^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~2024-07-26 23:39 UTC | newest]

Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2024-07-26 23:37 [9front] git bug: spurious deletion of libmp/tests ori

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).