You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@subversion.apache.org by "Daniel Shahaf (Jira)" <ji...@apache.org> on 2022/02/25 22:49:00 UTC

[jira] [Comment Edited] (SVN-4885) multi-wc-format: WC upgraded and not-upgraded notifications

    [ https://issues.apache.org/jira/browse/SVN-4885?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17498287#comment-17498287 ] 

Daniel Shahaf edited comment on SVN-4885 at 2/25/22, 10:48 PM:
---------------------------------------------------------------

I think that doesn't address the use-case I described, which was that an upgrade _was_ done, but not to the latest version.

Looking at the new conditions:

[[[
https://svn.apache.org/viewvc/subversion/trunk/subversion/svn/upgrade-cmd.c?r1=1898397&r2=1898396&pathrev=1898397
+  /* Remind the user they can upgrade further if:
+   *   - no upgrade was performed
+   *   - the user did not specify compatible-version explicitly
+   *   - a higher version is available. */
]]]

I'd question the first condition.  Suppose I run {{svn1.15 upgrade}} on a f29 wc, getting f31.  I think it would be reasonable to notify that an upgrade to f32 is further possible, particularly since the book explicitly documents that «svn upgrade» would upgrade to the "most recent metadata format supported by your version of Subversion" (https://svnbook.red-bean.com/nightly/en/svn.ref.svn.c.upgrade.html) [I copy-pasted this sentence from an earlier message today, <https://mail-archives.apache.org/mod_mbox/subversion-dev/202202.mbox/%3C20220225185702.GC8073%40tarpaulin.shahaf.local2%3E>].

Also, I think the second sentence is a bit unclear, since it doesn't say what the effect of the specification would be.  Suggesting instead:

svn: The working copy at '%(wcroot_path)s' is already at version 1.8; to upgrade to the highest version … specify '--compatible-version=%d.%d'.".

Changes:

- Add "svn: "
- Add the path of the working copy in question (rule of thumb: every error message should have at least one %s)
- Use semicolon for advice, since IIRC we document that somewhere as a convention for error messages

So, how about striking the first condition form that comment?  I.e., printing the reminder both when the command was a no-op and when an upgrade was performed to an implicit, non-latest version?


was (Author: danielsh):
I think that doesn't address the use-case I described, which was that an upgrade _was_ done, but not to the latest version.

Looking at the new conditions:

[[[
https://svn.apache.org/viewvc/subversion/trunk/subversion/svn/upgrade-cmd.c?r1=1898397&r2=1898396&pathrev=1898397
+  /* Remind the user they can upgrade further if:
+   *   - no upgrade was performed
+   *   - the user did not specify compatible-version explicitly
+   *   - a higher version is available. */
]]]

I'd question the first condition.  Suppose I run {{svn1.15 upgrade}} on a f29 wc, getting f31.  I think it would be reasonable to notify that an upgrade to f32 is further possible, particularly since the book explicitly documents that «svn upgrade» would upgrade to the "most recent metadata format supported by your version of Subversion" (https://svnbook.red-bean.com/nightly/en/svn.ref.svn.c.upgrade.html) [I copy-pasted this sentence from an earlier message today, <https://mail-archives.apache.org/mod_mbox/subversion-dev/202202.mbox/%3C20220225185702.GC8073%40tarpaulin.shahaf.local2%3E>].

Also, I think the second sentence is a bit unclear, since it doesn't say what the effect of the specification would be.  Suggesting instead:

svn: The working copy at '%(wcroot_path)s' is already at version 1.8; to upgrade to the highest version … specify '--compatible-version=%d.%d'.".

Changes:

- Add "svn: "
- Add the path of the working copy in question (rule of thumb: every error message should have at least one %s)
- Use semicolon for advice, since IIRC we document that somewhere as a convention for error messages

So, how about notifying whether or not an upgrade was performed?  I.e., simply striking the first condition?

> multi-wc-format: WC upgraded and not-upgraded notifications
> -----------------------------------------------------------
>
>                 Key: SVN-4885
>                 URL: https://issues.apache.org/jira/browse/SVN-4885
>             Project: Subversion
>          Issue Type: Bug
>            Reporter: Julian Foad
>            Priority: Major
>              Labels: api
>
> Daniel Shahaf wrote, in dev@ email "multi-wc-format review":
> «svn upgrade» of an f31 working copy does nothing and prints nothing. I see this is deliberate behaviour (by the docstring of SVN_WC__DEFAULT_VERSION).
> [...] should «svn upgrade» print an info message to the effect of "I upgraded your wc to f31 but I can also upgrade it to f32 if you request that explicitly", so users don't mistakenly assume they're running the latest-and-greatest wc format?



--
This message was sent by Atlassian Jira
(v8.20.1#820001)