Skip to content

feat: load common rules from config#30

Merged
TristanKruse merged 3 commits into
mainfrom
codex/config-rules
Jul 18, 2026
Merged

feat: load common rules from config#30
TristanKruse merged 3 commits into
mainfrom
codex/config-rules

Conversation

@TristanKruse

Copy link
Copy Markdown
Collaborator

Pull Request

Adds initial configuration-file support for common architecture rules.

This introduces rules_from_config(...), which loads named architecture rules from a JSON file and returns normal checkable rules that can be used with assert_passes(...) or .check().

The goal is to support simple shared project/team rules while keeping the fluent Python API as the primary and most flexible interface.

Supported rule types in this first slice:

  • no_cycles
  • forbidden_dependency
  • forbidden_external_dependency

Example:

from archunitpython import assert_passes, rules_from_config

def test_configured_architecture_rules():
    for rule in rules_from_config("archunitpython.json"):
        assert_passes(rule)

@TristanKruse

Copy link
Copy Markdown
Collaborator Author

@copilot resolve the merge conflicts in this pull request

Copilot AI commented Jul 18, 2026

Copy link
Copy Markdown
Contributor

@copilot resolve the merge conflicts in this pull request

Resolved by merging origin/main into this branch and fixing the conflicts in README.md and BACKLOG.md in commit 9a8b542.

@TristanKruse

Copy link
Copy Markdown
Collaborator Author

@copilot resolve the merge conflicts in this pull request

@TristanKruse
TristanKruse merged commit 738ebc7 into main Jul 18, 2026
10 checks passed
@github-actions

Copy link
Copy Markdown

🎉 This PR is included in version 1.5.0 🎉

The release is available on GitHub release

Your semantic-release bot 📦🚀

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants