changeset 49480:0199712c7a6d

rhg: fallback in `debugdata` if repo has `narrow` Narrow uses ellipsis nodes and debugdata does not understand them yet.
author Raphaël Gomès <rgomes@octobus.net>
date Mon, 11 Jul 2022 17:44:03 +0200
parents 6193e846cb65
children a0d189b2e871
files rust/rhg/src/commands/debugdata.rs
diffstat 1 files changed, 5 insertions(+), 0 deletions(-) [+]
line wrap: on
line diff
--- a/rust/rhg/src/commands/debugdata.rs	Wed Jul 06 11:46:00 2022 +0200
+++ b/rust/rhg/src/commands/debugdata.rs	Mon Jul 11 17:44:03 2022 +0200
@@ -55,6 +55,11 @@
         };
 
     let repo = invocation.repo?;
+    if repo.has_narrow() {
+        return Err(CommandError::unsupported(
+            "support for ellipsis nodes is missing and repo has narrow enabled",
+        ));
+    }
     let data = debug_data(repo, rev, kind).map_err(|e| (e, rev))?;
 
     let mut stdout = invocation.ui.stdout_buffer();