~ knotless Search/
↑↓ move↵ open⇧↵ all results
0
0

A group's settings are changed from the console

Merged
Merged chadtmiller.com asked to merge into main from chadtmiller.com/group-host:host/group-settings

What changes

A group's settings (/g/<handle>/settings, linked from its page for its members), each part for whoever the group lets:

  • The profile: its name, words, how people join, and its own site (updateProfile). The profile is replaced whole, so what the form does not show (where it meets, online, topics, languages) is carried over as it is.
  • Rules: added and taken away (putRule, deleteRule).
  • Roles: defined, with what each may do, the roles its holders may give, and whether every new member gets it; and taken away (putRole, deleteRole).
  • The apps acting as the group (listGroupTokens): each grant, how it was given and whose it is, to end (revokeGroupToken), and the latest of the group's log.
  • App passwords (listAppPasswords): each to revoke, and a new one to make, shown once (createAppPassword, revokeAppPassword).

The first four are for its configurers. App passwords are for them and for whoever may make one. The host's refusals show on the page.

From the members pull's review:

  • The invite action uses act, as the others do.
  • getGroup reads its members' and requesters' DID documents at once rather than in turn (futures::future::join_all; futures joins the host's dependencies).

Why

Step 7's last part: a group is run from the console, start to finish. That completes the console's step in docs/design/README.md.

How it was checked

just e2e, four new flows (seventeen in all), passing locally:

  • the profile renamed, its words kept;
  • a rule added, shown on the group's page, and taken away;
  • a role defined with invite, and taken away;
  • an app password made, signed in with from outside (createSession), its session ended from the page, the password revoked, and signing in with it refused.

svelte-check, the layers and the build pass. The host's tests for getGroup pass. Local coverage was 100% at the members pull, and the change since is getGroup's concurrent reads.

Shortcomings

  • The profile's images, location, topics and languages are not yet edited here, only kept.
Approved

This adds the /g/<handle>/settings page. It covers the profile, rules, roles, the apps acting as the group, and app passwords. It also makes getGroup read DID documents concurrently and routes the invite action through act.

I found nothing that must change.

  • Images: the profile action doesn't carry avatar or banner over, but it doesn't need to. update_profile keeps an image that is left out, so "only kept" is true.
  • Concurrent reads: the join_all change keeps the order of members and requesters, because it zips the results back onto the same lists.
  • Page access: the page shows each part only to those the group lets, and the host enforces that anyway.

Two small things, neither blocking:

  • The new e2e flows depend on each other. "defining a role" and "making an app password" don't navigate and rely on the previous test's page. That works while the file runs serially, but it breaks if one flow is run on its own.
  • ACTIONS in web/src/lib/actions.ts is a hand-kept copy of the lexicon's action list. It will drift when an action is added.

I did not read the checks or run anything.

Merged as b1d6d0d