* Test failure @ 2017-09-01 3:34 Ian Zimmerman 2017-09-01 5:09 ` David Gibson 2017-09-02 3:50 ` Rusty Russell 0 siblings, 2 replies; 13+ messages in thread From: Ian Zimmerman @ 2017-09-01 3:34 UTC (permalink / raw) To: ccan Trying to run make check on current master, I get: [many successful tests snipped] tools/ccanlint/ccanlint -s --deps-fail-ignore ccan/io/ && touch ccan/io/.ok io: Module examples with expected output give that output (examples_run): FAIL /tmp/ccanlint-24192.1804289383/example-_info-io.c:2:output '' didn't match 'tr a-z a-z' io: Total score: 82/87 FAIL! make: *** [Makefile:78: ccan/io/.ok] Error 1 What's up? -- Please don't Cc: me privately on mailing lists and Usenet, if you also post the followup to the list or newsgroup. Do obvious transformation on domain to reply privately _only_ on Usenet. _______________________________________________ ccan mailing list ccan@lists.ozlabs.org https://lists.ozlabs.org/listinfo/ccan ^ permalink raw reply [flat|nested] 13+ messages in thread
* Re: Test failure 2017-09-01 3:34 Test failure Ian Zimmerman @ 2017-09-01 5:09 ` David Gibson 2017-09-01 16:30 ` Ian Zimmerman 2017-09-02 3:50 ` Rusty Russell 1 sibling, 1 reply; 13+ messages in thread From: David Gibson @ 2017-09-01 5:09 UTC (permalink / raw) To: ccan [-- Attachment #1.1: Type: text/plain, Size: 731 bytes --] On Thu, Aug 31, 2017 at 08:34:21PM -0700, Ian Zimmerman wrote: > Trying to run make check on current master, I get: > > [many successful tests snipped] > > tools/ccanlint/ccanlint -s --deps-fail-ignore ccan/io/ && touch ccan/io/.ok > io: Module examples with expected output give that output (examples_run): FAIL > /tmp/ccanlint-24192.1804289383/example-_info-io.c:2:output '' didn't match 'tr a-z a-z' > > io: Total score: 82/87 FAIL! > make: *** [Makefile:78: ccan/io/.ok] Error 1 > > What's up? What platform? -- David Gibson | I'll have my music baroque, and my code david AT gibson.dropbear.id.au | minimalist, thank you. NOT _the_ _other_ | _way_ _around_! http://www.ozlabs.org/~dgibson [-- Attachment #1.2: signature.asc --] [-- Type: application/pgp-signature, Size: 833 bytes --] [-- Attachment #2: Type: text/plain, Size: 127 bytes --] _______________________________________________ ccan mailing list ccan@lists.ozlabs.org https://lists.ozlabs.org/listinfo/ccan ^ permalink raw reply [flat|nested] 13+ messages in thread
* Re: Test failure 2017-09-01 5:09 ` David Gibson @ 2017-09-01 16:30 ` Ian Zimmerman 0 siblings, 0 replies; 13+ messages in thread From: Ian Zimmerman @ 2017-09-01 16:30 UTC (permalink / raw) To: ccan On 2017-09-01 15:09, David Gibson wrote: > On Thu, Aug 31, 2017 at 08:34:21PM -0700, Ian Zimmerman wrote: > > Trying to run make check on current master, I get: > > > > [many successful tests snipped] > > > > tools/ccanlint/ccanlint -s --deps-fail-ignore ccan/io/ && touch ccan/io/.ok > > io: Module examples with expected output give that output (examples_run): FAIL > > /tmp/ccanlint-24192.1804289383/example-_info-io.c:2:output '' didn't match 'tr a-z a-z' > > > > io: Total score: 82/87 FAIL! > > make: *** [Makefile:78: ccan/io/.ok] Error 1 > > > > What's up? > > What platform? matica!1 ~$ gcc --version gcc (Gentoo 5.4.0-r3 p1.3, pie-0.6.5) 5.4.0 Copyright (C) 2015 Free Software Foundation, Inc. This is free software; see the source for copying conditions. There is NO warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. matica!2 ~$ uname -a Linux matica 4.4.84 #1 SMP Fri Aug 25 22:31:12 PDT 2017 x86_64 AMD Phenom(tm) II X4 955 Processor AuthenticAMD GNU/Linux matica!3 ~$ ld --version GNU ld (Gentoo 2.28.1 p1.0) 2.28.1 Copyright (C) 2017 Free Software Foundation, Inc. This program is free software; you may redistribute it under the terms of the GNU General Public License version 3 or (at your option) a later version. This program has absolutely no warranty. matica!8 ~$ info libc | head -7 | tail -2 This is ‘The GNU C Library Reference Manual’, for Version 2.23 (Gentoo 2.23-r4 p8) of the GNU C Library. matica!9 ~$ info coreutils | head -7 | tail -2 This manual documents version 8.25 of the GNU core utilities, including the standard programs for text and file manipulation. -- Please don't Cc: me privately on mailing lists and Usenet, if you also post the followup to the list or newsgroup. Do obvious transformation on domain to reply privately _only_ on Usenet. _______________________________________________ ccan mailing list ccan@lists.ozlabs.org https://lists.ozlabs.org/listinfo/ccan ^ permalink raw reply [flat|nested] 13+ messages in thread
* Re: Test failure 2017-09-01 3:34 Test failure Ian Zimmerman 2017-09-01 5:09 ` David Gibson @ 2017-09-02 3:50 ` Rusty Russell 2017-09-02 8:00 ` Ian Zimmerman 1 sibling, 1 reply; 13+ messages in thread From: Rusty Russell @ 2017-09-02 3:50 UTC (permalink / raw) To: ccan Ian Zimmerman <itz@very.loosely.org> writes: > Trying to run make check on current master, I get: > > [many successful tests snipped] > > tools/ccanlint/ccanlint -s --deps-fail-ignore ccan/io/ && touch ccan/io/.ok > io: Module examples with expected output give that output (examples_run): FAIL > /tmp/ccanlint-24192.1804289383/example-_info-io.c:2:output '' didn't match 'tr a-z a-z' > > io: Total score: 82/87 FAIL! > make: *** [Makefile:78: ccan/io/.ok] Error 1 > > What's up? Hmm, can't reproduce here. Can you run this test manually? $ tools/ccanlint/ccanlint -k --target=examples_run ccan/io $ echo tr A-Z a-z | strace /tmp/ccanlint-*/example-_info-io tr A-Z a-z The output should show what's going wrong. Thanks! Rusty. _______________________________________________ ccan mailing list ccan@lists.ozlabs.org https://lists.ozlabs.org/listinfo/ccan ^ permalink raw reply [flat|nested] 13+ messages in thread
* Re: Test failure 2017-09-02 3:50 ` Rusty Russell @ 2017-09-02 8:00 ` Ian Zimmerman 2017-09-04 0:51 ` Rusty Russell 0 siblings, 1 reply; 13+ messages in thread From: Ian Zimmerman @ 2017-09-02 8:00 UTC (permalink / raw) To: ccan [-- Attachment #1: Type: text/plain, Size: 918 bytes --] On 2017-09-02 13:20, Rusty Russell wrote: > > tools/ccanlint/ccanlint -s --deps-fail-ignore ccan/io/ && touch ccan/io/.ok > > io: Module examples with expected output give that output (examples_run): FAIL > > /tmp/ccanlint-24192.1804289383/example-_info-io.c:2:output '' didn't match 'tr a-z a-z' > > > > io: Total score: 82/87 FAIL! > > make: *** [Makefile:78: ccan/io/.ok] Error 1 > > > > What's up? > > Hmm, can't reproduce here. > > Can you run this test manually? > > $ tools/ccanlint/ccanlint -k --target=examples_run ccan/io > $ echo tr A-Z a-z | strace /tmp/ccanlint-*/example-_info-io tr A-Z a-z > > The output should show what's going wrong. Attached. I can't make any sense of it w/o dropping to gdb. -- Please don't Cc: me privately on mailing lists and Usenet, if you also post the followup to the list or newsgroup. Do obvious transformation on domain to reply privately _only_ on Usenet. [-- Attachment #2: test_output --] [-- Type: text/plain, Size: 4357 bytes --] execve("/tmp/ccanlint-2217.1804289383/example-_info-io", ["/tmp/ccanlint-2217.1804289383/ex"..., "/tmp/ccanlint-28097.1804289383/e"..., "tr", "A-Z", "a-z"], [/* 51 vars */]) = 0 brk(NULL) = 0x7ee000 mmap(NULL, 4096, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_ANONYMOUS, -1, 0) = 0x7f6c74233000 access("/etc/ld.so.preload", R_OK) = -1 ENOENT (No such file or directory) open("/etc/ld.so.cache", O_RDONLY|O_CLOEXEC) = 3 fstat(3, {st_mode=S_IFREG|0644, st_size=114539, ...}) = 0 mmap(NULL, 114539, PROT_READ, MAP_PRIVATE, 3, 0) = 0x7f6c74217000 close(3) = 0 open("/lib64/libc.so.6", O_RDONLY|O_CLOEXEC) = 3 read(3, "\177ELF\2\1\1\3\0\0\0\0\0\0\0\0\3\0>\0\1\0\0\0\340\7\2\0\0\0\0\0"..., 832) = 832 fstat(3, {st_mode=S_IFREG|0755, st_size=1680808, ...}) = 0 mmap(NULL, 3786968, PROT_READ|PROT_EXEC, MAP_PRIVATE|MAP_DENYWRITE, 3, 0) = 0x7f6c73c74000 mprotect(0x7f6c73e07000, 2097152, PROT_NONE) = 0 mmap(0x7f6c74007000, 24576, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_FIXED|MAP_DENYWRITE, 3, 0x193000) = 0x7f6c74007000 mmap(0x7f6c7400d000, 14552, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_FIXED|MAP_ANONYMOUS, -1, 0) = 0x7f6c7400d000 close(3) = 0 mmap(NULL, 4096, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_ANONYMOUS, -1, 0) = 0x7f6c74216000 mmap(NULL, 4096, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_ANONYMOUS, -1, 0) = 0x7f6c74215000 mmap(NULL, 4096, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_ANONYMOUS, -1, 0) = 0x7f6c74214000 arch_prctl(ARCH_SET_FS, 0x7f6c74215700) = 0 mprotect(0x7f6c74007000, 16384, PROT_READ) = 0 mprotect(0x60a000, 4096, PROT_READ) = 0 mprotect(0x7f6c74234000, 4096, PROT_READ) = 0 munmap(0x7f6c74217000, 114539) = 0 pipe([3, 4]) = 0 pipe([5, 6]) = 0 clone(child_stack=NULL, flags=CLONE_CHILD_CLEARTID|CLONE_CHILD_SETTID|SIGCHLD, child_tidptr=0x7f6c742159d0) = 4488 close(3) = 0 close(6) = 0 rt_sigaction(SIGPIPE, {sa_handler=SIG_IGN, sa_mask=[PIPE], sa_flags=SA_RESTORER|SA_RESTART, sa_restorer=0x7f6c73ca7690}, {sa_handler=SIG_DFL, sa_mask=[], sa_flags=0}, 8) = 0 brk(NULL) = 0x7ee000 brk(0x80f000) = 0x80f000 fcntl(0, F_GETFL) = 0 (flags O_RDONLY) fcntl(0, F_SETFL, O_RDONLY|O_NONBLOCK) = 0 fcntl(4, F_GETFL) = 0x1 (flags O_WRONLY) fcntl(4, F_SETFL, O_WRONLY|O_NONBLOCK) = 0 fcntl(5, F_GETFL) = 0 (flags O_RDONLY) fcntl(5, F_SETFL, O_RDONLY|O_NONBLOCK) = 0 fcntl(1, F_GETFL) = 0x8402 (flags O_RDWR|O_APPEND|O_LARGEFILE) fcntl(1, F_SETFL, O_RDWR|O_APPEND|O_NONBLOCK|O_LARGEFILE) = 0 poll([{fd=0, events=POLLIN}, {fd=-4}, {fd=5, events=POLLIN}, {fd=1, events=POLLOUT}], 4, -1) = 3 ([{fd=0, revents=POLLIN|POLLHUP}, {fd=5, revents=POLLIN}, {fd=1, revents=POLLOUT}]) read(0, "tr A-Z a-z\n", 4096) = 11 read(5, "\0", 4095) = 1 write(1, "\0", 1) = 1 poll([{fd=0, events=POLLIN}, {fd=4, events=POLLOUT}, {fd=5, events=POLLIN}, {fd=1, events=POLLOUT}], 4, -1) = 3 ([{fd=0, revents=POLLHUP}, {fd=4, revents=POLLOUT}, {fd=1, revents=POLLOUT}]) close(0) = 0 write(4, "tr A-Z a-z\n", 11) = 11 close(4) = 0 poll([{fd=1, events=POLLOUT}, {fd=5, events=POLLIN}], 2, -1) = 1 ([{fd=1, revents=POLLOUT}]) write(1, "\0", 1) = 1 poll([{fd=-1}, {fd=5, events=POLLIN}], 2, -1) = 1 ([{fd=5, revents=POLLIN}]) read(5, "r a-z a-z\n", 4094) = 10 poll([{fd=1, events=POLLOUT}, {fd=5, events=POLLIN}], 2, -1) = 2 ([{fd=1, revents=POLLOUT}, {fd=5, revents=POLLHUP}]) --- SIGCHLD {si_signo=SIGCHLD, si_code=CLD_EXITED, si_pid=4488, si_uid=1000, si_status=0, si_utime=0, si_stime=0} --- write(1, " a-z a-z\n", 9 a-z a-z ) = 9 close(5) = 0 poll([{fd=1, events=POLLOUT}], 1, -1) = 1 ([{fd=1, revents=POLLOUT}]) write(1, "\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0"..., 18446744073709551607) = -1 EFAULT (Bad address) close(1) = 0 wait4(-1, [{WIFEXITED(s) && WEXITSTATUS(s) == 0}], 0, NULL) = 4488 exit_group(0) = ? +++ exited with 0 +++ [-- Attachment #3: Type: text/plain, Size: 127 bytes --] _______________________________________________ ccan mailing list ccan@lists.ozlabs.org https://lists.ozlabs.org/listinfo/ccan ^ permalink raw reply [flat|nested] 13+ messages in thread
* Re: Test failure 2017-09-02 8:00 ` Ian Zimmerman @ 2017-09-04 0:51 ` Rusty Russell 2017-09-04 5:32 ` Ian Zimmerman 0 siblings, 1 reply; 13+ messages in thread From: Rusty Russell @ 2017-09-04 0:51 UTC (permalink / raw) To: Ian Zimmerman, ccan So many bugs in one example program! There was an unrelated but which strace revealed (trying to write -7 bytes), but I think your issue was more prosaic: failing to zero the from buffer. Does this patch fix it for you? Thanks! Rusty. diff --git a/ccan/io/_info b/ccan/io/_info index fe49df5c..6e95e4ab 100644 --- a/ccan/io/_info +++ b/ccan/io/_info @@ -61,9 +61,10 @@ * { * // Remove what we just wrote. * b->start += b->wlen; + * b->wlen = 0; * assert(b->start <= sizeof(b->buf)); * - * // If we wrote something, wake writer. + * // If we wrote something, wake reader. * if (b->wlen != 0) * io_wake(b); * @@ -114,6 +115,7 @@ * io_new_conn(NULL, tochild[1], write_out, &to); * * // Read from child, write to stdout. + * memset(&from, 0, sizeof(from)); * reader = io_new_conn(NULL, fromchild[0], read_in, &from); * io_set_finish(reader, finish, &from); * io_new_conn(NULL, STDOUT_FILENO, write_out, &from); _______________________________________________ ccan mailing list ccan@lists.ozlabs.org https://lists.ozlabs.org/listinfo/ccan ^ permalink raw reply related [flat|nested] 13+ messages in thread
* Re: Test failure 2017-09-04 0:51 ` Rusty Russell @ 2017-09-04 5:32 ` Ian Zimmerman 0 siblings, 0 replies; 13+ messages in thread From: Ian Zimmerman @ 2017-09-04 5:32 UTC (permalink / raw) To: ccan On 2017-09-04 10:21, Rusty Russell wrote: > So many bugs in one example program! > > There was an unrelated but which strace revealed (trying to write -7 > bytes), but I think your issue was more prosaic: failing to zero the > from buffer. > > Does this patch fix it for you? It does indeed. Now I can at last think about writing my own code and tests :-) Thanks. Btw, no need to Cc me, I'm subscribed to the list. -- Please don't Cc: me privately on mailing lists and Usenet, if you also post the followup to the list or newsgroup. Do obvious transformation on domain to reply privately _only_ on Usenet. _______________________________________________ ccan mailing list ccan@lists.ozlabs.org https://lists.ozlabs.org/listinfo/ccan ^ permalink raw reply [flat|nested] 13+ messages in thread
* test failure @ 2016-12-16 20:32 Ramsay Jones 2016-12-17 14:28 ` Lars Schneider 0 siblings, 1 reply; 13+ messages in thread From: Ramsay Jones @ 2016-12-16 20:32 UTC (permalink / raw) To: Lars Schneider; +Cc: Junio C Hamano, GIT Mailing-list Hi Lars, For the last two days, I've noticed t0021.15 on the 'pu' branch has been failing intermittently (well it fails with: 'make test >ptest-out', but when run by hand, it fails only say 1-in-6, 1-in-18, etc.). [yes, it's a bit strange; this hasn't changed in a couple of weeks!] I don't have time to investigate further tonight and, since I had not heard anyone else complain, I thought I should let you know. See below for the output from a failing run. [Note: this is on Linux Mint 18, tonight's pu branch @7c7984401]. ATB, Ramsay Jones $ ./t0021-conversion.sh -i -v ... ok 14 - diff does not reuse worktree files that need cleaning expecting success: test_config_global filter.protocol.process "rot13-filter.pl clean smudge" && test_config_global filter.protocol.required true && rm -rf repo && mkdir repo && ( cd repo && git init && echo "*.r filter=protocol" >.gitattributes && git add . && git commit -m "test commit 1" && git branch empty-branch && cp "$TEST_ROOT/test.o" test.r && cp "$TEST_ROOT/test2.o" test2.r && mkdir testsubdir && cp "$TEST_ROOT/test3 'sq',\$x=.o" "testsubdir/test3 'sq',\$x=.r" && >test4-empty.r && S=$(file_size test.r) && S2=$(file_size test2.r) && S3=$(file_size "testsubdir/test3 'sq',\$x=.r") && filter_git add . && cat >expected.log <<-EOF && START init handshake complete IN: clean test.r $S [OK] -- OUT: $S . [OK] IN: clean test2.r $S2 [OK] -- OUT: $S2 . [OK] IN: clean test4-empty.r 0 [OK] -- OUT: 0 [OK] IN: clean testsubdir/test3 'sq',\$x=.r $S3 [OK] -- OUT: $S3 . [OK] STOP EOF test_cmp_count expected.log rot13-filter.log && filter_git commit -m "test commit 2" && cat >expected.log <<-EOF && START init handshake complete IN: clean test.r $S [OK] -- OUT: $S . [OK] IN: clean test2.r $S2 [OK] -- OUT: $S2 . [OK] IN: clean test4-empty.r 0 [OK] -- OUT: 0 [OK] IN: clean testsubdir/test3 'sq',\$x=.r $S3 [OK] -- OUT: $S3 . [OK] IN: clean test.r $S [OK] -- OUT: $S . [OK] IN: clean test2.r $S2 [OK] -- OUT: $S2 . [OK] IN: clean test4-empty.r 0 [OK] -- OUT: 0 [OK] IN: clean testsubdir/test3 'sq',\$x=.r $S3 [OK] -- OUT: $S3 . [OK] STOP EOF test_cmp_count expected.log rot13-filter.log && rm -f test2.r "testsubdir/test3 'sq',\$x=.r" && filter_git checkout --quiet --no-progress . && cat >expected.log <<-EOF && START init handshake complete IN: smudge test2.r $S2 [OK] -- OUT: $S2 . [OK] IN: smudge testsubdir/test3 'sq',\$x=.r $S3 [OK] -- OUT: $S3 . [OK] STOP EOF test_cmp_exclude_clean expected.log rot13-filter.log && filter_git checkout --quiet --no-progress empty-branch && cat >expected.log <<-EOF && START init handshake complete IN: clean test.r $S [OK] -- OUT: $S . [OK] STOP EOF test_cmp_exclude_clean expected.log rot13-filter.log && filter_git checkout --quiet --no-progress master && cat >expected.log <<-EOF && START init handshake complete IN: smudge test.r $S [OK] -- OUT: $S . [OK] IN: smudge test2.r $S2 [OK] -- OUT: $S2 . [OK] IN: smudge test4-empty.r 0 [OK] -- OUT: 0 [OK] IN: smudge testsubdir/test3 'sq',\$x=.r $S3 [OK] -- OUT: $S3 . [OK] STOP EOF test_cmp_exclude_clean expected.log rot13-filter.log && test_cmp_committed_rot13 "$TEST_ROOT/test.o" test.r && test_cmp_committed_rot13 "$TEST_ROOT/test2.o" test2.r && test_cmp_committed_rot13 "$TEST_ROOT/test3 'sq',\$x=.o" "testsubdir/test3 'sq',\$x=.r" ) Initialized empty Git repository in /home/ramsay/git/t/trash directory.t0021-conversion/repo/.git/ [master (root-commit) 56d459b] test commit 1 Author: A U Thor <author@example.com> 1 file changed, 1 insertion(+) create mode 100644 .gitattributes [master 9ea74df] test commit 2 Author: A U Thor <author@example.com> 4 files changed, 5 insertions(+) create mode 100644 test.r create mode 100644 test2.r create mode 100644 test4-empty.r create mode 100644 testsubdir/test3 'sq',$x=.r sort: cannot read: rot13-filter.log: No such file or directory --- expected.log 2016-12-16 20:14:29.037426091 +0000 +++ rot13-filter.log 2016-12-16 20:14:29.041426091 +0000 @@ -1,7 +0,0 @@ -x IN: clean test.r 57 [OK] -- OUT: 57 . [OK] -x IN: clean test2.r 14 [OK] -- OUT: 14 . [OK] -x IN: clean test4-empty.r 0 [OK] -- OUT: 0 [OK] -x IN: clean testsubdir/test3 'sq',$x=.r 49 [OK] -- OUT: 49 . [OK] - 1 START - 1 STOP - 1 init handshake complete not ok 15 - required process filter should filter data # # test_config_global filter.protocol.process "rot13-filter.pl clean smudge" && # test_config_global filter.protocol.required true && # rm -rf repo && # mkdir repo && # ( # cd repo && # git init && # # echo "*.r filter=protocol" >.gitattributes && # git add . && # git commit -m "test commit 1" && # git branch empty-branch && # # cp "$TEST_ROOT/test.o" test.r && # cp "$TEST_ROOT/test2.o" test2.r && # mkdir testsubdir && # cp "$TEST_ROOT/test3 'sq',\$x=.o" "testsubdir/test3 'sq',\$x=.r" && # >test4-empty.r && # # S=$(file_size test.r) && # S2=$(file_size test2.r) && # S3=$(file_size "testsubdir/test3 'sq',\$x=.r") && # # filter_git add . && # cat >expected.log <<-EOF && # START # init handshake complete # IN: clean test.r $S [OK] -- OUT: $S . [OK] # IN: clean test2.r $S2 [OK] -- OUT: $S2 . [OK] # IN: clean test4-empty.r 0 [OK] -- OUT: 0 [OK] # IN: clean testsubdir/test3 'sq',\$x=.r $S3 [OK] -- OUT: $S3 . [OK] # STOP # EOF # test_cmp_count expected.log rot13-filter.log && # # filter_git commit -m "test commit 2" && # cat >expected.log <<-EOF && # START # init handshake complete # IN: clean test.r $S [OK] -- OUT: $S . [OK] # IN: clean test2.r $S2 [OK] -- OUT: $S2 . [OK] # IN: clean test4-empty.r 0 [OK] -- OUT: 0 [OK] # IN: clean testsubdir/test3 'sq',\$x=.r $S3 [OK] -- OUT: $S3 . [OK] # IN: clean test.r $S [OK] -- OUT: $S . [OK] # IN: clean test2.r $S2 [OK] -- OUT: $S2 . [OK] # IN: clean test4-empty.r 0 [OK] -- OUT: 0 [OK] # IN: clean testsubdir/test3 'sq',\$x=.r $S3 [OK] -- OUT: $S3 . [OK] # STOP # EOF # test_cmp_count expected.log rot13-filter.log && # # rm -f test2.r "testsubdir/test3 'sq',\$x=.r" && # # filter_git checkout --quiet --no-progress . && # cat >expected.log <<-EOF && # START # init handshake complete # IN: smudge test2.r $S2 [OK] -- OUT: $S2 . [OK] # IN: smudge testsubdir/test3 'sq',\$x=.r $S3 [OK] -- OUT: $S3 . [OK] # STOP # EOF # test_cmp_exclude_clean expected.log rot13-filter.log && # # filter_git checkout --quiet --no-progress empty-branch && # cat >expected.log <<-EOF && # START # init handshake complete # IN: clean test.r $S [OK] -- OUT: $S . [OK] # STOP # EOF # test_cmp_exclude_clean expected.log rot13-filter.log && # # filter_git checkout --quiet --no-progress master && # cat >expected.log <<-EOF && # START # init handshake complete # IN: smudge test.r $S [OK] -- OUT: $S . [OK] # IN: smudge test2.r $S2 [OK] -- OUT: $S2 . [OK] # IN: smudge test4-empty.r 0 [OK] -- OUT: 0 [OK] # IN: smudge testsubdir/test3 'sq',\$x=.r $S3 [OK] -- OUT: $S3 . [OK] # STOP # EOF # test_cmp_exclude_clean expected.log rot13-filter.log && # # test_cmp_committed_rot13 "$TEST_ROOT/test.o" test.r && # test_cmp_committed_rot13 "$TEST_ROOT/test2.o" test2.r && # test_cmp_committed_rot13 "$TEST_ROOT/test3 'sq',\$x=.o" "testsubdir/test3 'sq',\$x=.r" # ) # $ ^ permalink raw reply [flat|nested] 13+ messages in thread
* Re: test failure 2016-12-16 20:32 test failure Ramsay Jones @ 2016-12-17 14:28 ` Lars Schneider 2016-12-17 16:11 ` Lars Schneider 0 siblings, 1 reply; 13+ messages in thread From: Lars Schneider @ 2016-12-17 14:28 UTC (permalink / raw) To: Ramsay Jones, Jeff King; +Cc: Junio C Hamano, GIT Mailing-list > On 16 Dec 2016, at 21:32, Ramsay Jones <ramsay@ramsayjones.plus.com> wrote: > > Hi Lars, > > For the last two days, I've noticed t0021.15 on the 'pu' branch has been failing intermittently (well it fails with: 'make test >ptest-out', but > when run by hand, it fails only say 1-in-6, 1-in-18, etc.). > > [yes, it's a bit strange; this hasn't changed in a couple of weeks!] > > I don't have time to investigate further tonight and, since I had not > heard anyone else complain, I thought I should let you know. > > See below for the output from a failing run. [Note: this is on Linux > Mint 18, tonight's pu branch @7c7984401]. Thanks Ramsay! I was able to reproduce the problem with this test: test_expect_success 'ramsay-report' ' test_config_global filter.protocol.clean cat && git init && echo "*.r filter=protocol" >.gitattributes && echo "bla" >test.r && git add . && GIT_TRACE=1 git commit -m "test commit 2" > trace 2>&1 && grep "run_command" trace ' It looks like as if Git occasionally forgets to run the clean filter. I bisected the problem and I think the problem starts with "diff: do not reuse worktree files that need "clean" conversion" (06dec439a3) which definitively sounds related. Back in June I reported that Git invokes the clean process 4 times if a single file is added. Peff took a closer look and suggested the patch mentioned above to remove one unnecessary invocation. I re-read his comments and everything sounds still reasonable to me: http://public-inbox.org/git/1469134747-26785-1-git-send-email-larsxschneider@gmail.com/#t Does anyone have a clue what is going on? I keep digging... Thanks, Lars ^ permalink raw reply [flat|nested] 13+ messages in thread
* Re: test failure 2016-12-17 14:28 ` Lars Schneider @ 2016-12-17 16:11 ` Lars Schneider 0 siblings, 0 replies; 13+ messages in thread From: Lars Schneider @ 2016-12-17 16:11 UTC (permalink / raw) To: Ramsay Jones, Jeff King; +Cc: Junio C Hamano, GIT Mailing-list > On 17 Dec 2016, at 15:28, Lars Schneider <larsxschneider@gmail.com> wrote: > > >> On 16 Dec 2016, at 21:32, Ramsay Jones <ramsay@ramsayjones.plus.com> wrote: >> >> Hi Lars, >> >> For the last two days, I've noticed t0021.15 on the 'pu' branch has been failing intermittently (well it fails with: 'make test >ptest-out', but >> when run by hand, it fails only say 1-in-6, 1-in-18, etc.). >> >> [yes, it's a bit strange; this hasn't changed in a couple of weeks!] >> >> I don't have time to investigate further tonight and, since I had not >> heard anyone else complain, I thought I should let you know. >> >> See below for the output from a failing run. [Note: this is on Linux >> Mint 18, tonight's pu branch @7c7984401]. > > Thanks Ramsay! > > I was able to reproduce the problem with this test: > > test_expect_success 'ramsay-report' ' > test_config_global filter.protocol.clean cat && > git init && > echo "*.r filter=protocol" >.gitattributes && > echo "bla" >test.r && > git add . && > GIT_TRACE=1 git commit -m "test commit 2" > trace 2>&1 && > grep "run_command" trace > ' > > It looks like as if Git occasionally forgets to run the clean filter. > I bisected the problem and I think the problem starts with "diff: do not > reuse worktree files that need "clean" conversion" (06dec439a3) which > definitively sounds related. > > Back in June I reported that Git invokes the clean process 4 times if a > single file is added. Peff took a closer look and suggested the patch > mentioned above to remove one unnecessary invocation. I re-read his comments > and everything sounds still reasonable to me: > http://public-inbox.org/git/1469134747-26785-1-git-send-email-larsxschneider@gmail.com/#t > > Does anyone have a clue what is going on? > I keep digging... Ugh. I stopped coding, started cleaning the house, and it hit me: "git commit" shouldn't call the filter anyways. I suspect it is called in my tests because I add and commit the file to the index right after its creation. All this usually happens within 1 second and therefore Git cannot know if the file was modified between "add" and "commit". That's why it needs to run "clean" again. I will adjust the tests. Cheers, Lars ^ permalink raw reply [flat|nested] 13+ messages in thread
* Test failure
@ 2014-11-08 19:28 Michael Blume
2014-11-09 1:43 ` Jeff King
0 siblings, 1 reply; 13+ messages in thread
From: Michael Blume @ 2014-11-08 19:28 UTC (permalink / raw)
To: git
I'm on a macbook running a beta of Mac OS Yosemite 10.10.1. I've never
been able to get GETTEXT to work so I have
NO_GETTEXT=1
in my makefile, but other than that I'm using the master branch of the
official github mirror.
When I build and run tests I get
[11:17][michael.blume@tcc-michael-4:~/workspace/git/t(master)]$
./t1410-reflog.sh
ok 1 - setup
ok 2 - rewind
ok 3 - corrupt and check
ok 4 - reflog expire --dry-run should not touch reflog
ok 5 - reflog expire
ok 6 - prune and fsck
ok 7 - recover and check
ok 8 - delete
ok 9 - rewind2
ok 10 - --expire=never
ok 11 - gc.reflogexpire=never
ok 12 - gc.reflogexpire=false
ok 13 - checkout should not delete log for packed ref
not ok 14 - stale dirs do not cause d/f conflicts (reflogs on)
#
# test_when_finished "git branch -d a || git branch -d a/b" &&
#
# git branch a/b master &&
# echo "a/b@{0} branch: Created from master" >expect &&
# git log -g --format="%gd %gs" a/b >actual &&
# test_cmp expect actual &&
# git branch -d a/b &&
#
# # now logs/refs/heads/a is a stale directory, but
# # we should move it out of the way to create "a" reflog
# git branch a master &&
# echo "a@{0} branch: Created from master" >expect &&
# git log -g --format="%gd %gs" a >actual &&
# test_cmp expect actual
#
not ok 15 - stale dirs do not cause d/f conflicts (reflogs off)
#
# test_when_finished "git branch -d a || git branch -d a/b" &&
#
# git branch a/b master &&
# echo "a/b@{0} branch: Created from master" >expect &&
# git log -g --format="%gd %gs" a/b >actual &&
# test_cmp expect actual &&
# git branch -d a/b &&
#
# # same as before, but we only create a reflog for "a" if
# # it already exists, which it does not
# git -c core.logallrefupdates=false branch a master &&
# : >expect &&
# git log -g --format="%gd %gs" a >actual &&
# test_cmp expect actual
#
# failed 2 among 15 test(s)
(I get the same thing with 'make test' but this is me just running the
problematic test)
A quick search seems to indicate the test is pretty new?
http://www.mail-archive.com/git@vger.kernel.org/msg60495.html
Test passes in my ubuntu vm.
^ permalink raw reply [flat|nested] 13+ messages in thread* Re: Test failure 2014-11-08 19:28 Test failure Michael Blume @ 2014-11-09 1:43 ` Jeff King 2014-11-09 5:44 ` Michael Blume 0 siblings, 1 reply; 13+ messages in thread From: Jeff King @ 2014-11-09 1:43 UTC (permalink / raw) To: Michael Blume; +Cc: git On Sat, Nov 08, 2014 at 11:28:32AM -0800, Michael Blume wrote: > When I build and run tests I get > > [11:17][michael.blume@tcc-michael-4:~/workspace/git/t(master)]$ > ./t1410-reflog.sh What does "./t1410-reflog.sh -v -i" report? > A quick search seems to indicate the test is pretty new? > http://www.mail-archive.com/git@vger.kernel.org/msg60495.html Yes, it is new. In these cases there's often some silly little platform incompatibility in the test script, but I don't see one. So maybe the incompatibility is in the code itself; I'm wondering if OS X returns something besides EISDIR when trying to open a directory. Unfortunately I don't have an OS X install handy to test on. -Peff ^ permalink raw reply [flat|nested] 13+ messages in thread
* Re: Test failure 2014-11-09 1:43 ` Jeff King @ 2014-11-09 5:44 ` Michael Blume 0 siblings, 0 replies; 13+ messages in thread From: Michael Blume @ 2014-11-09 5:44 UTC (permalink / raw) To: Jeff King; +Cc: git $ ./t1410-reflog.sh -v -i Initialized empty Git repository in /Users/michael.blume/workspace/git/t/trash directory.t1410-reflog/.git/ expecting success: mkdir -p A/B && echo rat >C && echo ox >A/D && echo tiger >A/B/E && git add . && test_tick && git commit -m rabbit && H=`git rev-parse --verify HEAD` && A=`git rev-parse --verify HEAD:A` && B=`git rev-parse --verify HEAD:A/B` && C=`git rev-parse --verify HEAD:C` && D=`git rev-parse --verify HEAD:A/D` && E=`git rev-parse --verify HEAD:A/B/E` && check_fsck && test_chmod +x C && git add C && test_tick && git commit -m dragon && L=`git rev-parse --verify HEAD` && check_fsck && rm -f C A/B/E && echo snake >F && echo horse >A/G && git add F A/G && test_tick && git commit -a -m sheep && F=`git rev-parse --verify HEAD:F` && G=`git rev-parse --verify HEAD:A/G` && I=`git rev-parse --verify HEAD:A` && J=`git rev-parse --verify HEAD` && check_fsck && rm -f A/G && test_tick && git commit -a -m monkey && K=`git rev-parse --verify HEAD` && check_fsck && check_have A B C D E F G H I J K L && git prune && check_have A B C D E F G H I J K L && check_fsck && test_line_count = 4 .git/logs/refs/heads/master [master (root-commit) 07fcc4f] rabbit Author: A U Thor <author@example.com> 3 files changed, 3 insertions(+) create mode 100644 A/B/E create mode 100644 A/D create mode 100644 C Checking object directories: 100% (256/256), done. [master 7d1a0b8] dragon Author: A U Thor <author@example.com> 1 file changed, 0 insertions(+), 0 deletions(-) mode change 100644 => 100755 C Checking object directories: 100% (256/256), done. [master 15ab5f0] sheep Author: A U Thor <author@example.com> 4 files changed, 2 insertions(+), 2 deletions(-) delete mode 100644 A/B/E create mode 100644 A/G delete mode 100755 C create mode 100644 F Checking object directories: 100% (256/256), done. [master 3ac530f] monkey Author: A U Thor <author@example.com> 1 file changed, 1 deletion(-) delete mode 100644 A/G Checking object directories: 100% (256/256), done. tree tree blob blob blob blob blob commit tree commit commit commit tree tree blob blob blob blob blob commit tree commit commit commit Checking object directories: 100% (256/256), done. ok 1 - setup expecting success: test_tick && git reset --hard HEAD~2 && test -f C && test -f A/B/E && ! test -f F && ! test -f A/G && check_have A B C D E F G H I J K L && git prune && check_have A B C D E F G H I J K L && test_line_count = 5 .git/logs/refs/heads/master HEAD is now at 7d1a0b8 dragon tree tree blob blob blob blob blob commit tree commit commit commit tree tree blob blob blob blob blob commit tree commit commit commit ok 2 - rewind expecting success: corrupt $F && check_fsck "missing blob $F" Checking object directories: 100% (256/256), done. missing blob 9ae84adb2704cbd49549e52169b4043871e13432 ok 3 - corrupt and check expecting success: git reflog expire --dry-run \ --expire=$(($test_tick - 10000)) \ --expire-unreachable=$(($test_tick - 10000)) \ --stale-fix \ --all && test_line_count = 5 .git/logs/refs/heads/master && check_fsck "missing blob $F" would prune commit: sheep would prune commit: monkey would prune reset: moving to HEAD~2 would prune commit: sheep would prune commit: monkey would prune reset: moving to HEAD~2 Checking object directories: 100% (256/256), done. missing blob 9ae84adb2704cbd49549e52169b4043871e13432 ok 4 - reflog expire --dry-run should not touch reflog expecting success: git reflog expire --verbose \ --expire=$(($test_tick - 10000)) \ --expire-unreachable=$(($test_tick - 10000)) \ --stale-fix \ --all && test_line_count = 2 .git/logs/refs/heads/master && check_fsck "dangling commit $K" Marking reachable objects... keep commit (initial): rabbit keep commit: dragon prune commit: sheep prune commit: monkey prune reset: moving to HEAD~2 keep commit (initial): rabbit keep commit: dragon prune commit: sheep prune commit: monkey prune reset: moving to HEAD~2 Checking object directories: 100% (256/256), done. dangling commit 3ac530f2f6c3a45206a6b2d455baf89d1c8f672d ok 5 - reflog expire expecting success: git prune && check_fsck && check_have A B C D E H L && check_dont_have F G I J K Checking object directories: 100% (256/256), done. tree tree blob blob blob commit commit fatal: git cat-file 9ae84adb2704cbd49549e52169b4043871e13432: bad file fatal: git cat-file 41ca11d3340423c1922fe4110d2327bda0891b45: bad file fatal: git cat-file 1fe0f573dce6e694ce16e98a936c65db295d1948: bad file fatal: git cat-file 15ab5f0ad4d9117a7cdcbea9673ec0fff6ca8e55: bad file fatal: git cat-file 3ac530f2f6c3a45206a6b2d455baf89d1c8f672d: bad file ok 6 - prune and fsck expecting success: recover $F && check_fsck "dangling blob $F" Checking object directories: 100% (256/256), done. dangling blob 9ae84adb2704cbd49549e52169b4043871e13432 ok 7 - recover and check expecting success: echo 1 > C && test_tick && git commit -m rat C && echo 2 > C && test_tick && git commit -m ox C && echo 3 > C && test_tick && git commit -m tiger C && HEAD_entry_count=$(git reflog | wc -l) && master_entry_count=$(git reflog show master | wc -l) && test $HEAD_entry_count = 5 && test $master_entry_count = 5 && git reflog delete master@{1} && git reflog show master > output && test $(($master_entry_count - 1)) = $(wc -l < output) && test $HEAD_entry_count = $(git reflog | wc -l) && ! grep ox < output && master_entry_count=$(wc -l < output) && git reflog delete HEAD@{1} && test $(($HEAD_entry_count -1)) = $(git reflog | wc -l) && test $master_entry_count = $(git reflog show master | wc -l) && HEAD_entry_count=$(git reflog | wc -l) && git reflog delete master@{07.04.2005.15:15:00.-0700} && git reflog show master > output && test $(($master_entry_count - 1)) = $(wc -l < output) && ! grep dragon < output [master b60a214] rat Author: A U Thor <author@example.com> 1 file changed, 1 insertion(+), 1 deletion(-) [master 9908ef9] ox Author: A U Thor <author@example.com> 1 file changed, 1 insertion(+), 1 deletion(-) [master b93561f] tiger Author: A U Thor <author@example.com> 1 file changed, 1 insertion(+), 1 deletion(-) ok 8 - delete expecting success: test_tick && git reset --hard HEAD~2 && test_line_count = 4 .git/logs/refs/heads/master HEAD is now at b60a214 rat ok 9 - rewind2 expecting success: git reflog expire --verbose \ --expire=never \ --expire-unreachable=never \ --all && test_line_count = 4 .git/logs/refs/heads/master keep commit (initial): rabbit keep commit: dragon keep commit: rat keep commit: tiger keep reset: moving to HEAD~2 keep commit (initial): rabbit keep commit: rat keep commit: tiger keep reset: moving to HEAD~2 ok 10 - --expire=never expecting success: git config gc.reflogexpire never && git config gc.reflogexpireunreachable never && git reflog expire --verbose --all && test_line_count = 4 .git/logs/refs/heads/master keep commit (initial): rabbit keep commit: dragon keep commit: rat keep commit: tiger keep reset: moving to HEAD~2 keep commit (initial): rabbit keep commit: rat keep commit: tiger keep reset: moving to HEAD~2 ok 11 - gc.reflogexpire=never expecting success: git config gc.reflogexpire false && git config gc.reflogexpireunreachable false && git reflog expire --verbose --all && test_line_count = 4 .git/logs/refs/heads/master && git config --unset gc.reflogexpire && git config --unset gc.reflogexpireunreachable keep commit (initial): rabbit keep commit: dragon keep commit: rat keep commit: tiger keep reset: moving to HEAD~2 keep commit (initial): rabbit keep commit: rat keep commit: tiger keep reset: moving to HEAD~2 ok 12 - gc.reflogexpire=false expecting success: test $(git reflog master | wc -l) = 4 && git branch foo && git pack-refs --all && git checkout foo && test $(git reflog master | wc -l) = 4 Switched to branch 'foo' ok 13 - checkout should not delete log for packed ref expecting success: test_when_finished "git branch -d a || git branch -d a/b" && git branch a/b master && echo "a/b@{0} branch: Created from master" >expect && git log -g --format="%gd %gs" a/b >actual && test_cmp expect actual && git branch -d a/b && # now logs/refs/heads/a is a stale directory, but # we should move it out of the way to create "a" reflog git branch a master && echo "a@{0} branch: Created from master" >expect && git log -g --format="%gd %gs" a >actual && test_cmp expect actual fatal: ambiguous argument 'a/b': both revision and filename Use '--' to separate paths from revisions, like this: 'git <command> [<revision>...] -- [<file>...]' not ok 14 - stale dirs do not cause d/f conflicts (reflogs on) # # test_when_finished "git branch -d a || git branch -d a/b" && # # git branch a/b master && # echo "a/b@{0} branch: Created from master" >expect && # git log -g --format="%gd %gs" a/b >actual && # test_cmp expect actual && # git branch -d a/b && # # # now logs/refs/heads/a is a stale directory, but # # we should move it out of the way to create "a" reflog # git branch a master && # echo "a@{0} branch: Created from master" >expect && # git log -g --format="%gd %gs" a >actual && # test_cmp expect actual # On Sat, Nov 8, 2014 at 5:43 PM, Jeff King <peff@peff.net> wrote: > On Sat, Nov 08, 2014 at 11:28:32AM -0800, Michael Blume wrote: > >> When I build and run tests I get >> >> [11:17][michael.blume@tcc-michael-4:~/workspace/git/t(master)]$ >> ./t1410-reflog.sh > > What does "./t1410-reflog.sh -v -i" report? > >> A quick search seems to indicate the test is pretty new? >> http://www.mail-archive.com/git@vger.kernel.org/msg60495.html > > Yes, it is new. In these cases there's often some silly little > platform incompatibility in the test script, but I don't see one. So > maybe the incompatibility is in the code itself; I'm wondering if > OS X returns something besides EISDIR when trying to open a directory. > > Unfortunately I don't have an OS X install handy to test on. > > -Peff ^ permalink raw reply [flat|nested] 13+ messages in thread
end of thread, other threads:[~2017-09-04 5:32 UTC | newest] Thread overview: 13+ messages (download: mbox.gz follow: Atom feed -- links below jump to the message on this page -- 2017-09-01 3:34 Test failure Ian Zimmerman 2017-09-01 5:09 ` David Gibson 2017-09-01 16:30 ` Ian Zimmerman 2017-09-02 3:50 ` Rusty Russell 2017-09-02 8:00 ` Ian Zimmerman 2017-09-04 0:51 ` Rusty Russell 2017-09-04 5:32 ` Ian Zimmerman -- strict thread matches above, loose matches on Subject: below -- 2016-12-16 20:32 test failure Ramsay Jones 2016-12-17 14:28 ` Lars Schneider 2016-12-17 16:11 ` Lars Schneider 2014-11-08 19:28 Test failure Michael Blume 2014-11-09 1:43 ` Jeff King 2014-11-09 5:44 ` Michael Blume
This is an external index of several public inboxes, see mirroring instructions on how to clone and mirror all data and code used by this external index.