Repository navigation
osy 0.19.11
This release fixes rows that could be lost when a page saved while other work was writing, a page that could show a person their old words after saving a Markdown text, background work on a zone that could not build the app's public address, and requests answered "nothing is routed here" while an app moved between runtimes. A call refused by an organisation's policy or its host lists now answers 403 with a short message. A commit that writes many Markdown documents is checked in time proportional to their number, and a runtime's first start throws far fewer exceptions. In Osyrin Cloud's Admin, a policy's outbound hosts are edited, compared and approved on the Policies tab. A few things that ran before now answer differently; each has its fix beside it. To upgrade, run osy upgrade, then osy update in a project.
Breaking changes
- A call refused by your organisation answers 403, not 500. A call refused by the organisation's policy or by its two host lists in Admin answers 403 at a REST endpoint and a page call, and a tool error with code
deniedat an MCP tool, where it answered 500 or a generic error. This holds insideParalleland a blocking wait too. In the app, a caught refusal'se.TypeisPolicyRefused; a refusal by the host lists wasInvalidOperationException. When anotherParallelleg fails with a real fault beside the refusal, the caller gets the 403 and the fault is logged at Error with its stack. Who sees a difference: an app in an organisation whose host lists or policy refuse one of its outbound calls. Fix: test forPolicyRefused, or for 403, where you tested forInvalidOperationExceptionor 500. - A refusal's message says less. What an app's
catch,Http.Refusaland a signed-in caller receive says what was refused, that your organisation (or its policy) does not allow it, and the policy's reason. It no longer lists the organisation's allowed hosts, nor names the organisation, the policy's version, who set it or when, nor says how to change it. A caller with no account is told only "Operation not permitted.". The full sentence is written to the platform log underOsy.PolicyRefusal, at Warning, on release hosts too; identical refusals are written once and then counted per minute. Fix: read the platform log for the full sentence, not the message. - A page function paused inside a
catchblock cannot be resumed by an older release. After a rollback, or while an app moves between releases, such a pause fails and the person starts that step again. Fix: none needed.
Runtime
throw;works after a resume. After a page's call into the browser or a workflow wait, athrow;in acatchbody rethrows what was caught; it answered 400 "throw;… ran with no exception in flight". A refusal kept across such a wait is still a refusal when the function resumes.
Fixes
- Rows written while a page saves are no longer lost. A row that a stream or another flow wrote while a page's changes were being committed could be cleared without being written. It is now written by the next commit, keeping who wrote each column. A delete from another flow during a commit waits until the commit has finished, and a change the committing flow itself makes to a row it has just written goes into the next commit.
- A page that saves a Markdown text and shows it again in the same session now shows the new text. Before, it could show the text as it was when the row was created.
- A row with a Markdown text that is made, given its text and deleted in one call now leaves nothing. Before, it failed with a permission error about creating the text's sections.
- Background work on a zone now sees the app's public address in
App.BaseUrl. Scheduled jobs and workflow steps on a zone runtime readApp.BaseUrlas the placement's public address. Before, it was built on nothing there, so mail links built in background work failed (for example, the notification kit's hourly digest). - A request that arrives while an app moves between runtimes now waits for the new runtime instead of being answered "nothing is routed here".
- An app's first deploy on a zone no longer goes briefly unrouted before it is assigned.
- A rare crash (exit 139) at a runtime's first start, while it compiled Osy#, no longer reproduces. The code that turns functions into browser code is split into smaller methods, and it no longer throws an exception for each function that cannot run in the browser.
Performance
- A commit that writes many Markdown documents is checked in time proportional to their number. Before, the cost grew with the square of the number of documents.
- A runtime's first start throws far fewer exceptions. Compiling an app no longer throws an exception for each function that cannot run in the browser, and checking a time-zone name no longer throws for an ordinary string.
- Checking a large app allocates less memory. The checks walk each function body without allocating per node, look functions up by name in an index, and share one index of the app's entities between all its function bodies. On Admin,
osy validateallocated about a fifth less.
Osyrin Cloud
- Admin's policy editor. A policy's allowed and blocked outbound hosts can be edited, reviewed and saved as a draft on the Policies tab. The editor shows what a draft changes and the exact text its hash is taken over, compares your edits with a colleague's when they saved first, can save and approve in one step where you may approve, and sets the day a version comes into force; a day before today is refused. A save never replaces a draft someone else approved or saved meanwhile.
- A version in force whose rules cannot be found is shown as in force.
POST /organizations/policy/in-forcegainsrulesMissingand answersinForce: truefor that version, where it answeredinForce: false. Admin's Policies tab says the version is in force, its rules could not be read, and every outbound call of the organisation's applications is refused until a new version is approved. - Saving a policy draft names the draft it was based on.
POST /organizations/policy/draftand/policy/reverttakebasedOnHash, the content hash of the open draft read before editing, and answer 409 if someone else changed the draft in the meantime; abasedOnRevisionother than 0 withoutbasedOnHashis a 400. A new read,POST /organizations/policy/draft-state, gives the open draft's state and its hash. - Changing how many approvals a policy version needs takes an optional
was.POST /organizations/policy/approvals-neededanswers 409 when the number has moved since then, or when two changes land at the same moment. - Admin's navigation rail runs the full height of the window at its left edge.