diff --git a/AGENTS.md b/AGENTS.md index 7975f3e..f17ce7c 100644 --- a/AGENTS.md +++ b/AGENTS.md @@ -22,17 +22,12 @@ server. ## Workflow -- Use `todo.txt` as the source of truth for staged work. -- Preserve the todo status markers: - - `-` means open. - - `+` means implemented, needs testing. - - `X` means tested and done. -- Work in small batches and update `todo.txt` only for items actually completed - or tested. -- Before beginning a new phase or section, review all earlier `+` and `X` - sections in `todo.txt`; confirm their status still matches the code, tests, - docs, and user-facing surfaces, and downgrade stale `X` markers when evidence - no longer supports them. +- Skald is production software; prefer small, scoped maintenance changes with + focused verification. +- Use a temporary local plan file only for large or risky batches that need a + resumable checklist. +- Building the Arch package updates `distro-packages/Arch-Linux/skald-git/PKGBUILD` + with the generated `pkgver`, so this file is often dirty after package builds. - Keep changes scoped to the current batch. Do not mix in unrelated cleanup. - Before behavior changes, inspect the current code path and tests rather than assuming Galene behavior still applies. diff --git a/distro-packages/Arch-Linux/skald-git/PKGBUILD b/distro-packages/Arch-Linux/skald-git/PKGBUILD index b5db99c..7307cd6 100644 --- a/distro-packages/Arch-Linux/skald-git/PKGBUILD +++ b/distro-packages/Arch-Linux/skald-git/PKGBUILD @@ -2,7 +2,7 @@ # shellcheck shell=bash disable=SC2034,SC2154 pkgname=skald-git -pkgver=2026.07.08 +pkgver=2026.07.08.r0.g9a9742e pkgrel=1 pkgdesc='Audio-only hall-based conferencing server' arch=('x86_64' 'aarch64') diff --git a/hall/description.go b/hall/description.go index aa1144c..b25b2ca 100644 --- a/hall/description.go +++ b/hall/description.go @@ -34,11 +34,10 @@ type Permissions struct { } var permissionsMap = map[string][]string{ - "op": {"op", "present", "message", "caption", "token"}, + "op": {"op", "present", "message", "token"}, "present": {"present", "message"}, "message": {"message"}, "observe": {}, - "caption": {"caption"}, "admin": {"admin"}, } diff --git a/hall/hall_test.go b/hall/hall_test.go index 596ab42..02a14a8 100644 --- a/hall/hall_test.go +++ b/hall/hall_test.go @@ -396,8 +396,6 @@ var james = "james" var paul = "paul" var peter = "peter" var admin = "admin" -var stt = "speech-to-text" - var badClients = []ClientCredentials{ {Username: &jch, Password: "foo"}, {Username: &john, Password: "foo"}, @@ -418,9 +416,7 @@ var desc2JSON = ` "john": {"password": "secret", "permissions": "present"}, "james": {"password": "secret2", "permissions": "message"}, "peter": {"password": "secret4"}, - "admin": {"password": "admin", "permissions": "admin"}, - "speech-to-text": {"password": {"type": "wildcard"}, - "permissions": "caption"} + "admin": {"password": "admin", "permissions": "admin"} }, "wildcard-user": {"permissions": "message", "password": {"type":"wildcard"}} @@ -429,7 +425,7 @@ var desc2JSON = ` var goodClients = []credPerm{ { ClientCredentials{Username: &jch, Password: "topsecret"}, - []string{"op", "present", "message", "caption", "token"}, + []string{"op", "present", "message", "token"}, }, { ClientCredentials{Username: &john, Password: "secret"}, @@ -451,10 +447,6 @@ var goodClients = []credPerm{ ClientCredentials{Username: &admin, Password: "admin"}, []string{"admin"}, }, - { - ClientCredentials{Username: &stt}, - []string{"caption"}, - }, } func TestPermissions(t *testing.T) { @@ -513,7 +505,7 @@ func TestExtraPermissions(t *testing.T) { } } - doit("jch", []string{"op", "token", "present", "message", "caption"}) + doit("jch", []string{"op", "token", "present", "message"}) doit("john", []string{"present", "message"}) doit("james", []string{}) @@ -521,7 +513,7 @@ func TestExtraPermissions(t *testing.T) { d.UnrestrictedTokens = false doit("jch", []string{ - "op", "record", "token", "present", "message", "caption", + "op", "record", "token", "present", "message", }) doit("john", []string{"present", "message"}) doit("james", []string{}) @@ -529,7 +521,7 @@ func TestExtraPermissions(t *testing.T) { d.AllowRecording = false d.UnrestrictedTokens = true - doit("jch", []string{"op", "token", "present", "message", "caption"}) + doit("jch", []string{"op", "token", "present", "message"}) doit("john", []string{"token", "present", "message"}) doit("james", []string{}) @@ -537,7 +529,7 @@ func TestExtraPermissions(t *testing.T) { d.UnrestrictedTokens = true doit("jch", []string{ - "op", "record", "token", "present", "message", "caption", + "op", "record", "token", "present", "message", }) doit("john", []string{"token", "present", "message"}) doit("james", []string{}) diff --git a/rtpconn/webclient.go b/rtpconn/webclient.go index b2275eb..e386a6c 100644 --- a/rtpconn/webclient.go +++ b/rtpconn/webclient.go @@ -1606,11 +1606,7 @@ func handleClientMessage(c *webClient, m clientMessage) error { return c.error(hall.UserError("join a hall first")) } - required := "message" - if m.Type == "chat" && m.Kind == "caption" { - required = "caption" - } - if !member(required, c.permissions) { + if !member("message", c.permissions) { return c.error(hall.UserError("not authorised")) } diff --git a/skald-protocol.md b/skald-protocol.md index eb26da9..08b4b07 100644 --- a/skald-protocol.md +++ b/skald-protocol.md @@ -306,7 +306,7 @@ A chat message may be sent using a `chat` message. ```javascript { type: 'chat', - kind: null or 'me' or 'caption', + kind: null or 'me', source: source-id, username: username, dest: dest-id, @@ -320,9 +320,7 @@ A chat message may be sent using a `chat` message. The field `kind` can have one of the following values: - `null` or the empty string, a normal chat message; - - `'me'`, an IRC-style first-person message; - - `'caption'`, a caption or subtitle (this requires the sender to have - the `caption` permission). + - `'me'`, an IRC-style first-person message. If `dest` is empty, the message is a broadcast message, destined to all of the clients in the hall. If `source` is empty, then the message was diff --git a/skald.md b/skald.md index 17aaf7d..4895788 100644 --- a/skald.md +++ b/skald.md @@ -434,7 +434,6 @@ following strings: - `message`: a user with the right to send chat messages; - `observe`: a user that receives media streams and chat messages, but is not allowed to send them; - - `caption`: a user with the right to display captions (only); - `admin`: a user with the right to administer the hall (only). Usernames must be non-empty and unique among connected non-system clients in a diff --git a/skaldctl/skaldctl_test.go b/skaldctl/skaldctl_test.go index 0d2fb2d..3b45f25 100644 --- a/skaldctl/skaldctl_test.go +++ b/skaldctl/skaldctl_test.go @@ -97,7 +97,7 @@ func TestInteractiveHall(t *testing.T) { func TestFormatPermissions(t *testing.T) { tests := []struct{ j, v, p string }{ - {`"op"`, "op", "[cmopt]"}, + {`"op"`, "op", "[mopt]"}, {`"present"`, "present", "[mp]"}, {`"observe"`, "observe", "[]"}, {`"admin"`, "admin", "[a]"}, diff --git a/static/skald.css b/static/skald.css index 767295f..e51f16e 100644 --- a/static/skald.css +++ b/static/skald.css @@ -1220,26 +1220,6 @@ header .collapse:hover { } -#captions-container { - position: absolute; - bottom: 40px; - width: 100%; - pointer-events: none; - z-index: 1390; - alpha: 0; -} - -#captions { - margin: auto; - padding: 0 0.4rem 0 0.4rem; - width: max-content; - font-size: 1.2rem; - text-align: center; - pointer-events: none; - background-color: rgba(255,255,255,.7); - color: #000; -} - :root { --skald-menu-bg: #eee; --skald-menu-shadow: 1px 1px 1px #444; diff --git a/static/skald.html b/static/skald.html index 082ce37..9f5b1ad 100644 --- a/static/skald.html +++ b/static/skald.html @@ -84,9 +84,6 @@ -