mirror of
https://github.com/urbit/shrub.git
synced 2024-12-20 09:21:42 +03:00
gall: stop sending %onto
Gall would send %onto gifts to notify about app updates and update failures. This would end up in dill, which printed some appropriate text. Here, we make gall responsible for doing this printing itself (by having it explicitly ask dill to print some tape/tank), instead of relying on the receiving end of some bespoke notification protocol.
This commit is contained in:
parent
c4f470ec15
commit
5ef68d38c7
@ -112,7 +112,6 @@
|
||||
|= [=wire syn=sign-arvo]
|
||||
^- step:agent:gall
|
||||
?+ wire ~|([%hood-bad-wire wire] !!)
|
||||
[%drum *] =^(c drum.state (take-arvo:drum-core t.wire syn) [c this])
|
||||
[%helm *] =^(c helm.state (take-arvo:helm-core t.wire syn) [c this])
|
||||
[%kiln *] =^(c kiln.state (take-arvo:kiln-core t.wire syn) [c this])
|
||||
==
|
||||
|
@ -344,12 +344,6 @@
|
||||
::
|
||||
(se-drop & gyl)
|
||||
::
|
||||
++ take-arvo
|
||||
|= [=wire =sign-arvo]
|
||||
%+ take-onto wire
|
||||
?> ?=(%onto +<.sign-arvo)
|
||||
+>.sign-arvo
|
||||
::
|
||||
++ take-coup-phat :: ack poke
|
||||
|= [way=wire saw=(unit tang)]
|
||||
=< se-abet =< se-view
|
||||
@ -360,19 +354,6 @@
|
||||
:_ u.saw
|
||||
>[%drum-coup-fail src.hid gyl]<
|
||||
::
|
||||
++ take-onto :: ack start
|
||||
|= [way=wire saw=(each suss:gall tang)]
|
||||
=< se-abet =< se-view
|
||||
?> ?=([@ @ ~] way)
|
||||
?> (~(has by fur) i.t.way)
|
||||
=/ wel=well:gall [i.way i.t.way]
|
||||
?- saw
|
||||
[%| *] (se-dump p.saw)
|
||||
[%& *] ?> =(q.wel p.p.saw)
|
||||
:: =. +>.$ (se-text "live {<p.saw>}")
|
||||
+>.$(fur (~(put by fur) q.wel `[p.wel %da r.p.saw]))
|
||||
==
|
||||
::
|
||||
++ take-agent
|
||||
|= [=wire =sign:agent:gall]
|
||||
?+ wire ~|([%drum-bad-take-agent wire -.sign] !!)
|
||||
|
@ -1611,7 +1611,6 @@
|
||||
+$ gift :: outgoing result
|
||||
$% [%boon payload=*] :: ames response
|
||||
[%done error=(unit error:ames)] :: ames message (n)ack
|
||||
[%onto p=(each suss tang)] :: about agent
|
||||
[%unto p=sign:agent] ::
|
||||
== ::
|
||||
+$ task :: incoming request
|
||||
|
@ -78,10 +78,7 @@
|
||||
$>(%blit gift:dill) ::
|
||||
== ::
|
||||
$: %gall ::
|
||||
$> $? %onto ::
|
||||
%unto ::
|
||||
== ::
|
||||
gift:gall ::
|
||||
$>(%unto gift:gall) ::
|
||||
== == ::
|
||||
:::::::: :: dill tiles
|
||||
--
|
||||
@ -248,12 +245,6 @@
|
||||
|= [tea=wire sih=sign]
|
||||
^+ +>
|
||||
?- sih
|
||||
[%gall %onto *]
|
||||
?- -.+>.sih
|
||||
%| (crud %onto p.p.+>.sih)
|
||||
%& (fore (tuba "{(t q)}ed %{(t p)}":[t=trip p.p.sih]) ~)
|
||||
==
|
||||
::
|
||||
[%gall %unto *]
|
||||
:: ~& [%take-gall-unto +>.sih]
|
||||
?- -.+>.sih
|
||||
|
@ -159,7 +159,7 @@
|
||||
~< %slog.[0 leaf+"gall: molted"]
|
||||
:: +molt should never notify its client about agent changes
|
||||
::
|
||||
=- [(skip -< |=(move ?=([* %give %onto *] +<))) ->]
|
||||
=- [(skip -< |=(move ?=([* %pass [%sys %say ~] *] +<))) ->]
|
||||
=/ adult adult-core
|
||||
=. state.adult
|
||||
[%7 system-duct outstanding contacts yokes=~ blocked]:spore
|
||||
@ -263,12 +263,22 @@
|
||||
:: +mo-abet: finalize, reversing moves
|
||||
:: +mo-pass: prepend a standard %pass to the current list of moves
|
||||
:: +mo-give: prepend a standard %give to the current list of moves
|
||||
:: +mo-talk: build task to print config report or failure trace
|
||||
::
|
||||
++ mo-core .
|
||||
++ mo-abed |=(hun=duct mo-core(hen hun))
|
||||
++ mo-abet [(flop moves) gall-payload]
|
||||
++ mo-pass |=(p=[wire note-arvo] mo-core(moves [[hen pass+p] moves]))
|
||||
++ mo-give |=(g=gift mo-core(moves [[hen give+g] moves]))
|
||||
++ mo-talk
|
||||
|= rup=(each suss tang)
|
||||
^- [wire note-arvo]
|
||||
:+ /sys/say %d
|
||||
^- task:dill
|
||||
?- -.rup
|
||||
%& [%text "gall: {(t q)}ed %{(t p)}":[t=trip p.rup]]
|
||||
%| [%talk leaf+"gall: failed" (flop p.rup)]
|
||||
==
|
||||
:: +mo-boot: ask %ford to build us a core for the specified agent.
|
||||
::
|
||||
++ mo-boot
|
||||
@ -346,12 +356,12 @@
|
||||
=/ ap-core +.wag
|
||||
?^ maybe-tang
|
||||
=. mo-core old
|
||||
(mo-give %onto %.n u.maybe-tang)
|
||||
(mo-pass (mo-talk %.n u.maybe-tang))
|
||||
::
|
||||
=. mo-core ap-abet:ap-core
|
||||
=. mo-core (mo-clear-queue dap)
|
||||
=/ =suss [dap %boot now]
|
||||
(mo-give %onto [%.y suss])
|
||||
(mo-pass (mo-talk %.y suss))
|
||||
:: +mo-subscribe-to-agent-builds: request agent update notices
|
||||
::
|
||||
:: Also subscribe to our own source path, in case we get reloaded
|
||||
@ -541,7 +551,7 @@
|
||||
++ fail
|
||||
|= =tang
|
||||
^+ mo-core
|
||||
=. mo-core (mo-give %onto |+tang)
|
||||
=. mo-core (mo-pass (mo-talk |+tang))
|
||||
=/ =case [%da tim]
|
||||
=/ =wire /sys/cor/[dap]/[her]/[desk]/(scot case)
|
||||
(mo-pass wire %c %warp p.beak desk ~ %next %a case /app/[dap]/hoon)
|
||||
@ -1017,8 +1027,8 @@
|
||||
::
|
||||
=/ running (~(put by yokes.state) agent-name current-agent)
|
||||
=/ moves
|
||||
=/ giver |=(report=(each suss tang) [hen %give %onto report])
|
||||
=/ from-suss (turn agent-config giver)
|
||||
=/ talker |=(report=(each suss tang) [hen %pass (mo-talk report)])
|
||||
=/ from-suss (turn agent-config talker)
|
||||
:(weld agent-moves from-suss moves)
|
||||
::
|
||||
%_ mo-core
|
||||
|
@ -107,11 +107,8 @@
|
||||
$>(%wake gift:behn) ::
|
||||
== ::
|
||||
$: %gall ::
|
||||
$> $? %onto ::
|
||||
%unto ::
|
||||
$>(%unto gift:gall) ::
|
||||
== ::
|
||||
gift:gall ::
|
||||
==
|
||||
== ::
|
||||
-- ::
|
||||
:: ::::
|
||||
@ -557,10 +554,6 @@
|
||||
=/ ships (~(get ju ship-sources-reverse.etn) source-id)
|
||||
%- curd =< abet
|
||||
(sources:~(feel su hen now pki etn) ships source)
|
||||
::
|
||||
[%gall %onto *]
|
||||
~& [%jael-onto tea hin]
|
||||
+>.$
|
||||
::
|
||||
[%gall %unto *]
|
||||
?- +>-.hin
|
||||
|
Loading…
Reference in New Issue
Block a user