Skip to content

CodeClone 2.0.3

Latest

Choose a tag to compare

@orenlab orenlab released this 28 Oct 13:47

2.0.3 is a security release and the last planned release of the 2.x line. It keeps an analysed repository from steering CodeClone and its GitHub Action, and pins what CodeClone installs. Upgrade the package and the Action now; plan the move to 3.0.

Editor and agent clients are not updated by this release. The VS Code extension, the Claude Desktop bundle and the Codex plugin are not republished through their own channels with 2.0.3. Their launcher fixes are in this repository at the v2.0.3 tag only. The links in the README and on PyPI still point to the main branch. See the security advisory for what to do until updated clients are available.

Users of 2.1.0a1: pip install -U codeclone keeps 2.1.0a1, with or without --pre, because pip treats it as newer than 2.0.3. Install the fix explicitly with pip install "codeclone==2.0.3". Baselines written by 2.1.0a1 are accepted by 2.0.3. Change control and engineering memory exist only in 2.1.0a1 and are not part of 2.0.3.

Security

  • The launchers in this repository never start a codeclone-mcp found inside the opened workspace: the Codex plugin launcher, the Claude Desktop bundle and the VS Code extension. They start a configured absolute launcher, a user-level install or an absolute PATH entry, and otherwise stop with setup instructions.
  • Paths in the analysed repository's pyproject.toml must stay inside the repository after links are followed. Reports, --update-baseline and the cache (CLI and MCP analyze_repository) are never written or read through a link that leads outside it.
  • In gating mode a file that was found but not analysed is a contract error (exit 2). A syntax error can be excluded file by file with --allow-syntax-error FILE. Report schema 2.12 and every report show the verified scope and the excluded files.
  • File names and qualnames are inert code spans in the Markdown report and the MCP PR summary.
  • Changed-file review runs git without the repository's filesystem monitor, hooks, filter drivers and inherited GIT_DIR-style variables.
  • The HTML report loads nothing from the network: no web fonts, and the badge dialog shows the badge address as text.

Fixed

  • A pyproject.toml nested too deeply to read is a contract error instead of an internal error.

Dependencies

  • Cap runtime dependencies below their next major version, and raise the mcp extra to mcp>=1.30.0,<2.
  • Lock releases at least 14 days old (exclude-newer), with reviewed security exceptions for certifi, filelock and virtualenv. The VS Code extension lock is refreshed after byte-level verification; this covers development dependencies only.

GitHub Action

  • Install the release from requirements.txt: every wheel is pinned by SHA-256 and installed with a pip that is itself fetched and checked by SHA-256.
  • Publish a JSON or SARIF report only when this run wrote it.
  • Run on Node 24 releases of the actions it uses, pinned to full commits.

Documentation

  • README, the PyPI description, the package metadata, the MCP help topics and the plugin and bundle manifests link the documentation of the v2.0.3 tag.

Internal

  • List CodeClone in the MCP Registry (server.json, codeclone --mcp) and on Glama (glama.json), and ship a pre-commit hook manifest.
  • Build the release wheel reproducibly and refuse to publish a wheel other than the one the Action pins. Pin every workflow action to a full commit and install CI dependencies with uv sync --locked --no-build.
  • Pass the release tag and workflow inputs to shell steps through the environment.
  • Introduce type checking with ty, pinned to 0.0.84 and run in CI on codeclone, .github/actions and benchmarks. It reports no diagnostics on 0.0.84, with no type suppressions added; newer ty releases may still report warnings.

Known issues

  • Clients. The VS Code extension, the Claude Desktop bundle and the Codex plugin are not republished with this release; see the note at the top.
  • Changed-files mode. With --changed-only or --diff-against, and in MCP analyze_changed_paths, a changed file whose name git prints in quotes is left out of the checked set, and the gate can pass. Such names contain non-ASCII characters, " or \. Full runs, --ci, the pre-commit hook and the Action defaults are not affected.
  • With --changed-only, changed files are not found when the analysis root is a subdirectory of the repository.
  • The text report (--text) prints control characters from file names as they are.
  • A repository can slow the analysis down or exhaust memory: very large files, a heavy coverage_xml, golden_fixture_paths patterns, or a high processes value in pyproject.toml. The gate then fails; it does not pass.
  • A cache entry inside the repository is trusted when the file's modification time and size match. In practice this applies to unpacked archives, not to a git checkout.
  • git diff may refresh the stat data of the analysed repository's index.
  • Known analysis inaccuracies remain: false positives in dead-code detection, and imprecision in complexity and coupling metrics.
  • The source distribution is not byte-reproducible. The wheel is reproducible and is the artifact the Action pins.
  • Report schema 2.12. Reports written by 2.0.3 and by the 2.1.0a1 pre-release both say 2.12 but have different fields. 2.0.3 adds inventory.excluded_files; 2.1.0a1 has derived.module_map and derived.review_queue. They are not interchangeable.

Full changelog: https://github.com/orenlab/codeclone/blob/v2.0.3/CHANGELOG.md