Skip to content

Delete the Collaboration tab, membership store and service, and the Pro plugin from core #3331

Closed as not planned

Description

@mstomar125

Summary

Delete the Pro collection-membership surface from core:

The Pro frontend in nodespace-sync owns its own copies (SYNC counterpart (a) on the parent). The change only deletes code: about 1,450 source lines and 770 test lines.

Context

Line numbers are at main @ af8ddb6, so locate code by symbol. Paths are under packages/desktop-app/src. This describes the state after #3316, #3325 and #3329.

lib/plugins/pro-plugin.ts (lines 1-99)

lib/components/collaboration/

File Lines Imports
collaboration-view.svelte 1-606 the membership store, Permission from membership-service, and proSync
collaboration-tab.svelte 1-15 the view
collaboration-locked.svelte 1-94 proSync, and resolveProSyncVariant from pro-sync-variant.svelte

#3325 deleted invitations-inbox.svelte and its test.

The membership store and service

Design-token baseline

packages/desktop-app/design-tokens-baseline.json has four entries for these files:

  • three for collaboration-locked.svelte: #1d4ed8, #2563eb and #ffffff;
  • one for collaboration-view.svelte: #fff.

quality:design-tokens fails on stale entries. It runs in quality:fix, in quality:check, and in the push-time lint (scripts/test-gate.ts).

Preconditions

Verify these before starting. The dependencies guarantee them; if one fails, an upstream issue has not merged.

Scope

Source files to delete

All under packages/desktop-app/src/lib:

File Lines at af8ddb6
plugins/pro-plugin.ts 1-99
components/collaboration/collaboration-view.svelte 1-606
components/collaboration/collaboration-tab.svelte 1-15
components/collaboration/collaboration-locked.svelte 1-94
stores/membership.svelte.ts 1-375
services/membership-service.ts everything that remains after #3325

The components/collaboration/ directory goes entirely.

Test files to delete

All under packages/desktop-app/src/tests:

File Lines at af8ddb6
components/collaboration-view.test.ts 1-331
stores/membership.test.ts 1-261
services/membership-service.test.ts 1-181

Tests that #3316 left importing pro-plugin.ts

tests/plugins/pro-sync-variant.test.ts:

tests/free-user-guardrail.test.ts:

Design tokens

Run bun run --cwd packages/desktop-app quality:design-tokens --update. The diff must remove exactly the four entries listed under Context.

Ratchet

Run bun run scripts/check-pro-boundary.ts and paste the printed BASELINES. proNamedFiles drops by 1, for pro-plugin.ts.

Follow-up issue

Transfer core#3296, the open collaboration-view follow-up, to nodespace-sync:

gh issue transfer 3296 NodeSpaceAI/nodespace-sync --repo NodeSpaceAI/nodespace-core

Out of scope

Steps

  1. Startup, per core's CLAUDE.md:
    • On the primary checkout, run git status, then git fetch origin && git pull origin main.
    • Run EnterWorktree({name: "issue-<N>-remove-collaboration-ui"}).
    • Inside the worktree, run bun install, then bun run test for the baseline.
    • Run bun run gh:comment <N> "Frontend: X passed", bun run gh:assign <N> "@me" and bun run gh:status <N> "In Progress".
  2. Run the precondition searches. Stop if any of them fails.
  3. git rm the source and test files listed under Scope.
  4. Edit the two tests that import pro-plugin.ts.
  5. Re-record the design-token baseline.
  6. Run bun run --cwd packages/desktop-app quality:fix. svelte-check and ESLint fail on any missed import of a deleted module, and on any unused import.
  7. Run the ratchet and paste BASELINES.
  8. Transfer core#3296.
  9. Finish:
    • Run bun run test:changed, then commit.
    • Run git push origin HEAD:issue-<N>-remove-collaboration-ui.
    • Run gh pr create --repo NodeSpaceAI/nodespace-core --base main --head issue-<N>-remove-collaboration-ui, then bun run gh:status <N> "In Review".
    • Run /pragmatic-code-review, then /address-review.
    • Merge only after the user approves. Run bun run merge <PR#> in the background, then ExitWorktree.

Standards:

  • Run tests with bun run test, never bun test.
  • No lint suppression.

Acceptance criteria

  • All files listed under Scope are deleted.
  • This search finds nothing, apart from Stop importing the Pro extension in core; register it only through the build entry #3316's boundary guard if it names pro-plugin: rg -n 'membership-service|stores/membership|components/collaboration|pro-plugin|proSyncUiExtension|membershipService|pro_list_members|pro_set_member|pro_current_person|pro_list_joinable_collections' packages/desktop-app/src
  • No test imports $lib/plugins/pro-plugin.
  • In the free app, the collection viewer shows no tab strip, as before.
  • design-tokens-baseline.json has no collaboration-locked.svelte or collaboration-view.svelte entry, and bun run --cwd packages/desktop-app quality:design-tokens passes.
  • BASELINES in scripts/check-pro-boundary.ts is lowered to the printed counts, and bun run scripts/check-pro-boundary.ts exits 0.
  • core#3296 is in nodespace-sync.
  • bun run test and bun run --cwd packages/desktop-app quality:fix pass.

Tests and verification

  • bun run --cwd packages/desktop-app quality:fix
  • bun run --cwd packages/desktop-app test src/tests/plugins src/tests/free-user-guardrail.test.ts
  • bun run test, then bun run test:changed.
  • Free-app check: run bun run tauri:dev with an isolated NODESPACE_HOME. Open a collection page. It shows no tab strip, and nothing new appears in the console.
  • Pro check, in nodespace-sync's pin-bump PR, with SYNC counterpart (a) from the parent: open a collection's Collaboration tab. The roster loads, and adding a member, creating an invite and accepting an invite all work.

Dependencies

Risks and rollback

  • A missed importer breaks svelte-check or the Vite build. quality:fix and the merge gate catch it before merge.
  • A Pro build at a pin past this commit must inject its own Pro frontend.
  • Rollback: revert the PR. It restores files that core no longer uses.

Plan key: C6.4a (pro-boundary DAG).

🤖 Generated with Claude Code

Metadata

Metadata

Assignees

Labels

pro-boundary

Type

No type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions