Open rabsef-bicrym opened 1 year ago
We've run into a weird issue with it mounting. There's a branch set up at develop-ui
with our boilerplate and we were working on just getting basic subscriptions down, but no matter what we do, when you access the page (on localhost:80 or localhost:3000, it doesn't matter), Eyre throws a stack trace:
crud: %request event failed
[%poke %request]
wire=/run-app-request/~.eyre_0v6.ddvhm.c728h.c2d3h.qa1e9.01kf9
bar-stack
~[
~[//http-server/0v1s.dkq90/28/6]
~[
/eyre/run-app-request/~.eyre_0v6.ddvhm.c728h.c2d3h.qa1e9.01kf9
//http-server/0v1s.dkq90/28/6
]
~[//http-server/0v1s.dkq90/28/6]
]
take: failed
/sys/vane/eyre/hoon:<[2.356 3].[2.529 5]>
/sys/vane/eyre/hoon:<[2.357 3].[2.529 5]>
/sys/vane/eyre/hoon:<[2.359 3].[2.529 5]>
/sys/vane/eyre/hoon:<[2.368 3].[2.529 5]>
/sys/vane/eyre/hoon:<[2.370 3].[2.529 5]>
/sys/vane/eyre/hoon:<[2.370 7].[2.381 9]>
/sys/vane/eyre/hoon:<[2.372 7].[2.381 9]>
/sys/vane/eyre/hoon:<[2.375 28].[2.375 43]>
/sys/vane/eyre/hoon:<[2.385 5].[2.401 29]>
/sys/vane/eyre/hoon:<[2.388 5].[2.401 29]>
/sys/vane/eyre/hoon:<[2.389 5].[2.401 29]>
/sys/vane/eyre/hoon:<[2.390 5].[2.401 29]>
/sys/vane/eyre/hoon:<[2.396 5].[2.401 29]>
/sys/vane/eyre/hoon:<[2.397 5].[2.401 29]>
/sys/vane/eyre/hoon:<[2.399 5].[2.401 29]>
/sys/vane/eyre/hoon:<[2.400 7].[2.400 37]>
/sys/vane/eyre/hoon:<[1.807 5].[1.827 35]>
/sys/vane/eyre/hoon:<[1.809 5].[1.827 35]>
/sys/vane/eyre/hoon:<[1.809 9].[1.809 54]>
/sys/vane/eyre/hoon:<[1.809 20].[1.809 54]>
And if you browse the Network tab you can see that desk.js
is spinning forever, never giving us its content. At first I thought it was because our scry or subscription requests were malformed, but even without any request to the back-end, Eyre throws its hands up trying to handle it. I wondered — "maybe the window.desk injection inside Eyre serving globs can't handle dashes in the desk name?" — but that's unclear, I removed all dashes and it just never showed up in Grid then. Well. Okay.
So. Here's what I'll say for reproduction:
develop-ui
.|merge %full-stop our %garden
|commit %full-stop
and |install our %full-stop
.Click "Full Stop" on the grid — you don't even have to run the dev server! You'll see the issue in the Dojo. The glob I've assigned to the docket is just the Grid, so you'd expect to see Grid, but instead nothing loads and it crashes on the back-end.
Introduction
Full-Stop is a period tracker for Urbit. Both directly connected front-ends and offline->sync applications can communicate updates to Full-Stop allowing users to utilize offline local data storage when they are without internet, while maintaining an accurate record of data on their urbits. When offline systems sync, their changes are read and implemented (where appropriate) and the resultant data is sent back to the application to update local state.
Model Theory
Full-Stop operates on the following model:
rate
andspot
).Subscription
Subscribe on
[%website ~]
for data.On first subscription, receive full data set:
Pokes and Outcomes
Pokes
The system always expects a
drop
which is a(list [activity time])
. An activity is a blended case of all the pokes listed below, the time at the tail of the cell should be when the poke was made by the user, so that we can date it against conflicting updates from other sources, during sync.Marks
The expected
mark
is a%dot-point
. When there is a unit in a poke, I will write soft parsers - please assume that sending me'garbage'
or anything other than a reasonable answer will result in anull
while a reasonable answer will be taken as theunit
of itself.Notes
Sanguine
Handles menstruation tracking.
Test Data
Load period data starting 11.1.2021 thru 8.5.2022:
Add some rate reports:
Add some spotting reports:
[%flow wen=time]
Example JSON Poke:
Expectation Start or remove a flow - we'll basically take anything, except for a time within another period. If you give us a day we already have tracked as the start of a period, we'll delete that instance.
Result
{ del-flow: <start-date in seconds> }
{ need-flow-stop: <start-date-of-conflicting-period> }
- You have an open period recorded prior to the one you're trying to record that needs to be closed. Close it and try entering this again.[%stop wen=time]
Example JSON Poke
Expectation Set or adjust the stop date for a given period. We'll take anything, find the period corresponding to it, and (assuming we don't have a more recent update for that period) adjust the period's stop date to the date you just provided.
Result
On Add
On Adjust
and separately if needed
On Error
{need-flow-start: <proposed stop date>}
- You've given me a stop date I cannot associate with a period.[%spot wen=time]
Example JSON Poke
Expectation Add or delete an instance of spotting, outside your cycle. These are not checked against edit time.
Result
{need-prior-flow: <a spotting date you gave me>}
- I don't see a flow starting and stopping before this date, and thus I can't tell if this is a valid spotting occasion.{need-flow-stop: <a spotting date you gave me>}
- You indicated you are spotting in a period that doesn't have a stop date associated - are you sure this isn't part of your period?{spot-inside-flow: [<start date> <stop date>]}
- You indicated you were spotting during a recorded period - not sure what you want me to do with that.[%rate how=(unit ?(%1 %2 %3 %4 %5) wen=time]
Example JSON Poke
or
Expectation Add or delete (on
how=~
) a rate report within the window of a period. These are not checked against edit time so go crazy, go stupid, enter conflicting information from various sources, we won't even notice.Result
{need-flow-start: <your-rate-date>}
- I don't have a flow to which this could correspond.{rate-doesnt-exist: <your-rate-date>}
- You asked me to delete a rate report that I don't have recorded.{rate-outside-flow: ~[<start-date> <stop-date>]}
- You gave me a rate report outside of your purported period, here is the stop and start date I have recorded - fix that first.Physical
Handles fertility prediction aid tracking (basal body temp and cervical mucosal consistency)
Test Data
Load some temps
Load some mucosal reports
[%temp baz=(unit @rs) wen=time]
Example JSON Poke
Expectation
Result
{del-fire: <date to delete>}
or `{add-fire: {when:On Error
{temp-fail-delete: <date you gave>}
- You gave me a null unit, indicating you wanted to delete a something - I don't have a report there.[%muco con=(unit cons) wen=time]
Example JSON Poke
Expectation
Result
{del-rain: <date to delete>}
or{add-rain: {when: <date>, drip: <rating>, edit: <date>}}
{muco-fail-delete: <date you gave>}
- You gave me a null unit indicating you wanted to delete something - I don't have a report there.Controls
Handles birth control method tracking/alerting
Relation
Handles sexual encounter tracking
Election
Handles agent settings (notifications, fertility window predictions)
Pregnant
Handles pregnancy tracking
Scrys