mirror of
https://github.com/urbit/shrub.git
synced 2024-12-20 17:32:11 +03:00
Merge pull request #6976 from urbit/yu/fix-old-migrations
ames: fix old state migrations
This commit is contained in:
commit
dad0bbfec5
@ -1275,6 +1275,17 @@
|
|||||||
counter=@ud
|
counter=@ud
|
||||||
==
|
==
|
||||||
::
|
::
|
||||||
|
+$ task-4-til-8
|
||||||
|
$+ task-4-til-8
|
||||||
|
$% [?(%heed %jilt) =ship] :: introduced in state %4, removed in %21
|
||||||
|
$<(?(%snub %kroc %deep %keen) task) :: tasks introduced later
|
||||||
|
==
|
||||||
|
+$ queued-event-4-til-8
|
||||||
|
$+ queued-event-4-til-8
|
||||||
|
$% [%call =duct wrapped-task=(hobo task-4-til-8)]
|
||||||
|
[%take =wire =duct =sign]
|
||||||
|
==
|
||||||
|
::
|
||||||
+$ queued-event-9-til-11
|
+$ queued-event-9-til-11
|
||||||
$+ queued-event-9-til-11
|
$+ queued-event-9-til-11
|
||||||
$% [%call =duct wrapped-task=(hobo task-9-til-11)]
|
$% [%call =duct wrapped-task=(hobo task-9-til-11)]
|
||||||
@ -1285,6 +1296,7 @@
|
|||||||
$+ task-9-til-11
|
$+ task-9-til-11
|
||||||
$% [%kroc dry=?] :: introduced in state %10, modified in %17
|
$% [%kroc dry=?] :: introduced in state %10, modified in %17
|
||||||
[%snub ships=(list ship)] :: introduced in state %9, modified in %11
|
[%snub ships=(list ship)] :: introduced in state %9, modified in %11
|
||||||
|
[?(%heed %jilt) =ship] :: introduced in state %4, removed in %21
|
||||||
$<(?(%snub %kroc %deep %keen) task) :: %deep/%keen introduced later
|
$<(?(%snub %kroc %deep %keen) task) :: %deep/%keen introduced later
|
||||||
==
|
==
|
||||||
::
|
::
|
||||||
@ -1299,6 +1311,7 @@
|
|||||||
$% [%kroc dry=?] :: introduced in state %10, modified in %17
|
$% [%kroc dry=?] :: introduced in state %10, modified in %17
|
||||||
[%keen spar] :: introduced in state %13, modified in %19
|
[%keen spar] :: introduced in state %13, modified in %19
|
||||||
deep-task-14 :: introduced in state %14, modified in %19
|
deep-task-14 :: introduced in state %14, modified in %19
|
||||||
|
[?(%heed %jilt) =ship] :: introduced in state %4, removed in %21
|
||||||
$<(?(%kroc %keen %deep) task)
|
$<(?(%kroc %keen %deep) task)
|
||||||
==
|
==
|
||||||
::
|
::
|
||||||
@ -1321,6 +1334,7 @@
|
|||||||
$+ task-16-and-18
|
$+ task-16-and-18
|
||||||
$% [%keen spar] :: introduced in state %13, modified in %19
|
$% [%keen spar] :: introduced in state %13, modified in %19
|
||||||
deep-task-14 :: introduced in state %14, modified in %19
|
deep-task-14 :: introduced in state %14, modified in %19
|
||||||
|
[?(%heed %jilt) =ship] :: introduced in state %4, removed in %21
|
||||||
$<(?(%keen %deep) task)
|
$<(?(%keen %deep) task)
|
||||||
==
|
==
|
||||||
::
|
::
|
||||||
@ -1347,16 +1361,15 @@
|
|||||||
=chain
|
=chain
|
||||||
==
|
==
|
||||||
::
|
::
|
||||||
+$ task-20
|
+$ task-19-and-20
|
||||||
$+ task-20
|
$+ task-19-and-20
|
||||||
$% task
|
$% [?(%heed %jilt) =ship] :: introduced in state %4, removed in %21
|
||||||
[%heed =ship]
|
task
|
||||||
[%jilt =ship]
|
|
||||||
==
|
==
|
||||||
::
|
::
|
||||||
+$ queued-event-20
|
+$ queued-event-19-and-20
|
||||||
$+ queued-event-20
|
$+ queued-event-19-and-20
|
||||||
$% [%call =duct wrapped-task=(hobo task-20)]
|
$% [%call =duct wrapped-task=(hobo task-19-and-20)]
|
||||||
[%take =wire =duct =sign]
|
[%take =wire =duct =sign]
|
||||||
==
|
==
|
||||||
::
|
::
|
||||||
@ -1696,35 +1709,35 @@
|
|||||||
|= $= old
|
|= $= old
|
||||||
$% $: %4
|
$% $: %4
|
||||||
$% $: %larva
|
$% $: %larva
|
||||||
events=(qeu queued-event)
|
events=(qeu queued-event-4-til-8)
|
||||||
state=ames-state-4
|
state=ames-state-4
|
||||||
==
|
==
|
||||||
[%adult state=ames-state-4]
|
[%adult state=ames-state-4]
|
||||||
== ==
|
== ==
|
||||||
$: %5
|
$: %5
|
||||||
$% $: %larva
|
$% $: %larva
|
||||||
events=(qeu queued-event)
|
events=(qeu queued-event-4-til-8)
|
||||||
state=ames-state-5
|
state=ames-state-5
|
||||||
==
|
==
|
||||||
[%adult state=ames-state-5]
|
[%adult state=ames-state-5]
|
||||||
== ==
|
== ==
|
||||||
$: %6
|
$: %6
|
||||||
$% $: %larva
|
$% $: %larva
|
||||||
events=(qeu queued-event)
|
events=(qeu queued-event-4-til-8)
|
||||||
state=ames-state-6
|
state=ames-state-6
|
||||||
==
|
==
|
||||||
[%adult state=ames-state-6]
|
[%adult state=ames-state-6]
|
||||||
== ==
|
== ==
|
||||||
$: %7
|
$: %7
|
||||||
$% $: %larva
|
$% $: %larva
|
||||||
events=(qeu queued-event)
|
events=(qeu queued-event-4-til-8)
|
||||||
state=ames-state-7
|
state=ames-state-7
|
||||||
==
|
==
|
||||||
[%adult state=ames-state-7]
|
[%adult state=ames-state-7]
|
||||||
== ==
|
== ==
|
||||||
$: %8
|
$: %8
|
||||||
$% $: %larva
|
$% $: %larva
|
||||||
events=(qeu queued-event)
|
events=(qeu queued-event-4-til-8)
|
||||||
state=ames-state-8
|
state=ames-state-8
|
||||||
==
|
==
|
||||||
[%adult state=ames-state-8]
|
[%adult state=ames-state-8]
|
||||||
@ -1757,8 +1770,8 @@
|
|||||||
==
|
==
|
||||||
[%adult state=ames-state-12]
|
[%adult state=ames-state-12]
|
||||||
== ==
|
== ==
|
||||||
$: %13
|
$: %13 :: %keen introduced
|
||||||
$% $: %larva :: %keen introduced
|
$% $: %larva
|
||||||
events=(qeu queued-event-12-til-16)
|
events=(qeu queued-event-12-til-16)
|
||||||
state=ames-state-13
|
state=ames-state-13
|
||||||
==
|
==
|
||||||
@ -1801,14 +1814,14 @@
|
|||||||
== ==
|
== ==
|
||||||
$: %19 :: %keen & %deep modified
|
$: %19 :: %keen & %deep modified
|
||||||
$% $: %larva
|
$% $: %larva
|
||||||
events=(qeu queued-event-20)
|
events=(qeu queued-event-19-and-20)
|
||||||
state=ames-state-19
|
state=ames-state-19
|
||||||
==
|
==
|
||||||
[%adult state=ames-state-19]
|
[%adult state=ames-state-19]
|
||||||
== ==
|
== ==
|
||||||
$: %20 :: start informal %ping
|
$: %20 :: start informal %ping
|
||||||
$% $: %larva
|
$% $: %larva
|
||||||
events=(qeu queued-event-20)
|
events=(qeu queued-event-19-and-20)
|
||||||
state=ames-state-20
|
state=ames-state-20
|
||||||
==
|
==
|
||||||
[%adult state=ames-state-20]
|
[%adult state=ames-state-20]
|
||||||
@ -1837,7 +1850,11 @@
|
|||||||
[%5 %larva *]
|
[%5 %larva *]
|
||||||
~> %slog.0^leaf/"ames: larva %5 load"
|
~> %slog.0^leaf/"ames: larva %5 load"
|
||||||
=. cached-state `[%5 state.old]
|
=. cached-state `[%5 state.old]
|
||||||
=. queued-events events.old
|
=. queued-events %- event-20-to-21
|
||||||
|
%- event-17-and-18-to-20
|
||||||
|
%- event-12-til-16-to-17
|
||||||
|
%- event-9-til-11-to-12
|
||||||
|
events.old
|
||||||
larval-gate
|
larval-gate
|
||||||
::
|
::
|
||||||
[%6 %adult *]
|
[%6 %adult *]
|
||||||
@ -1848,7 +1865,11 @@
|
|||||||
[%6 %larva *]
|
[%6 %larva *]
|
||||||
~> %slog.0^leaf/"ames: larva %6 load"
|
~> %slog.0^leaf/"ames: larva %6 load"
|
||||||
=. cached-state `[%6 state.old]
|
=. cached-state `[%6 state.old]
|
||||||
=. queued-events events.old
|
=. queued-events %- event-20-to-21
|
||||||
|
%- event-17-and-18-to-20
|
||||||
|
%- event-12-til-16-to-17
|
||||||
|
%- event-9-til-11-to-12
|
||||||
|
events.old
|
||||||
larval-gate
|
larval-gate
|
||||||
::
|
::
|
||||||
[%7 %adult *]
|
[%7 %adult *]
|
||||||
@ -1858,8 +1879,12 @@
|
|||||||
::
|
::
|
||||||
[%7 %larva *]
|
[%7 %larva *]
|
||||||
~> %slog.0^leaf/"ames: larva %7 load"
|
~> %slog.0^leaf/"ames: larva %7 load"
|
||||||
=. queued-events events.old
|
|
||||||
=. cached-state `[%7 state.old]
|
=. cached-state `[%7 state.old]
|
||||||
|
=. queued-events %- event-20-to-21
|
||||||
|
%- event-17-and-18-to-20
|
||||||
|
%- event-12-til-16-to-17
|
||||||
|
%- event-9-til-11-to-12
|
||||||
|
events.old
|
||||||
larval-gate
|
larval-gate
|
||||||
::
|
::
|
||||||
[%8 %adult *]
|
[%8 %adult *]
|
||||||
@ -1870,7 +1895,11 @@
|
|||||||
[%8 %larva *]
|
[%8 %larva *]
|
||||||
~> %slog.0^leaf/"ames: larva %8 load"
|
~> %slog.0^leaf/"ames: larva %8 load"
|
||||||
=. cached-state `[%8 state.old]
|
=. cached-state `[%8 state.old]
|
||||||
=. queued-events events.old
|
=. queued-events %- event-20-to-21
|
||||||
|
%- event-17-and-18-to-20
|
||||||
|
%- event-12-til-16-to-17
|
||||||
|
%- event-9-til-11-to-12
|
||||||
|
events.old
|
||||||
larval-gate
|
larval-gate
|
||||||
::
|
::
|
||||||
[%9 %adult *]
|
[%9 %adult *]
|
||||||
@ -1882,7 +1911,7 @@
|
|||||||
~> %slog.0^leaf/"ames: larva %9 load"
|
~> %slog.0^leaf/"ames: larva %9 load"
|
||||||
=. cached-state `[%9 state.old]
|
=. cached-state `[%9 state.old]
|
||||||
=. queued-events %- event-20-to-21
|
=. queued-events %- event-20-to-21
|
||||||
%- event-17-and-18-to-last
|
%- event-17-and-18-to-20
|
||||||
%- event-12-til-16-to-17
|
%- event-12-til-16-to-17
|
||||||
%- event-9-til-11-to-12
|
%- event-9-til-11-to-12
|
||||||
events.old
|
events.old
|
||||||
@ -1897,7 +1926,7 @@
|
|||||||
~> %slog.1^leaf/"ames: larva %10 load"
|
~> %slog.1^leaf/"ames: larva %10 load"
|
||||||
=. cached-state `[%10 state.old]
|
=. cached-state `[%10 state.old]
|
||||||
=. queued-events %- event-20-to-21
|
=. queued-events %- event-20-to-21
|
||||||
%- event-17-and-18-to-last
|
%- event-17-and-18-to-20
|
||||||
%- event-12-til-16-to-17
|
%- event-12-til-16-to-17
|
||||||
%- event-9-til-11-to-12
|
%- event-9-til-11-to-12
|
||||||
events.old
|
events.old
|
||||||
@ -1912,7 +1941,7 @@
|
|||||||
~> %slog.1^leaf/"ames: larva %11 load"
|
~> %slog.1^leaf/"ames: larva %11 load"
|
||||||
=. cached-state `[%11 state.old]
|
=. cached-state `[%11 state.old]
|
||||||
=. queued-events %- event-20-to-21
|
=. queued-events %- event-20-to-21
|
||||||
%- event-17-and-18-to-last
|
%- event-17-and-18-to-20
|
||||||
%- event-12-til-16-to-17
|
%- event-12-til-16-to-17
|
||||||
%- event-9-til-11-to-12
|
%- event-9-til-11-to-12
|
||||||
events.old
|
events.old
|
||||||
@ -1927,7 +1956,7 @@
|
|||||||
~> %slog.1^leaf/"ames: larva %12 load"
|
~> %slog.1^leaf/"ames: larva %12 load"
|
||||||
=. cached-state `[%12 state.old]
|
=. cached-state `[%12 state.old]
|
||||||
=. queued-events %- event-20-to-21
|
=. queued-events %- event-20-to-21
|
||||||
%- event-17-and-18-to-last
|
%- event-17-and-18-to-20
|
||||||
%- event-12-til-16-to-17
|
%- event-12-til-16-to-17
|
||||||
events.old
|
events.old
|
||||||
larval-gate
|
larval-gate
|
||||||
@ -1941,7 +1970,7 @@
|
|||||||
~> %slog.1^leaf/"ames: larva %13 load"
|
~> %slog.1^leaf/"ames: larva %13 load"
|
||||||
=. cached-state `[%13 state.old]
|
=. cached-state `[%13 state.old]
|
||||||
=. queued-events %- event-20-to-21
|
=. queued-events %- event-20-to-21
|
||||||
%- event-17-and-18-to-last
|
%- event-17-and-18-to-20
|
||||||
%- event-12-til-16-to-17
|
%- event-12-til-16-to-17
|
||||||
events.old
|
events.old
|
||||||
larval-gate
|
larval-gate
|
||||||
@ -1955,7 +1984,7 @@
|
|||||||
~> %slog.1^leaf/"ames: larva %14 load"
|
~> %slog.1^leaf/"ames: larva %14 load"
|
||||||
=. cached-state `[%14 state.old]
|
=. cached-state `[%14 state.old]
|
||||||
=. queued-events %- event-20-to-21
|
=. queued-events %- event-20-to-21
|
||||||
%- event-17-and-18-to-last
|
%- event-17-and-18-to-20
|
||||||
%- event-12-til-16-to-17
|
%- event-12-til-16-to-17
|
||||||
events.old
|
events.old
|
||||||
larval-gate
|
larval-gate
|
||||||
@ -1969,7 +1998,7 @@
|
|||||||
~> %slog.1^leaf/"ames: larva %15 load"
|
~> %slog.1^leaf/"ames: larva %15 load"
|
||||||
=. cached-state `[%15 state.old]
|
=. cached-state `[%15 state.old]
|
||||||
=. queued-events %- event-20-to-21
|
=. queued-events %- event-20-to-21
|
||||||
%- event-17-and-18-to-last
|
%- event-17-and-18-to-20
|
||||||
%- event-12-til-16-to-17
|
%- event-12-til-16-to-17
|
||||||
events.old
|
events.old
|
||||||
larval-gate
|
larval-gate
|
||||||
@ -1983,7 +2012,7 @@
|
|||||||
~> %slog.1^leaf/"ames: larva %16 load"
|
~> %slog.1^leaf/"ames: larva %16 load"
|
||||||
=. cached-state `[%16 state.old]
|
=. cached-state `[%16 state.old]
|
||||||
=. queued-events %- event-20-to-21
|
=. queued-events %- event-20-to-21
|
||||||
%- event-17-and-18-to-last
|
%- event-17-and-18-to-20
|
||||||
%- event-12-til-16-to-17
|
%- event-12-til-16-to-17
|
||||||
events.old
|
events.old
|
||||||
larval-gate
|
larval-gate
|
||||||
@ -1996,7 +2025,9 @@
|
|||||||
[%17 %larva *]
|
[%17 %larva *]
|
||||||
~> %slog.1^leaf/"ames: larva %17 load"
|
~> %slog.1^leaf/"ames: larva %17 load"
|
||||||
=. cached-state `[%17 state.old]
|
=. cached-state `[%17 state.old]
|
||||||
=. queued-events (event-20-to-21 (event-17-and-18-to-last events.old))
|
=. queued-events %- event-20-to-21
|
||||||
|
%- event-17-and-18-to-20
|
||||||
|
events.old
|
||||||
larval-gate
|
larval-gate
|
||||||
::
|
::
|
||||||
[%18 %adult *]
|
[%18 %adult *]
|
||||||
@ -2007,7 +2038,9 @@
|
|||||||
[%18 %larva *]
|
[%18 %larva *]
|
||||||
~> %slog.1^leaf/"ames: larva %18 load"
|
~> %slog.1^leaf/"ames: larva %18 load"
|
||||||
=. cached-state `[%18 state.old]
|
=. cached-state `[%18 state.old]
|
||||||
=. queued-events (event-20-to-21 (event-17-and-18-to-last events.old))
|
=. queued-events %- event-20-to-21
|
||||||
|
%- event-17-and-18-to-20
|
||||||
|
events.old
|
||||||
larval-gate
|
larval-gate
|
||||||
::
|
::
|
||||||
[%19 %adult *]
|
[%19 %adult *]
|
||||||
@ -2072,17 +2105,17 @@
|
|||||||
[%kroc ~]
|
[%kroc ~]
|
||||||
==
|
==
|
||||||
::
|
::
|
||||||
++ event-17-and-18-to-last
|
++ event-17-and-18-to-20
|
||||||
|= events=(qeu queued-event-17-and-18)
|
|= events=(qeu queued-event-17-and-18)
|
||||||
^- (qeu queued-event)
|
^- (qeu queued-event-19-and-20)
|
||||||
%- ~(rep in events)
|
%- ~(rep in events)
|
||||||
|= [e=queued-event-17-and-18 q=(qeu queued-event)]
|
|= [e=queued-event-17-and-18 q=(qeu queued-event-19-and-20)]
|
||||||
%- ~(put to q) ^- queued-event
|
%- ~(put to q) ^- queued-event-19-and-20
|
||||||
?. ?=(%call -.e) e
|
?. ?=(%call -.e) e
|
||||||
=/ task=task-16-and-18 ((harden task-16-and-18) wrapped-task.e)
|
=/ task=task-16-and-18 ((harden task-16-and-18) wrapped-task.e)
|
||||||
%= e
|
%= e
|
||||||
wrapped-task
|
wrapped-task
|
||||||
^- ^task
|
^- task-19-and-20
|
||||||
?: ?=(%keen -.task)
|
?: ?=(%keen -.task)
|
||||||
[%keen ~ +.task]
|
[%keen ~ +.task]
|
||||||
?. ?=([%deep %nack *] task) task
|
?. ?=([%deep %nack *] task) task
|
||||||
@ -2095,15 +2128,17 @@
|
|||||||
%naxplanation
|
%naxplanation
|
||||||
[%deep %nack ship.task nack-bone.task ;;(message [hed msg])]
|
[%deep %nack ship.task nack-bone.task ;;(message [hed msg])]
|
||||||
==
|
==
|
||||||
|
::
|
||||||
++ event-20-to-21
|
++ event-20-to-21
|
||||||
|= events=(qeu queued-event-20)
|
|= events=(qeu queued-event-19-and-20)
|
||||||
^- (qeu queued-event)
|
^- (qeu queued-event)
|
||||||
%- ~(rep in events)
|
%- ~(rep in events)
|
||||||
|= [e=queued-event-20 q=(qeu queued-event)]
|
|= [e=queued-event-19-and-20 q=(qeu queued-event)]
|
||||||
?. ?=(%call -.e) (~(put to q) e)
|
?. ?=(%call -.e) (~(put to q) e)
|
||||||
=/ task=task-20 ((harden task-20) wrapped-task.e)
|
=/ task=task-19-and-20 ((harden task-19-and-20) wrapped-task.e)
|
||||||
?: ?=(?(%heed %jilt) -.task) q
|
?: ?=(?(%heed %jilt) -.task) q
|
||||||
(~(put to q) e(wrapped-task task))
|
(~(put to q) e(wrapped-task task))
|
||||||
|
::
|
||||||
--
|
--
|
||||||
:: +molt: re-evolve to adult-ames
|
:: +molt: re-evolve to adult-ames
|
||||||
::
|
::
|
||||||
|
Loading…
Reference in New Issue
Block a user