Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

chat: room lifecycle specification #200

Draft
wants to merge 52 commits into
base: main
Choose a base branch
from
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
52 commits
Select commit Hold shift + click to select a range
a6ffe20
build: clean output directory on build
AndyTWF Aug 5, 2024
fd5c535
chat: chat room lifecycle feature specification
AndyTWF Aug 5, 2024
3b8937a
chat: remove protocol page
AndyTWF Aug 14, 2024
bcb7390
chat: add spec points clarifying release behaviour
AndyTWF Sep 3, 2024
3948180
chat: various clarifications on room lifecycle
AndyTWF Sep 13, 2024
d8ec6b1
chat: add messages specification
AndyTWF Sep 13, 2024
b4a495e
chat: add presence and ephemeral room reactions spec
AndyTWF Sep 13, 2024
1520300
add typing indicators spec
AndyTWF Oct 11, 2024
e3b9269
add CHA-PR9 for presence permissions
AndyTWF Oct 11, 2024
72ec8f6
Add typing event struct for chat
AndyTWF Oct 11, 2024
4ea5d67
clarify presence get behaviour
AndyTWF Oct 11, 2024
d4f5a28
additional chat room lifecycle clarifications
AndyTWF Oct 11, 2024
775be32
chat: clarify room lifecycle operation precedence
AndyTWF Oct 18, 2024
bd04eda
chat: add occupancy spec
AndyTWF Oct 18, 2024
6118c46
materialization: Remove reserved namespace from metadata and headers.
splindsay-92 Oct 23, 2024
1bc094c
Restore CHA-M3e
lawrence-forooghian Oct 30, 2024
0e5ab98
Update duplicate-finding script to handle Chat too
lawrence-forooghian Sep 17, 2024
9d8cb43
Restore IDs of deleted spec points
lawrence-forooghian Oct 30, 2024
2e57965
Don’t mark deleted clauses as Testable
lawrence-forooghian Oct 30, 2024
d8712a8
Fix language for replaced spec points
lawrence-forooghian Oct 30, 2024
8426fa0
clarify status codes accompanying chat specific errors
AndyTWF Oct 31, 2024
d46da47
clarify CHA-RL1h2 error
AndyTWF Oct 31, 2024
bb39916
CHA-RL1h4: remove duplicate text
AndyTWF Oct 31, 2024
179c8d8
CHA-RL2h1: clarify failed state entry
AndyTWF Oct 31, 2024
cfa6ae3
CHA-RL2h: clarify detach failure
AndyTWF Oct 31, 2024
dfee31d
CHA-RL2h1: clarify meaning of detachment
AndyTWF Oct 31, 2024
3192b53
CHA-RL2h1: clarify error usage
AndyTWF Oct 31, 2024
7db0bb4
CHA-RL2h3: clarify relation to CHA-RL2f
AndyTWF Oct 31, 2024
225c775
CHA-RL2h3: specify pause duration
AndyTWF Oct 31, 2024
1573765
CHA-RL3d: make statement a MUST
AndyTWF Oct 31, 2024
c46c6a2
CHA-RL3f: specify delay
AndyTWF Oct 31, 2024
dbe3fd8
CHA-RL3f: clarify relation to CHA-RL3d
AndyTWF Oct 31, 2024
6e4b890
CHA-RL3f: clarify relation to CHA-RL3g
AndyTWF Oct 31, 2024
ed15dd0
CHA-RL3g: clarify what constitutes a terminal condition
AndyTWF Oct 31, 2024
2d4edd2
CHA-RL1h1: make non-testable
AndyTWF Oct 31, 2024
c5232bf
chat: fix typo in resumed flag
AndyTWF Oct 31, 2024
da02c3b
CHA-RL4a2: clarify when a channel is deemed to have attached once
AndyTWF Oct 31, 2024
ab2bf98
CHA-RL4b1: clarify relation to CHA-RL1f
AndyTWF Oct 31, 2024
ba73e2f
CHA-RL4b4: link to CHA-RL1f
AndyTWF Oct 31, 2024
c0c6925
CHA-RL4b7: clarify transient disconnect timeouts
AndyTWF Oct 31, 2024
7a9a9ec
CHA-RL4b*: change channel lifecycle to room lifecycle
AndyTWF Oct 31, 2024
9a97301
CHA-RL4b: specify non-update events
AndyTWF Oct 31, 2024
6f4dd6d
CHA-RL4b2 remove from spec
AndyTWF Oct 31, 2024
e0c8251
CHA-RL4b3/4: remove
AndyTWF Oct 31, 2024
36fa661
CHA-RL4a1/2: relate to CHA-RL4a3/4
AndyTWF Oct 31, 2024
985d87a
CHA-RL4b6: remove specification point
AndyTWF Oct 31, 2024
ca0d985
CHA-RL4b5: link to CHA-RL2f
AndyTWF Oct 31, 2024
77f9970
CHA-RL1g2: add double notification clause
AndyTWF Oct 31, 2024
013d156
CHA-RL4a3: prefer first discontinuity event
AndyTWF Oct 31, 2024
ea7a8c9
CHA-RL5b: add wait time
AndyTWF Nov 4, 2024
ce68bb9
chat: link retry loop failure to detach
AndyTWF Nov 4, 2024
ef45469
CHA-RL5e: clarify error source
AndyTWF Nov 5, 2024
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 2 additions & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,8 @@
"name": "@ably/specification-build",
"version": "1.0.0",
"scripts": {
"build": "npm-run-all build:generate build:tailwind",
"clean": "rm -rf ./output",
"build": "npm-run-all clean build:generate build:tailwind",
"build:generate": "./scripts/build",
"build:tailwind": "tailwindcss -i ./templates/main.css -o ./output/tailwind.css --minify",
"lint": "npm-run-all format:*:check",
Expand Down
41 changes: 27 additions & 14 deletions scripts/find-duplicate-spec-items
Original file line number Diff line number Diff line change
Expand Up @@ -3,20 +3,33 @@
# Script to detect duplicate spec IDs in the client library spec
# This tends to happen when concurrent spec PRs are merged

SPEC_PATH = File.expand_path('../../textile/features.textile', __FILE__)

File.read(SPEC_PATH).scan(/\*\s\@\((\w+)\)\@/).group_by do |match|
match
end.select do |spec_id, matches|
matches.count > 1
end.each do |spec_id, matches|
puts "#{spec_id.first} has #{matches.count - 1} duplicate(s)"
end.tap do |matches|
if matches.empty?
puts "✓ Spec is valid. No duplicates found"
else
puts "\n✘ INVALID SPEC: #{matches.count} duplicate(s) found"
exit 1
SPEC_FILES = ["features", "chat-features"]

has_errors = false

SPEC_FILES.each_with_index do |spec_file, i|
file_name = "#{spec_file}.textile"

puts "Checking #{file_name}"

spec_path = File.expand_path("../../textile/#{file_name}", __FILE__)

File.read(spec_path).scan(/\*\s\@\(([\w-]+)\)\@/).group_by do |match|
match
end.select do |spec_id, matches|
matches.count > 1
end.each do |spec_id, matches|
puts "#{spec_id.first} has #{matches.count - 1} duplicate(s)"
end.tap do |matches|
if matches.empty?
puts "✓ Spec is valid. No duplicates found"
else
puts "\n✘ INVALID SPEC: #{matches.count} duplicate(s) found"
has_errors = true
end
end

puts if i < SPEC_FILES.count - 1
end

exit 1 if has_errors
Loading
Loading