A table call that arrived by sync makes a sound - #859
Merged
Merged
Conversation
"Call waiter" on the ordering page writes into the cloud database. The lane that brings it down was built tonight (Gateway "A call reaches the till", #853), and what arrived landed in the request dock silently: the dock polls, so the call showed within seconds, but the sound a counter-made call raises comes from the API's insert path, which a synced row never takes. A pulled call now rings the arrival bell once, the same treatment a synced-in order gets, and sends nothing to the kitchen printer. It does not ring until answered: that alarm needs the call's id so that "seen" can stop it, and the agent's line carries a count. What that next step needs is written beside the code.
scripts/check-installed-app.js declares a shebang and was committed 100644. cron or a deploy that calls it by path gets 'permission denied'. tests/executable-scripts.test.js has refused the suite over it since it landed; this is the mode bit, nothing else.
…call-makes-a-sound
Contributor
|
Merged to Try it at https://develop.posnic.io, or run it yourself: git fetch origin develop && git checkout develop
npm install && npm --prefix api install
npm run dev # then http://localhost:3000When you have tested it, say what you did and what happened, and set Reporting that something is broken is as useful as fixing it. It is |
This was referenced Sep 17, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What
The last gap in tonight's waiter-call lane. A call from the ordering page now reaches a till (Gateway #14, POS #853), but it landed in the request dock silently: the dock polls, so the call appeared within seconds, while the sound a counter-made call raises comes from the API's insert path, which a synced row never takes.
A pulled
waitercallsrow now rings the arrival bell once, exactly what a synced-in order gets from the same place (_announcePulled), taggedstate: 'waiter', and sends nothing to the kitchen printer; nobody cooks a call.What it deliberately does not do
It does not ring until answered. A counter-made call does, because the API knows the call's id and the dock's "seen" resolves that id. The agent's pull line carries a count, not ids, and the queue endpoint the dock reads sits behind
router.use(protect), so the repeating alarm for a synced call is a further step: a kiosk-keyed read of the open calls registered before the session guard, thenwaitingpercall_idandposnic:order-resolvedwhen a call leaves the list. Written beside the code so the bell is not mistaken for the alarm.Tests
tests/a-cloud-order-reaches-the-kitchen-at-once.test.js10/10: a pulled call makes exactly onereceivedsound withstate: 'waiter'and raises no kitchen-ticket event; "pulling anything else stays quiet" still holds. Desktop suite 2,895/2,896; the one failure (executable-scripts:scripts/check-installed-app.jscommitted non-executable) is already on develop and is fixed in its own PR.