8000 Release crawler 1.0.0 and publish on every version bump by daoudclarke · Pull Request #561 · mwmbl/mwmbl · GitHub
[go: up one dir, main page]

Skip to content

Release crawler 1.0.0 and publish on every version bump - #561

Merged
daoudclarke merged 4 commits into
mainfrom
crawler-v1.0.0
Oct 29, 2026
Merged

daoudclarke merged 4 commits into
mainfrom
crawler-v1.0.0

Conversation

@daoudclarke
@daoudclarke daoudclarke commented Oct 28, 2026 •
Copy link
Copy Markdown
Contributor

What changed

  • 1.0.0: CRAWLER_VERSION is now 1.0.0.
  • Release on bump: crawler-release.yml now runs on pushes to main that change mwmbl/crawler/version.py, instead of on a pushed tag. It builds and pushes mwmbl/crawler:X.Y.Z, :X.Y, :stable and :latest, then tags the commit crawler-vX.Y.Z. If that tag already exists (the version didn't change, or was reverted to an older one), it does nothing. Because the workflow only runs from main, the old "is the tag on main" check isn't needed. Releases share a concurrency group, so two merges can't race on :stable.
  • Bump check: a new CI step on pull requests, python -m mwmbl.crawler.release_check HEAD^1, fails when crawler code changed but CRAWLER_VERSION didn't go up. "Crawler code" means every mwmbl module loaded by importing mwmbl.crawl (the image's entry point), plus mwmbl_rank/, uv.lock, pyproject.toml and Dockerfile.crawler. The import runs in a subprocess with a throwaway HOME, so its ~400MB index never lands in ~/.mwmbl. Modules the crawler only imports inside functions aren't seen.
  • :latest follows releases: deleted docker-publish.yml, which rebuilt :latest on every merge to main. Now that every crawler change has to bump the version, that rebuild was redundant. Setups that pull the untagged image (including existing compose installs) get each release and nothing in between.
  • Compose: docker-compose.yml now pins mwmbl/crawler:stable.
  • Stats page: the "command line script" link went to the archived mwmbl/crawler-script repo. It now links to the book's Docker Compose guide, the same one the README uses.

Why

Without this, a crawler change could merge and never reach volunteers on :stable, because someone had to remember to bump the version and push a tag by hand.

Note: the imported set includes shared modules such as settings_common.py, models.py and tinysearchengine/, and also uv.lock. Changing any of these means a crawler version bump too. That's on purpose: they change what the image runs.

Verification

  • test/test_crawler_release_check.py passes, and so does make check.
  • Ran the check locally against main. A commit that touched mwmbl/crawl.py without a bump failed and listed the file. The same change with the bump to 1.0.0 passed.
  • Merging this PR is the first real run of the release workflow. It should publish 1.0.0 and create crawler-v1.0.0.

🤖 Generated with Claude Code

- Raise CRAWLER_VERSION to 1.0.0.
- crawler-release.yml now runs when version.py changes on main: it publishes
  mwmbl/crawler:X.Y.Z, :X.Y and :stable, then pushes the crawler-vX.Y.Z tag. A version
  that is already tagged is skipped.
- CI fails a pull request that changes the crawler without raising CRAWLER_VERSION. The
  crawler's code is every mwmbl module loaded by importing mwmbl.crawl, plus the Rust
  extension, the lockfile, pyproject.toml and Dockerfile.crawler.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@codecov
codecov Bot commented Oct 28, 2026 •
Copy link
Copy Markdown

Codecov Report

❌ Patch coverage is 97.95918% with 1 line in your changes missing coverage. Please review.

Files with missing lines Patch % Lines
mwmbl/crawler/release_check.py 97.91% 1 Missing ⚠️

📢 Thoughts on this report? Let us know!

daoudclarke and others added 3 commits October 28, 2026 16:58
- Drop docker-publish.yml, which rebuilt mwmbl/crawler:latest on every merge to main. The
  release workflow now pushes :latest with each release, so setups pulling the untagged
  image move with releases.
- Pin docker-compose.yml to mwmbl/crawler:stable.
- Point the stats page at the book's Docker Compose guide instead of the archived
  crawler-script repo.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
- Count mwmbl/resources/ and the justext stoplists as crawler code: modules the crawler
  loads read them at import time, and they ship in the image.
- Say in the failure message that a rollback ships as a new, higher version.
- Let the module-listing subprocess's stderr through, so an import error shows in CI.
- Note in crawler-release.yml that a version queued behind two others is skipped.
- Update a comment that still described the tag-triggered release.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Covers each outcome of main() and the git helper, which codecov/patch flagged as untested.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@blueheron786
Copy link
Copy Markdown
Collaborator

What kind of versioning system are we planning to use? I was leaning towards semantic versioning, which is why I suggested a version X.Y.Z. If not, we can go with something simpler, like x.yyy where x is a major release and yyy is the automatic build increment.

@daoudclarke
Copy link
Copy Markdown
Contributor Author

Semantic versioning is great

@daoudclarke
daoudclarke merged commit 0fb4a87 into main Oct 29, 2026
7 checks passed
@daoudclarke
daoudclarke deleted the crawler-v1.0.0 branch October 29, 2026 15:56
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.

2 participants

0