Skip to content

refactor: move examples/ into docs/examples/#10

Merged
aseguragonzalez merged 1 commit into
mainfrom
refactor/move-examples-to-docs
May 7, 2026
Merged

refactor: move examples/ into docs/examples/#10
aseguragonzalez merged 1 commit into
mainfrom
refactor/move-examples-to-docs

Conversation

@aseguragonzalez
Copy link
Copy Markdown
Owner

Summary

  • Moves examples/bank_account/ to docs/examples/bank_account/ to group all reference material under docs/
  • Updates pyproject.toml (pythonpath, pyright include + extraPaths), Makefile, and CI workflow to point at the new path
  • Updates internal imports inside the example package (from examples.bank_account.from bank_account.) and in all test files
  • Updates all documentation links in README.md, CLAUDE.md, docs/, and .github/

Test plan

  • make lint — ruff passes on src tests docs/examples
  • make typecheck — pyright reports 0 errors (resolves bank_account via extraPaths)
  • make test — 79 tests pass, coverage 100%
  • Pre-commit hooks pass (ruff, pyright, markdownlint, Conventional Commit)

🤖 Generated with Claude Code

Groups all reference material under docs/ so the repository structure is more
intuitive for contributors. Updates pythonpath, pyright extraPaths, ruff targets,
CI commands, internal example imports, and all documentation links accordingly.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Copilot AI review requested due to automatic review settings May 7, 2026 20:36
@codecov
Copy link
Copy Markdown

codecov Bot commented May 7, 2026

Codecov Report

✅ All modified and coverable lines are covered by tests.

📢 Thoughts on this report? Let us know!

Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR relocates the bank_account example bounded context under docs/examples/ to consolidate reference material within the documentation tree, and updates tooling/configuration so tests, linting, and type-checking continue to resolve the example package correctly.

Changes:

  • Moved the bank_account example code into docs/examples/bank_account/ and updated its internal imports to from bank_account....
  • Updated test imports to reference bank_account directly (instead of examples.bank_account).
  • Updated tooling/docs pointers (pytest pythonpath, pyright include/extraPaths, Makefile, CI, and documentation links) to the new location.

Reviewed changes

Copilot reviewed 22 out of 35 changed files in this pull request and generated no comments.

Show a summary per file
File Description
tests/infrastructure/test_registry_command_bus.py Update example-domain import path to bank_account.*.
tests/infrastructure/test_in_memory_repository.py Update example-domain import paths to bank_account.*.
tests/infrastructure/test_domain_event_publishing_repository.py Update example-domain import paths to bank_account.*.
tests/domain/test_value_object.py Update example-domain import path to bank_account.*.
tests/domain/test_domain_error.py Update example-domain import path to bank_account.*.
tests/domain/test_aggregate_root.py Update example-domain import paths to bank_account.*.
tests/application/test_get_balance_handler.py Update example-application import paths to bank_account.*.
README.md Point readers to the example’s new location under docs/examples/.
pyproject.toml Update pytest pythonpath and pyright paths to include docs/examples.
Makefile Update ruff targets to lint/format docs/examples instead of examples.
docs/README.md Update docs link to the example under docs/examples.
docs/getting-started.md Update example links to the new location.
docs/examples/bank_account/domain/money.py Add moved example domain Money value object implementation.
docs/examples/bank_account/domain/events/account_opened.py Add moved example domain event record/payload.
docs/examples/bank_account/domain/events/account_debited.py Add moved example domain event record/payload.
docs/examples/bank_account/domain/events/account_credited.py Add moved example domain event record/payload.
docs/examples/bank_account/domain/events/init.py Package marker for example domain events.
docs/examples/bank_account/domain/errors.py Add moved example domain errors.
docs/examples/bank_account/domain/bank_account.py Add moved example aggregate root and domain behavior.
docs/examples/bank_account/domain/bank_account_repository.py Add moved example repository protocol.
docs/examples/bank_account/domain/bank_account_id.py Add moved example ID NewType.
docs/examples/bank_account/domain/init.py Package marker for example domain.
docs/examples/bank_account/application/get_balance/get_balance_query.py Add moved example query object with updated imports.
docs/examples/bank_account/application/get_balance/get_balance_handler.py Add moved example handler with updated imports.
docs/examples/bank_account/application/get_balance/bank_account_read_repository.py Add moved example read-repo protocol with updated imports.
docs/examples/bank_account/application/get_balance/balance_response.py Add moved example DTO for query results.
docs/examples/bank_account/application/get_balance/init.py Package marker for example application module.
docs/examples/bank_account/application/init.py Package marker for example application layer.
docs/examples/bank_account/init.py Package marker for the bank_account example package.
docs/examples/init.py Package marker for docs examples root.
docs/best-practices.md Update reference to the new example location.
CLAUDE.md Update contributor guidance and example location references.
.github/workflows/ci.yml Update ruff CI paths to docs/examples.
.github/SECURITY.md Update out-of-scope wording to reference docs/examples.
.github/CONTRIBUTING.md Update contributor commands to reference docs/examples.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

@aseguragonzalez aseguragonzalez merged commit caf716c into main May 7, 2026
10 checks passed
@aseguragonzalez aseguragonzalez deleted the refactor/move-examples-to-docs branch May 7, 2026 20:40
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