Skip to content

20261012 - cMeta v0.35.1: the home notice, notices on stdout, cache --duplicates, re-spacing - #57

Merged
gfursin merged 6 commits into
mainfrom
dev
Oct 12, 2026
Merged

gfursin merged 6 commits into
mainfrom
dev

Conversation

@gfursin

@gfursin gfursin commented Oct 12, 2026

Copy link
Copy Markdown
Member

cMeta v0.35.1. See CHANGELOG.md for the details.

  • A new home says where it is and what chose it. The command that sets up a new home prints one line,
    cMeta info: a new cMeta home is set up in <home> (chosen by ...), and cx --version has the line
    cMeta home chosen by: .... How the home is chosen does not change. New in cmeta.config: home_from_env()
    and home_choice(home).
  • The standard error is for errors only. The waiting for a lock, a registered repository that cannot be
    reached and a reference to a migrated artifact are cMeta warning: ... lines on the standard output now;
    errors stay on the standard error. New: utils.common.console_line().
  • cx cache show --duplicates / cx cache clean --duplicates. The usable entries that no request can tell
    apart, group by group, the newest first; clean keeps the newest of each group. An entry with a name of its
    own (a program's build workspace) is nobody's duplicate.
  • One empty line before a remark that starts a block, in 35 files: a formatting commit of its own, only
    empty lines added, checked to give the same syntax tree.

Tested: the full suite on Windows 11, Ubuntu 24.04 (Python 3.9, 3.14, free-threaded 3.14t), macOS and WSL2,
and in Docker images of Debian, Ubuntu, Fedora and Alpine (Python 3.9 to 3.15rc).

🤖 Generated with Claude Code

gfursin and others added 6 commits October 11, 2026 22:19
… use_soft_lock_under and the soft-lock settings)

Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
Signed-off-by: Grigori Fursin <gfursin@gmail.com>
A formatting change only: 90 empty lines in 35 files, nothing else. A remark (a comment) that starts a
block of related lines gets one empty line above it, so that the blocks of the code read apart.

Made by a tool and checked file by file:

- only empty lines are added: the files are the same once the empty lines are dropped;
- Python: the same syntax tree (ast) before and after; YAML: the same data;
- left alone: a remark that is the first line inside a block or after a continued line, a remark that
  closes the block above it (an empty line or less indented code follows), commented-out code, the text
  of PowerShell block comments, multi-line strings, here-documents and YAML block scalars.

The files of the website category are left out: they are being changed in another piece of work.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Signed-off-by: Grigori Fursin <gfursin@gmail.com>
…for errors only

The home is chosen as before: CMETA_HOME, else <VIRTUAL_ENV>/CMETA, else <CONDA_PREFIX>/CMETA, else
CMETA_HOME2, else ~/CMETA. Nothing of that changes. Inside a container image that exports VIRTUAL_ENV
the home is <environment>/CMETA, and whoever expected ~/CMETA copied files to a place nothing reads,
without a hint.

- The command that sets up a new home (no repos.json yet) prints one line of information, "cMeta info: a
  new cMeta home is set up in <home> (chosen by ...)"; without the console it only goes to the log.
- `cx --version` has the line "cMeta home chosen by: ..." after the home path.
- cmeta.config: home_from_env() gives the home and the variable, home_choice(home) the same in words;
  check_init_vars_from_env() uses the first.

Information and warnings go to the standard output, errors stay on the standard error ("cMeta notice:
<error>!"). Three warnings went to the standard error too and are now "cMeta warning: ..." lines on the
standard output, logged as before: a wait for a lock (after 3 s), a registered repository that cannot be
reached, and a reference to a migrated artifact. Tools that take any line on the standard error for a
failure (Windows PowerShell 5.1 with 2>&1, CI steps) no longer see one where there is none. New:
utils.common.console_line(message, kind).

Docs: a script asks `cx --version` for the home and `cx repo find <alias>` for a repository's folder;
error-handling.md says what goes where. Tests: tests/core_tests/test_config_home.py and the notices of
three existing tests.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Signed-off-by: Grigori Fursin <gfursin@gmail.com>
Two usable cache entries are duplicates when no request can tell them apart: the same name (the alias
without the UID at its end), task, tags (the state tags aside), parameters and path. A path inside the
entry's own folder - the tool_path of a tool installed into its entry - counts as the same in both. An
entry with a name of its own, such as the build workspace of a program, is found by that name and is
nobody's duplicate. Duplicates come from a run with --new, or from identical requests that ran at once
before cmeta-aops 0.45.

- `show --duplicates` lists them group by group, the newest first - the entry the task engine of
  cmeta-aops takes - and says which one stays. A cache without any entry has no duplicates (an answer,
  not "not found").
- `clean --duplicates` keeps the newest of each group and removes the others, and nothing else; with a
  state flag such as --failed both are removed. An entry that is being built, or whose last attempt
  failed, is never a duplicate.
- New in the cache category: selection_identity(artifact), duplicate_groups(artifacts, states).
- Tests: tests/internal_repo_tests/test_cache_states.py.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Signed-off-by: Grigori Fursin <gfursin@gmail.com>
There python.exe is a launcher that starts the interpreter as its child, so the pid of the process a test
starts (Popen.pid) is not the pid the holder writes into its lock file. test_a_live_soft_holder_judged_gone_by_mistake
compared the two and failed when the suite ran in a venv on Windows; the CI and the earlier runs used a Python
without a venv. The holder now prints its own pid and the test compares with that.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Signed-off-by: Grigori Fursin <gfursin@gmail.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Signed-off-by: Grigori Fursin <gfursin@gmail.com>
@gfursin
gfursin merged commit 7568642 into main Oct 12, 2026
10 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant