A-373 grants-list-and-pass-as-objects: the keys list and pass of user-list name an object of the part's bucket, since each outgrows one bucket value

Builds: design 47 G A-373 (G-22-lead-answers-2.md)

Claude-Session: https://claude.ai/code/session_01NcbgfGKaxw984XyAPfLm4h
This commit is contained in:
2026-11-13 22:04:21 +01:00
parent fc51bf4832
commit e2eb99fc19
5 changed files with 154 additions and 2 deletions
+1 -1
View File
@@ -177,7 +177,7 @@ func run(ctx context.Context, getenv func(string) string, logOut io.Writer) erro
return err
}
fv.Assignment = assignment
f.Part = &grants.Part{Read: fv, Call: conn, Store: ownStore{conn}, Emit: emitting{conn}, Views: fv, FirstViewContext: ctx,
f.Part = &grants.Part{Read: fv, Call: conn, Store: grants.BigValues(ownStore{conn}, sealedObjects{ctx: ctx, js: js}), Emit: emitting{conn}, Views: fv, FirstViewContext: ctx,
Create: creating{ctx: ctx, js: js}, Consumers: creating{ctx: ctx, js: js}, NamedPurge: creating{ctx: ctx, js: js},
Objects: sealedObjects{ctx: ctx, js: js}, Purging: ownPurging{ctx: ctx, js: js, module: account.Module}, Logf: logger.Printf,
Bus: grants.BusAddress{URL: account.URL, Fingerprint: account.Fingerprint}}
@@ -53,3 +53,14 @@ func (o sealedObjects) DeleteObject(name string) error {
}
return nil
}
// GetObject reads one object of the bucket whole: what the keys `list` and `pass` of the state user-list name (design 47 G A-373).
func (o sealedObjects) GetObject(name string) ([]byte, error) {
ctx, cancel := context.WithTimeout(o.ctx, requestWithin)
defer cancel()
s, err := o.store(ctx)
if err != nil {
return nil, err
}
return s.GetBytes(ctx, name)
}
+1 -1
View File
@@ -320,7 +320,7 @@ func recordHandActAs(cause string) func(what, why string) error {
func serveTools() error {
tv := &toolViews{}
gate := newSeatGate()
p := &grants.Part{Read: runtimeReader{views: tv}, Call: runtimeBus{}, Store: runtimeStore{}, Emit: runtimeBus{}, SeatList: gate}
p := &grants.Part{Read: runtimeReader{views: tv}, Call: runtimeBus{}, Store: grants.BigValues(runtimeStore{}, nil), Emit: runtimeBus{}, SeatList: gate}
// The reader asks through the runtime, which serves once Serve has its channel.
go func() {
<-stdio.Served()