Skip to content

v0.2.1

Choose a tag to compare

@osmaczko osmaczko released this 31 Jul 06:33
8945260

This release reshapes init around a ChatConfig record, moves instance storage under the host-assigned persistence path, and adds pending invites to a conversation's roster.

Features

  • Store instance state under the host-assigned persistence path (#51). init no longer takes an instance path: the module writes under the directory its host assigned it. An absent or empty path fails init with a message naming the fix, rather than falling back to a location of the module's own choosing.
  • Let the delivery node pick its own port (#53). init no longer takes a TCP port. A host running several instances no longer has to invent a port scheme and thread it through calls, docs and tests.
  • Report a conversation's roster with its pending invites (#56). GroupMember gains pending, true for an invite this instance sent that the group has not committed yet; pending members are listed after committed ones and the flag clears when the commit lands. list_group_members now answers for a direct conversation too, reporting both participants.
  • Make the chat core audible, and answer whether the module is still there (#60). ChatConfig carries an optional log_level (error | warn | info | debug | trace, default info), read once at init. get_log_path() returns the file this module is writing its log to; health() answers without init or any lock held, so a caller learns whether the module answered at all.

Contract

init takes a single ChatConfig record (? delivery_preset, ? log_level) in place of the former instance_path, delivery_preset and tcp_port arguments. list_group_members widens to direct conversations, and GroupMember carries pending.

Changes & dependencies

  • delivery_module is declared by name, without a version constraint (#62). A constraint has to be written as an object entry, which a host built before logos-module 9fb81c5 reads as an empty name and skips, loading this module without the dependency it names. The constraint goes back once every reader has the fix.
  • The module builder is held at its 0.2.6 release (#61, #62) rather than tracking master, whose logos-rust-sdk emits declared records as typed Rust structs this module's providers are not written against.
  • CI reads and writes the Nix cache through Attic rather than Cachix (#57).