Created on 2008-10-05.09:36:36 by gwright, last changed 2009-08-27.14:17:32 by admin.
msg6228 (view) |
Author: gwright |
Date: 2008-10-05.09:36:30 |
|
I've had a test failure of 2.1.0pre3. Darcs is built using ghc 6.8.3
from MacPorts.
redwing-dakota> sudo make check
rm -f Main.hi Main.o
[ghc] stringify
test -f src/Context.hs || echo unknown | ./stringify Context context >
src/Context.hs
[ghc] src/ThisVersion.o
[ghc] src/Autoconf.o
[ghc] src/Context.o
[ghc] src/Workaround.o
[ghc] src/CommandLine.o
[ghc] src/FastPackedString.o
[ghc] src/Printer.o
[ghc] src/Darcs/Bug.o
[ghc] src/Darcs/Global.o
[ghc] src/HTTP.o
[ghc] src/Darcs/SignalHandler.o
[ghc] src/Darcs/Show.o
[ghc] src/Darcs/Sealed.o
[ghc] src/Darcs/Ordered.o
[ghc] src/Darcs/Progress.o
[ghc] src/Exec.o
[ghc] src/UTF8.o
[ghc] src/Darcs/Patch/FileName.o
[ghc] src/UglyFileName.o
[ghc] src/Darcs/URL.o
[ghc] src/Darcs/RepoPath.o
[ghc] src/Darcs/Utils.o
[ghc] src/Darcs/Compat.o
[ghc] src/Darcs/Lock.o
[ghc] src/URL.o
[ghc] src/IsoDate.o
[ghc] src/DateMatcher.o
[ghc] src/English.o
[ghc] src/Lcs.o
[ghc] src/OldDate.o
[ghc] src/OldFastPackedString.o
[ghc] src/RegChars.o
[ghc] src/SHA1.o
[ghc] src/Ssh.o
[ghc] src/Crypt/SHA256.o
[ghc] src/Darcs/Patch/MatchData.o
[ghc] src/Darcs/Flags.o
[ghc] src/Darcs/External.o
[ghc] src/Darcs/IO.o
[ghc] src/Darcs/CheckFileSystem.o
[ghc] src/Darcs/SlurpDirectory.o
[ghc] src/Darcs/Repository/Cache.o
[ghc] src/Darcs/Repository/Prefs.o
[ghc] src/Darcs/Patch/Info.o
[ghc] src/Darcs/Patch/ReadMonads.o
[ghc] src/Darcs/Patch/Patchy.o
[ghc] src/Darcs/Patch/Permutations.o
[ghc] src/Darcs/Patch/Prim.o
[ghc] src/Darcs/ColorPrinter.o
[ghc] src/Darcs/FilePathMonad.o
[ghc] src/Darcs/Patch/Core.o
[ghc] src/Darcs/Patch/Show.o
[ghc] src/Darcs/Patch/Commute.o
[ghc] src/Darcs/PopulationData.o
[ghc] src/Darcs/Patch/Apply.o
[ghc] src/Darcs/Patch/Viewing.o
[ghc] src/Darcs/Patch/Read.o
[ghc] src/Darcs/Patch/Non.o
[ghc] src/Darcs/Patch/Real.o
[ghc] src/Darcs/Patch.o
[ghc] src/Darcs/Hopefully.o
[ghc] src/Darcs/Patch/Set.o
[ghc] src/Darcs/Patch/Depends.o
[ghc] src/Darcs/Repository/Format.o
[ghc] src/Darcs/Repository/InternalTypes.o
[ghc] src/Darcs/Repository/HashedIO.o
[ghc] src/Darcs/FilePathUtils.o
[ghc] src/Darcs/Repository/HashedRepo.o
[ghc] src/Darcs/Diff.o
[ghc] src/Darcs/Repository/Pristine.o
[ghc] src/Darcs/Repository/ApplyPatches.o
[ghc] src/Darcs/Repository/DarcsRepo.o
[ghc] src/Darcs/Patch/Bundle.o
[ghc] src/Darcs/Resolution.o
[ghc] src/Darcs/Repository/Internal.o
[ghc] src/Darcs/Repository/Checkpoint.o
[ghc] src/Darcs/Repository.o
[ghc] src/Darcs/Arguments.o
[ghc] src/Darcs/ArgumentDefaults.o
[ghc] src/Darcs/Patch/Match.o
[ghc] src/Darcs/Match.o
[ghc] src/Darcs/Test.o
[ghc] src/Darcs/Commands.o
[ghc] src/Darcs/CommandsAux.o
[ghc] src/Darcs/Email.o
[ghc] src/Darcs/Population.o
[ghc] src/Darcs/PrintPatch.o
[ghc] src/Darcs/RemoteApply.o
[ghc] src/Darcs/Patch/Choices.o
[ghc] src/Darcs/Patch/TouchesFiles.o
[ghc] src/Darcs/SelectChanges.o
[ghc] src/Darcs/Commands/WhatsNew.o
[ghc] src/Darcs/Commands/Unrevert.o
[ghc] src/Darcs/Commands/Unrecord.o
[ghc] src/Darcs/Commands/TransferMode.o
[ghc] src/Darcs/Commands/TrackDown.o
[ghc] src/Darcs/Commands/Record.o
[ghc] src/Darcs/Commands/Tag.o
[ghc] src/Darcs/Commands/SetPref.o
[ghc] src/Darcs/Commands/Send.o
[ghc] src/Darcs/Commands/Rollback.o
[ghc] src/Darcs/Commands/Revert.o
[ghc] src/Darcs/Commands/Replace.o
[ghc] src/Darcs/Commands/Check.o
[ghc] src/Darcs/Commands/Repair.o
[ghc] src/Darcs/Commands/Remove.o
[ghc] src/Darcs/Commands/Init.o
[ghc] src/Darcs/Commands/Put.o
[ghc] src/Darcs/Commands/Push.o
[ghc] src/Darcs/Repository/Motd.o
[ghc] src/Darcs/Commands/Pull.o
[ghc] src/Darcs/Commands/Optimize.o
[ghc] src/Darcs/Commands/Mv.o
[ghc] src/Darcs/Commands/MarkConflicts.o
[ghc] src/Darcs/Commands/ShowRepo.o
[ghc] src/Darcs/Commands/ShowTags.o
[ghc] src/Darcs/Commands/ShowFiles.o
[ghc] src/Darcs/Commands/ShowContents.o
[ghc] src/Darcs/Commands/ShowBug.o
[ghc] src/Darcs/Commands/ShowAuthors.o
[ghc] src/Darcs/Commands/Show.o
[ghc] src/Darcs/Commands/Get.o
[ghc] src/Darcs/Commands/Dist.o
[ghc] src/Darcs/Commands/Diff.o
[ghc] src/Darcs/Commands/Convert.o
[ghc] src/Darcs/Commands/Annotate.o
[ghc] src/Darcs/Commands/Changes.o
[ghc] src/Darcs/Commands/Apply.o
[ghc] src/Darcs/Commands/AmendRecord.o
[ghc] src/Darcs/Commands/Add.o
[ghc] src/Darcs/TheCommands.o
[ghc] src/Darcs/Commands/Help.o
[ghc] src/c_compat.o
[ghc] src/maybe_relink.o
[ghc] src/atomic_create.o
[ghc] src/fpstring.o
[ghc] src/umask.o
[ghc] src/Crypt/sha2.o
[ghc] src/hscurl.o
[ghc] src/hslibwww.o
Linking darcs ...
Running shell tests on old-fashioned repositories...
Running what_sl.sh ... passed.
Running unrevert_cancel.sh ... passed.
Running unrevert.sh ... passed.
Running unrevert-replace-moved.sh ... passed.
Running unrevert-add.sh ... passed.
Running unrecord.sh ... passed.
Running unrecord-setpref.sh ... passed.
Running unrecord-remove.sh ... passed.
Running unrecord-add.sh ... passed.
Running unpull.sh ... passed.
Running uniqueoptions.sh ... passed.
Running tricky_unrecord.sh ... passed.
Running three_way_conflict.sh ... passed.
Running steve_and_monica_rollback.sh ... passed.
Running ssh.sh ... passed.
Running sigPIPE.sh ... passed.
Running show_tags.sh ... passed.
Running show-bug.sh ... passed.
Running show-authors.sh ... passed.
Running several_commands.sh ... passed.
Running setpref.sh ... passed.
Running send_apply.sh ... passed.
Running send.sh ... passed.
Running sametwice.sh ... passed.
Running rollback.sh ... passed.
Running rollback-nothing.sh ... passed.
Running rmdir.sh ... passed.
Running rmconflict.sh ... passed.
Running revert_unrecorded_add.sh ... passed.
Running revert_interactive.sh ... passed.
Running repodir.sh ... passed.
Running replace_after_pending_mv.sh ... passed.
Running replace_after_pending_add.sh ... passed.
Running replace.sh ... passed.
Running repair.sh ... passed.
Running repair-clean.sh ... passed.
Running recordrace.sh ... passed.
Running query_manifest.sh ... passed.
Running push_lock.sh ... passed.
Running push.sh ... passed.
Running push-dry-run.sh ... passed.
Running pull_two.sh ... passed.
Running pull_compl.sh ... passed.
Running pull_binary.sh ... passed.
Running pull.sh ... FAILED!
Output from failed pull.sh:
## I would use the builtin !, but that has the wrong semantics.
not () { "$@" && exit 1 || :; }
# darcs does not support cygwin paths (/cygdrive/c/foo), so if
# we want to run the test suite under Cygwin Bash, we must
# convert accordingly
portable_pwd () {
if uname | grep -qi cygwin ; then
cygpath -w `pwd`
else
pwd
fi
}
rm -rf temp1 temp2
mkdir temp1
cd temp1
darcs init
cd ..
mkdir temp2
cd temp2
darcs init
mkdir one
cd one
mkdir two
cd two
echo darcs pull should work relative to the current directory
darcs pull should work relative to the current directory
darcs pull -a ../../../temp1 | grep -i 'No remote changes to pull in'
No remote changes to pull in!
echo -- darcs pull should pull into repo specified with --repo
-- darcs pull should pull into repo specified with --repo
cd ../.. # now in temp2
darcs add one;
darcs record --patch-name uno --all
Finished recording patch 'uno'
cd .. # now outside of any repo
darcs pull --repodir temp1 --all temp2 | grep -i 'Finished pulling.' #
temp2 is not relative to temp1
Finished pulling and applying.
# set up server repo
date > temp2/one/date.t
darcs add --repodir ./temp2 one/date.t
darcs record --repodir ./temp2 -a -m foo
Finished recording patch 'foo'
# set up client repo for failure
if echo $OS | grep -i windows; then
echo this test does not work on windows because it
echo is not possible to chmod -r
else
chmod a-rwx ./temp1/one # remove all permissions
not darcs pull --repodir ./temp1 -a 2> err
chmod u+rwx temp1/one # restore permission
cat err
rm -rf temp1/one
fi
Pulling from "/opt/local/var/macports/build/
_Users_gwright_src_macports-trunk_dports_devel_darcs/work/
darcs-2.1.0pre3/tests-shell-old-fashioned.dir/temp2"...
Finished pulling and applying.
Running pull-union.sh ... passed.
Running prehook.sh ... passed.
Running prefs.sh ... passed.
Running posthook.sh ... passed.
Running perms.sh ... passed.
Running pending_has_conflicts.sh ... passed.
Running pending.sh ... passed.
Running partial.sh ... passed.
Running output.sh ... passed.
Running optimize_relink.sh ... passed.
Running obliterate.sh ... passed.
Running obliterate-add.sh ... passed.
Running nonewline.sh ... passed.
Running nodeps.sh ... passed.
Running no_pristine.sh ... passed.
Running nfs-failure.sh ... passed.
Running mv_then_add.sh ... passed.
Running mv_and_remove_tests.sh ... passed.
Running mv.sh ... passed.
Running mv-test-suite.sh ... passed.
Running mv-formerly-pl.sh ... passed.
Running mergeresolved.sh ... passed.
Running merge_three_patches.sh ... passed.
Running mark-conflicts.sh ... passed.
Running look_for_add.sh ... passed.
Running justrm.sh ... passed.
Running issue966_diff.sh ... passed.
Running issue885_get_to_match.sh ... passed.
Running issue844_gzip_crc.sh ... passed.
Running issue803.sh ... passed.
Running issue709_pending_look-for-adds.sh ... passed.
Running issue706.sh ... passed.
Running issue691.sh ... passed.
Running issue588.sh ... passed.
Running issue538.sh ... passed.
Running issue53.sh ... passed.
Running issue458.sh ... passed.
Running issue436.sh ... passed.
Running issue381.sh ... passed.
Running issue257.sh ... passed.
Running issue194.sh ... passed.
Running issue1110_get_old-fashioned.sh ... passed.
Running issue1110_get_hashed.sh ... passed.
Running issue1078_symlink.sh ... passed.
Running issue1057.sh ... passed.
Running issue1043_geteff_a.sh ... passed.
Running issue1041.sh ... passed.
Running issue1039.sh ... passed.
Running issue1012_unrecord_remove.sh ... passed.
Running invalid_pending_after_mv_to_self.sh ... passed.
Running impossible_unrevert.sh ... passed.
Running illegal_mv.sh ... passed.
Running ignoretimes.sh ... passed.
Running hidden_conflict.sh ... passed.
Running haskell_policy.sh ... passed.
Running hashed_inventory.sh ... passed.
Running harness.sh ... passed.
Running get_tag.sh ... passed.
Running get.sh ... passed.
Running double-unrevert.sh ... passed.
Running directory_confusion.sh ... passed.
Running diff.sh ... passed.
Running conflict-fight.sh ... passed.
Running conflict-fight-failure.sh ... passed.
Running conflict-doppleganger.sh ... passed.
Running checkpoint.sh ... passed.
Running changes.sh ... passed.
Running binary.sh ... passed.
Running bad_pending_after_pull.sh ... passed.
Running bad-match-pattern.sh ... passed.
Running bad-format.sh ... passed.
Running ask_deps.sh ... passed.
Running apply-hunks.sh ... passed.
Running annotate.sh ... passed.
Running amend-cancelling.sh ... passed.
Running addrm.sh ... passed.
Running addrace.sh ... passed.
Running addmv.sh ... passed.
Running addexitval.sh ... passed.
Running add.sh ... passed.
TESTS FAILED!
pull.sh
make: *** [test_shell] Error 1
redwing-dakota>
If I go into the tests directory and simply try to run the failing
command
(using the temp1 and temp2 directories built in the "make check" run):
redwing-dakota> sudo darcs pull --repodir ./temp1 -a
Pulling from "/opt/local/var/macports/build/
_Users_gwright_src_macports-trunk_dports_devel_darcs/work/
darcs-2.1.0pre3/tests/temp2"...
No remote changes to pull in!
Hmmm... darcs seems to be trying to pull from the wrong repo directory
(temp2 instead of temp1).
If I change the command line to
redwing-dakota> sudo darcs pull --repodir ./temp2 -a
Pulling from "/opt/local/var/macports/build/
_Users_gwright_src_macports-trunk_dports_devel_darcs/work/
darcs-2.1.0pre3/tests/temp1"...
No remote changes to pull in!
then temp1 and temp2 are again reversed.
If I try to pull from an nonexistent directory, I get the expected
failure:
redwing-dakota> sudo darcs pull --repodir ./temp0 -a
darcs failed: can't set directory to ./temp0
New bug, old bug or PEBKAC?
Best Wishes,
Greg
Attachments
|
msg6232 (view) |
Author: kowey |
Date: 2008-10-05.23:14:11 |
|
Hi, and thanks!
On Sun, Oct 05, 2008 at 09:36:36 -0000, Gregory Wright wrote:
> else
> chmod a-rwx ./temp1/one # remove all permissions
> not darcs pull --repodir ./temp1 -a 2> err
> chmod u+rwx temp1/one # restore permission
> cat err
> rm -rf temp1/one
> fi
> Pulling from "/opt/local/var/macports/build/
> _Users_gwright_src_macports-trunk_dports_devel_darcs/work/
> darcs-2.1.0pre3/tests-shell-old-fashioned.dir/temp2"...
Hmm, a pull that succeeds when it shouldn't. For what it's worth, I'm
also on MacOS X and I'm not getting this :-/
> redwing-dakota> sudo darcs pull --repodir ./temp1 -a
> Pulling from "/opt/local/var/macports/build/
> _Users_gwright_src_macports-trunk_dports_devel_darcs/work/
> darcs-2.1.0pre3/tests/temp2"...
> No remote changes to pull in!
Hang on, that seems normal to me. pull --repodir temp1 is like
cd'ing into temp1 and then doing a pull from there (presumably
temp1 wants to pull from temp2)
> redwing-dakota> sudo darcs pull --repodir ./temp2 -a
> Pulling from "/opt/local/var/macports/build/
> _Users_gwright_src_macports-trunk_dports_devel_darcs/work/
> darcs-2.1.0pre3/tests/temp1"...
> No remote changes to pull in!
>
> then temp1 and temp2 are again reversed.
Again, same explanation.
> New bug, old bug or PEBKAC?
New bug, but only the test suite failure...
What steps can we take to reproduce this? Could have somebody else try
to build the port?
|
msg6235 (view) |
Author: thorkilnaur |
Date: 2008-10-06.08:33:29 |
|
Hello,
I can reproduce this on a PPC Mac OS X 10.5. Because of the "sudo", the "not
darcs" command in
> # set up client repo for failure
> if echo $OS | grep -i windows; then
> echo this test does not work on windows because it
> echo is not possible to chmod -r
> else
> chmod a-rwx ./temp1/one # remove all permissions
> not darcs pull --repodir ./temp1 -a 2> err
> chmod u+rwx temp1/one # restore permission
> cat err
> rm -rf temp1/one
> fi
> if echo $OS | grep -i windows; then
> echo this test does not work on windows, so ignore it
> else
> if whoami | grep root; then
> echo root never gets permission denied
> else
> grep 'permission denied' err
> fi
> fi
in pull.sh fails to fail and, hence, the test fails when executed with "sudo".
I have a fix for this. Is it true that I need to create a patch against the
stable darcs repository?
Thanks and best regards
Thorkil
|
msg6236 (view) |
Author: kowey |
Date: 2008-10-06.08:48:08 |
|
On Mon, Oct 06, 2008 at 10:30:33 +0200, Thorkil Naur wrote:
> I have a fix for this. Is it true that I need to create a patch against the
> stable darcs repository?
Yes, thanks!
|
msg6243 (view) |
Author: thorkilnaur |
Date: 2008-10-06.11:16:52 |
|
Hello,
the
> > stable darcs repository?
>
> Yes, thanks!
Here it is.
> ...
Best regards
Thorkil
Attachments
|
msg6522 (view) |
Author: thorkilnaur |
Date: 2008-10-29.18:25:00 |
|
Setting status resolved based on the following.
Best regards
Thorkil
hunk ./tests/pull.sh
> > 54
> > > > +elif whoami | grep root; then
> > > > + echo root never gets permission denied
> > > > hunk ./tests/pull.sh 61
> > > > + grep 'permission denied' err
> > > > hunk ./tests/pull.sh 64
> > > > -if echo $OS | grep -i windows; then
> > > > - echo this test does not work on windows, so ignore it
> > > > -else
> > > > - if whoami | grep root; then
> > > > - echo root never gets permission denied
> > > > - else
> > > > - grep 'permission denied' err
> > > > - fi
> > > > -fi
> > >
> > > It looks a lot like you're removing the windows case here. Why is
> > > that safe?
> >
> > The original pull.sh has
> >
> > > # set up client repo for failure
> > > if echo $OS | grep -i windows; then
> > > echo this test does not work on windows because it
> > > echo is not possible to chmod -r
> > > else
> > > chmod a-rwx ./temp1/one # remove all permissions
> > > not darcs pull --repodir ./temp1 -a 2> err
> > > chmod u+rwx temp1/one # restore permission
> > > cat err
> > > rm -rf temp1/one
> > > fi
> > > if echo $OS | grep -i windows; then
> > > echo this test does not work on windows, so ignore it
> > > else
> > > if whoami | grep root; then
> > > echo root never gets permission denied
> > > else
> > > grep 'permission denied' err
> > > fi
> > > fi
> >
> > so Windows is, needlessly I'd say, being checked for twice.
>
> Ah, thanks! I'll apply then.
>
> David
> _______________________________________________
> darcs-users mailing list
> darcs-users@darcs.net
> http://lists.osuosl.org/mailman/listinfo/darcs-users
>
|
|
Date |
User |
Action |
Args |
2008-10-05 09:36:36 | gwright | create | |
2008-10-05 23:14:14 | kowey | set | status: unread -> unknown nosy:
kowey, dagit, simon, thorkilnaur, dmitry.kurochkin, gwright messages:
+ msg6232 |
2008-10-06 08:33:31 | thorkilnaur | set | nosy:
kowey, dagit, simon, thorkilnaur, dmitry.kurochkin, gwright messages:
+ msg6235 |
2008-10-06 08:48:10 | kowey | set | nosy:
kowey, dagit, simon, thorkilnaur, dmitry.kurochkin, gwright messages:
+ msg6236 |
2008-10-06 11:16:54 | thorkilnaur | set | files:
+ fix-running-pull.sh-test-as-root.dpatch nosy:
kowey, dagit, simon, thorkilnaur, dmitry.kurochkin, gwright messages:
+ msg6243 |
2008-10-29 18:25:02 | thorkilnaur | set | status: unknown -> resolved nosy:
kowey, dagit, simon, thorkilnaur, dmitry.kurochkin, gwright messages:
+ msg6522 |
2009-04-22 02:48:24 | twb | set | priority: bug nosy:
kowey, dagit, simon, thorkilnaur, dmitry.kurochkin, gwright |
2009-08-10 23:47:29 | admin | set | nosy:
- dagit |
2009-08-25 17:30:16 | admin | set | nosy:
+ darcs-devel, - simon |
2009-08-27 14:17:32 | admin | set | nosy:
kowey, darcs-devel, thorkilnaur, dmitry.kurochkin, gwright |
|