Merge branch 'philip/gall-clear'

This commit is contained in:
Isaac Visintainer 2020-04-02 15:32:43 -07:00
commit 2ad8264c52
5 changed files with 49 additions and 1 deletions

View File

@ -0,0 +1,14 @@
:: Clear ship from pending queues
::
:::: /hoon/gall-sear/hood/gen
::
/? 310
::
::::
!:
:- %say
|= $: [now=@da eny=@uvJ bec=beak]
[=ship ~]
~
==
[%kiln-gall-sear ship]

View File

@ -227,6 +227,7 @@
?- ver
%1
=< se-abet =< se-view
=< (se-emit %pass /kiln %arvo %g %sear ~wisrut-nocsub)
=< (se-born %home %goad)
=< (se-born %home %metadata-store)
=< (se-born %home %metadata-hook)
@ -240,6 +241,7 @@
::
%2
=< se-abet =< se-view
=< (se-emit %pass /kiln %arvo %g %sear ~wisrut-nocsub)
=< (se-born %home %metadata-store)
=< (se-born %home %metadata-hook)
=< (se-born %home %contact-store)

View File

@ -210,7 +210,8 @@
%kiln-keep-ford =;(f (f !<(_+<.f vase)) poke-keep-ford)
%kiln-autoload =;(f (f !<(_+<.f vase)) poke-autoload)
%kiln-overload =;(f (f !<(_+<.f vase)) poke-overload)
%kiln-goad-gall =;(f (f !<(_+<.f vase)) poke-overload)
%kiln-goad-gall =;(f (f !<(_+<.f vase)) poke-goad-gall)
%kiln-gall-sear =;(f (f !<(_+<.f vase)) poke-gall-sear)
%kiln-wash-gall =;(f (f !<(_+<.f vase)) poke-wash-gall)
%kiln-unmount =;(f (f !<(_+<.f vase)) poke-unmount)
%kiln-unsync =;(f (f !<(_+<.f vase)) poke-unsync)
@ -314,6 +315,10 @@
|= [force=? agent=(unit dude:gall)]
abet:(emit %pass /kiln %arvo %g %goad force agent)
::
++ poke-gall-sear
|= =ship
abet:(emit %pass /kiln %arvo %g %sear ship)
::
++ poke-wash-gall |=(* abet:(emit %pass /kiln %arvo %g [%wash ~]))
::
++ done

View File

@ -421,6 +421,7 @@
|= =ship
^+ mo-core
=. mo-core (mo-untrack-ship ship)
=. mo-core (mo-filter-queue ship)
=/ agents=(list [name=term =running-agent]) ~(tap by running.agents.state)
|- ^+ mo-core
?~ agents
@ -724,6 +725,28 @@
=/ card [%slip %g %deal sock term deal]
[duct card]
$(moves [move moves])
:: +mo-filter-queue: remove all blocked tasks from ship.
::
++ mo-filter-queue
|= =ship
=/ agents=(list [name=term =blocked]) ~(tap by blocked.agents.state)
=| new-agents=(map term blocked)
|- ^+ mo-core
?~ agents
mo-core(blocked.agents.state new-agents)
=| new-blocked=blocked
|- ^+ mo-core
?: =(~ blocked.i.agents)
?~ new-blocked
^$(agents t.agents)
%= ^$
agents t.agents
new-agents (~(put by new-agents) name.i.agents new-blocked)
==
=^ mov blocked.i.agents ~(get to blocked.i.agents)
=? new-blocked !=(ship attributing.q.p.mov)
(~(put to new-blocked) mov)
$
:: +mo-beak: assemble a beak for the specified agent.
::
++ mo-beak
@ -1512,6 +1535,9 @@
::
%goad
mo-abet:(mo-goad:initialised force.task agent.task)
::
%sear
mo-abet:(mo-filter-queue:initialised ship.task)
::
%init
=/ payload gall-payload(system-duct.agents.state duct)

View File

@ -1825,6 +1825,7 @@
$% [$conf p=dock q=dock] :: configure app
[$deal p=sock q=term r=deal] :: full transmission
[%goad force=? agent=(unit dude)] :: rebuild agent(s)
[%sear =ship] :: clear pending queues
$>(%init vane-task) :: set owner
$>(%trim vane-task) :: trim state
$>(%vega vane-task) :: report upgrade