Changelog
All notable changes to this project will be documented in this file.
The format is based on Keep a Changelog, and this project adheres to Semantic Versioning.
[Unreleased]
[1.5.0] - 2026-07-13
Commands that could not finish their work used to exit 0. They now exit nonzero, which will surface failures a script or CI step previously ran past. See Changed.
Changed
- Package commands exit nonzero when their work did not complete, and report a non-success
statusin--format json/stata.install,lock,outdated,add,updateanddepsall treated a resolve, install or version-check failure as a warning and exited 0 (#94). stacy.tomlrejects unknown keys, naming the offending one. A misplaced or misspelled key — a dependency under[dependencies]instead of[packages.dependencies], a typo’dverisonpin — was dropped without a word (#100).[packages] ado_diris rejected along with them. Nothing has ever read it; local ado directories are[paths] ado. Remove the key if yourstacy.tomlcarries it (#100).stacy installno longer writesstacy.lock. It installs the pinned version and fails when the source no longer serves it, instead of re-resolving and moving the pin. SSC serves only the current revision, so a cold-cache install of a superseded pin now fails rather than silently installing something else (#96).stacy runchecks every locked package against the cache before starting Stata and fails on a missing or modified one.run --no-verifyskips the check (#97).- A successful run removes its log in every output format.
--format json/statakept it, so each in-Statastacy_runleft one behind (#98).
Fixed
stacy runno longer drops streamed output that looks like a command echo. Echo detection ran on the trimmed line, so indented result lines went with it: every data row oflist, the missing-value row oftabulate, missing,display "1. step". The log was never affected (#95).[run] log_diris honored. Per-script logs were written to the project root and kept after a successful run (#98).stacy envchecks the cache before calling a locked package installed. A cold cache reported every package as installed (#99).stacy add <name> --source local:<dir>requires the directory to hold the named package instead of installing whatever it contains (#100).stacy doctorno longer reports a package’s own shipped files as missing dependencies. ftools’ internal.matafiles were listed as missing SSC packages, with astacy addtip that could not work (#101).- A task that defines no work — a table without
scriptorparallel(e.g. a typo’d key, which TOML parsing silently drops) or an empty array — now fails with a config error instead of succeeding as a no-op (#92).
[1.4.0] - 2026-07-13
Added
- Post-install dependency hints now also read the
Requires:line of a package’s.pkgmanifest, catching author-declared SSC dependencies that static.adoscanning misses (#78). stacy addwarns when a package’s manifest declares a newer minimum Stata version than the one stacy last detected (#82).stacy test -C <dir>/--directoryand--cd: control the test working directory, matchingstacy run(#85).
Changed
stacy testruns tests with the project root as the working directory regardless of where it’s invoked (previously the inherited directory) (#85).
Fixed
.pkgmanifests with bare\r(classic-Mac) line endings no longer parse as a title with no files (#79).stacy taskfrom the Stata console no longer fails withr(199): machine-readable formats no longer stream script output to stdout (#84).- Line breaks in
--format statastring values are replaced with spaces.
[1.3.1] - 2026-07-10
Added
stacy lock --refresh: recompute lockfile checksums from the installed cache.
Fixed
- Packages whose
.pkgmanifest lists a file twice (e.g. reghdfe) no longer fail checksum verification (#68). Runstacy lock --refreshto repair lockfile entries recorded by older versions.
[1.3.0] - 2026-07-09
Changed
stacy runstreams program output to stdout live in piped mode, likeRscript(#24). Same content as before, just live; status and errors stay on stderr.stacy taskstreams too.- The log file is now internal: removed on success, kept on failure. Machine-readable formats keep it. Use
--log <path>for a durable artifact. --parallelprints each script’s output as a grouped block on completion instead of discarding it.
Added
stacy run --log <path>: write the raw Stata log to a chosen path (works with--quietfor silent file-artifact mode).
Removed
- Dead
log_reader::is_successful_completion(unused since the streaming rework, #65).
Fixed
- Task arrays accept script paths:
all = ["clean", "src/02_analyze.do"](#64). - Post-install hints comma-separate package names (#63).
- Failure context no longer loads the entire log into memory (#66).
- Log streaming no longer hangs when Stata is killed or fails to launch, recovers from truncated logs, and survives closed pipes (
| head). --traceno longer leaks its temp script and log.
[1.2.1] - 2026-05-06
Added
- Stata wrappers now verify that the
stacybinary they invoke is version-compatible (#35). On mismatch,_stacy_execaborts with a clear error and astacy_setup, forcehint instead of silently running against a stale binary. The check shells out once per Stata session (cached in$stacy_version_checked).
Fixed
- Surface Stata’s stderr on launch failures instead of the misleading “Log file incomplete” (#21). Distinguish “no log produced” (launch failure) from “log truncated” (killed mid-run).
stacy install --format stata(and--format json) no longer emits a success-shaped block when checksum verification fails (#38). Status is now computed before output, so wrappers seeglobal stacy_status "error"plusglobal stacy_error "<msg>"(and JSON gets matchingstatus/error/failedfields) instead of a stale success preceding the non-zero exit.- Stata wrappers failed with
command _stacy_check_version is unrecognizedbecause the generated_stacy_compat.adodefined programs that didn’t match its filename and wasn’t listed instacy.pkg(#37). Split into one file per program. - Parallel
stacy runinvocations on scripts that share a basename no longer collide on the log file (#20). Each run writes to a uniquely-named log in the working directory (<stem>_<pid>_<nanos>_<n>.log), so build orchestrators like Make-jand Snakemake can run same-stemmed scripts from a shared cwd safely. The path is reported in JSON output’slog_filefield. - Non-UTF-8 characters in Stata log files no longer crash the log parser
- Update check now compares against the running binary version, not a stale cached value
- Cargo upgrade instruction now shows correct crate name (
stacy, notstata-cli)
1.2.0 - 2026-03-15
Added
stacy run --timeout <seconds>to kill long-running scripts[paths]config section for project-local ado directories inS_ADO- Post-install dependency scanning: warn about missing implicit dependencies after
stacy addand instacy doctor - Package naming hints: suggest correct SSC package on 404 (e.g.
labmask→labutil) - Stata wrappers now expose all CLI flags (
AllowGlobal,Trace,Timeout,Parallel,Cache, etc.)
Changed
stacy initgenerates minimal config (no default values the user will delete)- Dependencies in
stacy.tomlsorted alphabetically stacy initandstacy addshow package cache location
Fixed
- Sync
commands.tomlschema with CLI (missing flags, stale args, missing exit code 6)
1.1.0 - 2026-02-22
Added
net:source type for arbitrary URL packages (stacy add grc1leg --source net:http://www.stata.com/users/vwiggins/)local:source type for vendored/local packages (stacy add myutils --source local:./lib/myutils/)- GitHub fallback: synthesize manifest from repository tree when
.pkgfile is missing - Post-install hints for packages with known implicit dependencies (reghdfe, ivreghdfe, ppmlhdfe, grstyle, etc.)
stacy doctornow surfaces available updates (reads version check cache)stacy depsnow parsesrequirestatements as package dependencies (includingcap requireandcapture require)
Changed
- Improved SSC error messages: distinguish “package not found” from “mirror gap” from “server unreachable”
1.0.2 - 2026-02-17
Fixed
- Fix SSC downloads always failing: use HTTP instead of HTTPS for
fmwww.bc.edu(the server does not support TLS, causing everystacy addfrom SSC to fall back to the GitHub mirror)
1.0.1 - 2026-02-16
Fixed
- Fix
net installfrom Stata: remove phantom files fromstacy.pkgthat caused r(601) - Fix
--format stataoutput: wrong global prefix, wrong quoting, bare types in syntax - Fix
stacy init--nameoption andstacy taskconfig section reference - Fix installation docs command name
Added
- 24 tests for
--format stataoutput and codegen correctness
Changed
- Regenerate all Stata wrappers with fixes
- Align docs and README with paper framing
1.0.0 - 2026-02-15
Initial public release.
Added
stacy run— Execute Stata scripts with proper error detection and exit codesstacy run -c— Run inline Stata codestacy run --parallel— Parallel execution of multiple scriptsstacy init— Initialize project withstacy.tomlstacy add/stacy remove— Manage dependenciesstacy install— Reproducible installs from lockfilestacy update/stacy outdated— Keep packages currentstacy lock— Generate and verify lockfilestacy task— Task runner (npm-style scripts instacy.toml)stacy deps— Script dependency analysisstacy env/stacy doctor— Environment diagnosticsstacy explain— Error code lookup- Error codes dynamically extracted from user’s Stata installation
- SSC and GitHub package sources (
github:user/repo@tag) - Global package cache at
~/.cache/stacy/packages/ --format jsonand--format stataoutput modes- Cross-platform support: macOS, Linux, Windows