|
From: | Graydon Hoare |
Subject: | [Monotone-devel] Re: fatal: std::logic_error: ../roster.cc:800: invariant 'I(has_root())' violated |
Date: | Wed, 03 May 2006 15:30:41 -0700 |
User-agent: | Thunderbird 1.5.0.2 (Windows/20060308) |
Nathaniel Smith wrote:
Why _don't_ we create the root dir at setup-time? Graydon, do you remember? (I know this came up at some point, but I don't remember what was said. Maybe just "oh well, we already wrote it the other way, why bother switching"?)
I don't recall, but I can imagine some objections to what you specifically describe: "creating one at setup time". Consider the two options:
1. Write an _MTN/work file containing the setup. - If the user reverts, you lose. - If the user tries to update to a branch, you get a root conflict. 2. Write a revision and commit it. - The user has to have a pubkey. - User has to choose a branch name when setting up. - Same problem with update conflicts, as above.You could, however, modify the code path which calculates the workspace roster such that when it sees a workspace with no parent rev and no root, it returns a new roster with a fresh tempnode root (in memory).
-graydon
[Prev in Thread] | Current Thread | [Next in Thread] |