Open
Conversation
…ations, and associated logic
…d app activity charts
…e.json to set private to false; remove unused dependencies from package.json and yarn.lock
…rom backend GraphQL mutations
…for clean table drops
Keep transferOrganisationOwnership mutation from main, drop removed KMS types (KMSLogType, RotateAppKeysMutation, ChartDataPointType, TimeRange) and regenerate frontend types. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
🔍 Overview
The Phase Console codebase contains a legacy KMS (Key Management Service) product that pre-dates the current secrets management platform. This legacy product included a KMS REST endpoint for serving wrapped key shares, Cloudflare KV for edge caching those shares, DynamoDB/PynamoDB for KMS access logging, and related frontend UI (KMS logs panel, KMS tokens panel, rotate app keys). None of this is used by the current secrets management product and adds unnecessary complexity, dead code, and unused dependencies.
💡 Proposed Changes
Backend
/kms/<app_id>) and theapi/views/kms.pyviewbackend/api/kv.py) — write/delete/purge operations forkms.phase.devedge caching. Note: Cloudflare Workers/Pages syncing integrations (current product feature) are untouchedKMSLogType,ChartDataPointType,TimeRange,KMSLogsResponseType,kms_logsquery,app_activity_chartquery, and their resolvers fromschema.pyandtypes.pyRotateAppKeysMutation— only used by the legacy KMS panelDeleteAppMutationandApp.save()override (KV write on save)DYNAMODBandCLOUDFLAREconfig blocks fromsettings.pybackend/logs/as a minimal app with only migrations preserved (including a new0009_delete_kmsdblogmigration) to ensure existing deployments can cleanly drop thekmsdblogtablepynamodb, Twisted ecosystem (9 packages),pyOpenSSL,async-timeout,autopep8,pycodestyleapp_token,wrapped_key_share, etc. remain in the schemaFrontend
KmsLogs.tsx,getAppKmsLogs.gql,rotateAppKeys.gql,getAppActivityChart.gqlSecretLogsKmsPanel,RotateAppDialog, and panel switcher sidebar; now renders onlySecretTokensDeleteAppDialogwarning text to reference secrets instead of KMS keysinstall,jsonwebtoken,@types/jsonwebtoken📝 Release Notes
kmsdblogtable on existing deployments❓ Open Questions
🧪 Testing
python manage.py checkpasses🎯 Reviewer Focus
backend/backend/graphene/mutations/app.py— removal ofRotateAppKeysMutationand KV operations fromDeleteAppMutationbackend/backend/schema.py— removal of KMS query fields and resolversfrontend/app/[team]/apps/[app]/access/tokens/page.tsx— simplified from dual-panel to singleSecretTokensviewbackend/logs/migrations/0009_delete_kmsdblog.py— migration to drop the legacy table➕ Additional Context
ServiceTokenmodel, frontend service tokens tab) are kept and will be phased out separatelyapp_token,wrapped_key_share,app_seed,app_version) are preserved — no DB schema changes to the App table✨ How to Test the Changes Locally
docker compose -f dev-docker-compose.yml up --build💚 Did You...