Issue 1046 Surprising behaviour: darcs rec /silly ↦ darcs rec

Title Surprising behaviour: darcs rec /silly ↦ darcs rec
Priority bug Status resolved
Milestone Resolved in
Superseder Nosy List darcs-devel, dmitry.kurochkin, jaredj, kowey, submit, thorkilnaur, twb
Assigned To
Topics ProbablyEasy, UI

Created on 2008-08-30.05:37:38 by twb, last changed 2009-08-27.14:19:04 by admin.

msg5803 (view) Author: twb Date: 2008-08-30.05:37:35
Package: darcs
Version: 2.0.2-2
Severity: minor
Tags: upstream

While in a repo, I accidentally ran "darcs rec ~/foo" instead of
"darcs rec ./foo".  This resulted in the error:

    Ignoring non-repository paths: /home/twb/foo

which I expected.  What surprised me is that darcs went on to ask me
about all unrecorded changes -- as if I'd run "darcs rec".  I expected
it to simply return immediately, because none of the files listed on
the command line had unrecorded changes.

That is, I expected it to behave similarly to this:

   $ darcs rec ~/foo bar
   Ignoring non-repository paths: /home/twb/foo
   Recording changes in "bar":

   Ok, if you don't want to record anything, that's fine!

-- System Information:
Debian Release: lenny/sid
  APT prefers testing
  APT policy: (990, 'testing')
Architecture: i386 (i686)

Kernel: Linux 2.6.25-2-686 (SMP w/1 CPU core)
Locale: LANG=en_AU.utf8, LC_CTYPE=en_AU.utf8 (charmap=UTF-8)
Shell: /bin/sh linked to /bin/dash

Versions of packages darcs depends on:
ii  libc6                  2.7-13            GNU C Library: Shared libraries
ii  libcurl3               7.18.2-5          Multi-protocol file transfer libra
ii  libgmp3c2              2:4.2.2+dfsg-3    Multiprecision arithmetic library
ii  libncurses5            5.6+20080804-1    shared libraries for terminal hand
ii  zlib1g                 1: compression library - runtime

Versions of packages darcs recommends:
ii  msmtp-mta [mail-transport-age 1.4.15-1   light SMTP client with support for

Versions of packages darcs suggests:
pn  darcs-server                  <none>     (no description available)

-- no debconf information
msg5805 (view) Author: kowey Date: 2008-08-30.07:25:16
This is a fairly easy bug to fix.

Darcs filters out unsuitable paths, but I suppose what happens is that it
subsequently forgets that you had tried to pass paths in in the first place.  It
should be possible to fix this just by looking at src/Darcs/Commands/Record.lhs
msg6463 (view) Author: simon Date: 2008-10-26.07:38:00
The patch just sent to list checks for this:

$ darcs rec ~
Ignoring non-repository paths: /Users/simon
Non existent files or directories: "/Users/simon"

darcs failed:  None of the files you specified exist!
msg6465 (view) Author: kowey Date: 2008-10-26.07:48:40
Cool! Fwiw, no need to manually resolve bugs if you are using the fancy 'resolve
issue1046' syntax. (also setting back to in-progress until the patch is actually
applied, in which case it really will be resolved-in-something ;-) )
msg6466 (view) Author: simon Date: 2008-10-26.07:49:46
Oh good point, thanks.
msg6490 (view) Author: simon Date: 2008-10-28.02:39:23
The following patch updated the status of issue1046 to be resolved:

* resolve issue1046: record nothing when only a non-repo file is specified 
Ignore-this: efa65ddd1adaa6a8ef4a1c390e70e408
Date User Action Args
2008-08-30 05:37:38twbcreate
2008-08-30 07:25:21koweysetpriority: bug
status: unread -> needs-reproduction
topic: + ProbablyEasy, UI
messages: + msg5805
nosy: + jaredj
2008-10-26 07:38:08simonsetstatus: needs-reproduction -> resolved
nosy: + dmitry.kurochkin, simon, thorkilnaur
messages: + msg6463
2008-10-26 07:48:45koweysetstatus: resolved -> has-patch
nosy: kowey, dagit, simon, twb, thorkilnaur, submit, jaredj, dmitry.kurochkin
messages: + msg6465
2008-10-26 07:49:48simonsetnosy: kowey, dagit, simon, twb, thorkilnaur, submit, jaredj, dmitry.kurochkin
messages: + msg6466
2008-10-28 02:39:26simonsetstatus: has-patch -> resolved-in-unstable
nosy: kowey, dagit, simon, twb, thorkilnaur, submit, jaredj, dmitry.kurochkin
messages: + msg6490
2009-04-22 03:34:27twbsetstatus: resolved-in-unstable -> resolved
nosy: kowey, dagit, simon, twb, thorkilnaur, submit, jaredj, dmitry.kurochkin
2009-08-10 23:44:24adminsetnosy: - dagit
2009-08-25 17:32:35adminsetnosy: + darcs-devel, - simon
2009-08-27 14:19:04adminsetnosy: kowey, darcs-devel, twb, thorkilnaur, submit, jaredj, dmitry.kurochkin