darcs

Issue 467 darcs changes --context interferes with --repodir

Title darcs changes --context interferes with --repodir
Priority bug Status resolved
Milestone Resolved in
Superseder Nosy List Aaron, beschmi, darcs-devel, dmitry.kurochkin, kowey, thorkilnaur, tommy
Assigned To kowey
Topics ProbablyEasy

Created on 2007-05-26.13:21:14 by lists2546, last changed 2009-10-24.09:08:42 by admin.

Messages
msg1708 (view) Author: Aaron Date: 2007-05-26.13:21:07
With darcs 1.0.8, darcs changes --repodir foo works, but darcs changes
--repodir foo --context claims that it can't find the inventory file.

I apoligize if this is a duplicate.  I reported it once before, but as
far as I can see it never showed up in the tracker.

-Aaron
msg1838 (view) Author: kowey Date: 2007-07-16.09:35:04
Hi, I can't reproduce this with 1.0.8.  Can you cook up a minimal test case, please?
msg1959 (view) Author: thorkilnaur Date: 2007-08-01.08:44:29
Here is an example of this behaviour:

$ darcs --exact-version
darcs compiled on May  8 2007, at 09:50:57
# configured Fri Jun 16 14:55:21 EDT 2006
./configure --no-create --no-recursion

Context:

[TAG 1.0.8
Tommy Pettersson <ptp@lysator.liu.se>**20060616160213] 
$ uname -a
Darwin Thorkil-Naurs-Computer.local 8.9.0 Darwin Kernel Version 8.9.0: Thu Feb 
22 20:54:07 PST 2007; root:xnu-792.17.14~1/RELEASE_PPC Power Macintosh powerpc
$ mkdir Issue467Repo1
$ cd Issue467Repo1
$ darcs initialize
$ echo This is file1.txt >file1.txt
$ darcs add file1.txt
$ darcs record -a --author=Thorkil --patch-name=file1.txt
Finished recording patch 'file1.txt'
$ darcs changes --context

Context:

[file1.txt
Thorkil**20070801084349] 
$ darcs changes --context --repodir=.

Context:

[file1.txt
Thorkil**20070801084349] 
$ cd .. 
$ darcs changes --context --repodir=Issue467Repo1

darcs failed:  Not a repository: Issue467Repo1 (Issue467Repo1/_darcs/inventory: 
openBinaryFile: does not exist (No such file or directory))
$ ls -R Issue467Repo1
_darcs          file1.txt

Issue467Repo1/_darcs:
inventories     inventory       patches         prefs           pristine

Issue467Repo1/_darcs/inventories:

Issue467Repo1/_darcs/patches:
20070801084349-c19ed-b92a993114182b2a6be420c023d464d5939cd12d.gz        pending

Issue467Repo1/_darcs/prefs:
binaries        boring          motd

Issue467Repo1/_darcs/pristine:
file1.txt
$ 

Best regards
Thorkil
msg1960 (view) Author: kowey Date: 2007-08-01.09:02:44
Wow, that's pretty weird.  I can confirm also that just --repodir=Issue467Repo1
does work, but adding --context makes it not understand what's going on.  Would
be worth seeing how it behaves in later darcs, though I suspect there won't be
any improvement.

Thanks for the test case!  You might even consider submitting it as a patch to
our test suite if you're feeling extra-helpful.
msg1961 (view) Author: thorkilnaur Date: 2007-08-01.09:13:56
It also fails with darcs 1.0.9 on a SuSE Linux:

$ darcs --exact-version
darcs compiled on Jun 13 2007, at 21:47:50
# configured Sun Jun  3 18:53:47 EDT 2007
./configure

Context:

[TAG 1.0.9
Tommy Pettersson <ptp@lysator.liu.se>**20070603213706]
$ uname -a
Linux linux 2.6.13-15-default #1 Tue Sep 13 14:56:15 UTC 2005 i686 i686 i386 
GNU/Linux
$ mkdir Issue467Repo1
$ cd Issue467Repo1
$ darcs initialize
$ echo This is file1.txt >file1.txt
$ darcs add file1.txt
$ darcs record -a --author=Thorkil --patch-name=file1.txt
Finished recording patch 'file1.txt'
$ darcs changes --context

Context:

[file1.txt
Thorkil**20070801091041]
$ darcs changes --context --repodir=.

Context:

[file1.txt
Thorkil**20070801091041]
$ cd ..
$ darcs changes --context --repodir=Issue467Repo1

darcs failed:  Not a repository: Issue467Repo1 (Issue467Repo1/_darcs/inventory: 
openBinaryFile: does not exist (No such file or directory))
$ ls -R Issue467Repo1
Issue467Repo1:
_darcs  file1.txt

Issue467Repo1/_darcs:
inventories  inventory  patches  prefs  pristine

Issue467Repo1/_darcs/inventories:

Issue467Repo1/_darcs/patches:
20070801091041-c19ed-f3a7d3d4c5d6776ecbd7e10534c8a80ead82c604.gz  pending

Issue467Repo1/_darcs/prefs:
binaries  boring  motd

Issue467Repo1/_darcs/pristine:
file1.txt
$

Best regards
Thorkil
msg1964 (view) Author: droundy Date: 2007-08-01.17:33:06
I noticed (in trying to reproduce this) that it only causes trouble when
the --repodir argument is a relative path.  When given an absolute path,
--context and --repodir work together fine.
-- 
David Roundy
Department of Physics
Oregon State University
msg1966 (view) Author: kowey Date: 2007-08-01.18:43:19
I think these should do it... (see darcs-devel)

Wed Aug  1 20:40:51 CEST 2007  Eric Kow <eric.kow@gmail.com>
  * [issue467] changes --context --repodir

Wed Aug  1 20:41:38 CEST 2007  Eric Kow <eric.kow@gmail.com>
  * Add test for issue467.
History
Date User Action Args
2007-05-26 13:21:14lists2546create
2007-07-16 09:35:09koweysetstatus: unread -> waiting-for
nosy: droundy, tommy, beschmi, kowey, lists2546
messages: + msg1838
2007-08-01 08:44:32thorkilnaursetnosy: + thorkilnaur
messages: + msg1959
2007-08-01 09:02:46koweysetstatus: waiting-for -> unknown
messages: + msg1960
title: darcs changes --context interferes with --repodir -> darcs changes --context interferes with --repodir (1.0.8)
2007-08-01 09:09:56koweysettopic: + ProbablyEasy
2007-08-01 09:14:01thorkilnaursetmessages: + msg1961
2007-08-01 09:15:35koweysettitle: darcs changes --context interferes with --repodir (1.0.8) -> darcs changes --context interferes with --repodir (1.0.9)
2007-08-01 17:33:08droundysetmessages: + msg1964
title: darcs changes --context interferes with --repodir (1.0.9) -> darcs changes --context interferes with --repodir
2007-08-01 18:43:20koweysetstatus: unknown -> testing
messages: + msg1966
2007-08-05 21:01:41koweysetstatus: testing -> resolved-in-unstable
2007-08-09 12:04:56koweysetstatus: resolved-in-unstable -> resolved-in-stable
2008-09-16 21:31:04adminsetstatus: resolved-in-stable -> resolved
nosy: + dagit
2009-08-06 17:47:35adminsetnosy: + markstos, jast, Serware, dmitry.kurochkin, darcs-devel, zooko, mornfall, simon, - droundy, lists2546
2009-08-10 22:04:40adminsetnosy: + lists2546, - markstos, darcs-devel, zooko, jast, Serware, mornfall
2009-08-11 00:00:51adminsetnosy: - dagit
2009-08-25 17:59:19adminsetnosy: + darcs-devel, - simon
2009-08-27 14:11:48adminsetnosy: tommy, beschmi, kowey, darcs-devel, lists2546, thorkilnaur, dmitry.kurochkin
2009-10-24 09:08:42adminsetnosy: + Aaron, - lists2546