From bb7e74c1e971a3aa64203820b86703a6495c6807 Mon Sep 17 00:00:00 2001 From: fang Date: Wed, 11 May 2022 16:16:03 +0200 Subject: [PATCH] arvo: add %uv hash case to scry paths Clay desparately wants something like this. It helps answer questions around hash-based content fetching. --- pkg/arvo/sys/arvo.hoon | 3 +++ pkg/arvo/sys/lull.hoon | 1 + pkg/arvo/sys/vane/clay.hoon | 1 + 3 files changed, 5 insertions(+) diff --git a/pkg/arvo/sys/arvo.hoon b/pkg/arvo/sys/arvo.hoon index 6de32dbb9..0f8d01915 100644 --- a/pkg/arvo/sys/arvo.hoon +++ b/pkg/arvo/sys/arvo.hoon @@ -39,10 +39,12 @@ $% :: %da: date :: %tas: label :: %ud: sequence + :: %uv: hash :: [%da p=@da] [%tas p=@tas] [%ud p=@ud] + [%uv p=@uv] == +$ cage (cask vase) ++ cask |$ [a] (pair mark a) @@ -313,6 +315,7 @@ ^- (unit case) ?^ num=(slaw %ud knot) `[%ud u.num] ?^ wen=(slaw %da knot) `[%da u.wen] + ?^ hax=(slaw %uv knot) `[%uv u.hax] ?~ lab=(slaw %tas knot) ~ `[%tas u.lab] :: diff --git a/pkg/arvo/sys/lull.hoon b/pkg/arvo/sys/lull.hoon index 0573f6d0f..2fc62350a 100644 --- a/pkg/arvo/sys/lull.hoon +++ b/pkg/arvo/sys/lull.hoon @@ -1754,6 +1754,7 @@ $% [%da p=@da] :: date [%tas p=@tas] :: label [%ud p=@ud] :: number + [%uv p=@uv] :: hash == :: +$ cash :: case or tako $% [%tako p=tako] :: diff --git a/pkg/arvo/sys/vane/clay.hoon b/pkg/arvo/sys/vane/clay.hoon index dd9e9dbfc..4f2f4e965 100644 --- a/pkg/arvo/sys/vane/clay.hoon +++ b/pkg/arvo/sys/vane/clay.hoon @@ -1451,6 +1451,7 @@ ?- -.lok %tas (~(get by lab.dom) p.lok) %ud ?:((gth p.lok let.dom) ~ [~ p.lok]) + %uv ?~(yak=(~(get by hut.ran) p.lok) ~ $(lok [%da t.u.yak])) %da ?: (gth p.lok lim) ~ |- ^- (unit aeon)