Skip to content

Get deepnote sync and publish ready for the editor and agents #543

Description

@jamesbhobbs

The VS Code / Cursor extension (deepnote/vscode-deepnote) and coding agents are going to drive deepnote sync and deepnote publish. Today they can't do that reliably. This issue collects the CLI changes they need.

Current state

  • @deepnote/cli@0.8.0 on npm has no publish or static-site access; they exist only on main. deepnote streamlit publish is still in feat(cli): add deepnote streamlit publish #466.
  • publish and static-site access output only human-readable text. -q hides the URL (packages/cli/src/commands/publish.ts:327-347).
  • publish needs --project-id. No command lists projects or returns their ids.
  • sync always covers every project in the workspace. There is no per-project filter.
  • Only sync, run and schedule read .env, each from its own folder. publish, static-site access and streamlit publish don't read it.
  • Nothing creates a starter app. A static app is just a folder that publish uploads.

Tasks

  • Release @deepnote/cli, @deepnote/cloud and @deepnote/mcp with publish, static-site access and streamlit publish, once feat(cli): add deepnote streamlit publish #466 merges.
  • Add -o json to publish, static-site access and streamlit publish:
    • Static: {url, projectId, apiAccess, filesUploaded, pruned}
    • Streamlit: {appId, url, status}
    • A divergence ("Deepnote changed these files since the last sync") gets its own error code or exit code, so callers can offer "sync first" or "force".
  • Look up DEEPNOTE_TOKEN in .env the same way for every command that needs a token: the command's folder first, then parent folders up to the sync root. The missing-token error should tell the user to add DEEPNOTE_TOKEN to .env.
  • Make --project-id optional for publish and streamlit publish. When the folder is inside a synced project, take the id from .deepnote-sync.json or from the .deepnote file's project id.
  • Add deepnote projects list -o json, returning id, name, folder path and URL.
  • Add deepnote sync --project <id|path> to sync a single project. This is separate from the speed-up in feat(cli,cloud): sync projects concurrently and retry rate-limited requests #535.
  • Add deepnote app init <dir> --template static|ts|streamlit, which creates a starter app. The TS template builds to a folder that publish can upload. The extension and agents will share these templates.
  • Update skills/deepnote/references/{cli-publish,cli-sync,apps}.md and docs/, as AGENTS.md requires.

Done when

An agent with no TTY and only a .env file can do all of this without running --help or parsing text:

  1. Create an app.
  2. Sync one project.
  3. Publish the app.
  4. Get the URL back as JSON.

Unblocks the vscode-deepnote work on agent setup and on sync and publish buttons.

🤖 Generated with Claude Code

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Labels

No labels
No labels

Type

No type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions