Skip to content

Cloud

fw data pull

data pull

Bring the project's data catalog up to date with Framework Cloud

Added in 0.5.1.

Reads the project's data registry on Framework Cloud with its project token (FW_PROJECT_TOKEN in .env), lists the changes, and asks before applying them: entries to add, entries whose definition differs, and entries only in this project. Applying writes the new entries into the settings' data section. Local entries are never removed, and local definitions are kept; --overwrite uses Framework Cloud's instead.

Without a terminal, pass --yes to apply or --dry-run to only list the changes. In R and Python projects, fw runs the language package's pull_data_registry().

Usage

fw data pull [flags]

Options

Name Type Description
--dry-run bool

list the changes without applying them

--json bool

print JSON on stdout, for scripts and agents (Stata projects)

--overwrite bool

use Framework Cloud's definitions over local edits

-y, --yes bool

apply without asking (required without a terminal)

Value

With --json, for Stata projects, {"revision", "entries", "applied", "dry_run", "message"}, matching pull_data_registry(): entries lists added, changed, differ_kept, and kept_local. R and Python projects print their package's summary.

Exit codes

Code Meaning
0 Success
1 Failure
2 Bad flags or arguments
3 Not logged in, or the server rejected the token
4 The server has no such project or resource
5 Browser login was denied, or its code expired
6 An upload has "private" in a path; rerun with --include-private if you mean to send it

With --json, a failure also prints one JSON line on stderr: {"error": "...", "exit_code": 4}. Exit code 6 adds "reason": "private_path".

Examples

fw data pull --dry-run
fw data pull
fw data pull --yes --overwrite

Related reference

Search guides and reference for R, Python, Stata, the CLI, and Framework Cloud.