RepoAuditor 0.2.29__tar.gz → 0.2.31__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- {repoauditor-0.2.29 → repoauditor-0.2.31}/.pre-commit-config.yaml +7 -0
- {repoauditor-0.2.29 → repoauditor-0.2.31}/PKG-INFO +1 -1
- {repoauditor-0.2.29 → repoauditor-0.2.31}/pyproject.toml +1 -1
- {repoauditor-0.2.29 → repoauditor-0.2.31}/src/RepoAuditor/CommandLineProcessor.py +5 -3
- {repoauditor-0.2.29 → repoauditor-0.2.31}/src/RepoAuditor/Display.py +2 -2
- {repoauditor-0.2.29 → repoauditor-0.2.31}/src/RepoAuditor/EntryPoint.py +8 -9
- {repoauditor-0.2.29 → repoauditor-0.2.31}/src/RepoAuditor/ExecuteModules.py +4 -5
- {repoauditor-0.2.29 → repoauditor-0.2.31}/src/RepoAuditor/Impl/ParallelSequentialProcessor.py +4 -4
- {repoauditor-0.2.29 → repoauditor-0.2.31}/src/RepoAuditor/Module.py +2 -3
- {repoauditor-0.2.29 → repoauditor-0.2.31}/src/RepoAuditor/Plugin.py +1 -2
- {repoauditor-0.2.29 → repoauditor-0.2.31}/src/RepoAuditor/Plugins/GitHub/ClassicBranchProtectionQuery.py +33 -17
- {repoauditor-0.2.29 → repoauditor-0.2.31}/src/RepoAuditor/Plugins/GitHub/ClassicBranchProtectionRequirements/AllowDeletions.py +3 -1
- {repoauditor-0.2.29 → repoauditor-0.2.31}/src/RepoAuditor/Plugins/GitHub/ClassicBranchProtectionRequirements/AllowForcePushes.py +3 -1
- {repoauditor-0.2.29 → repoauditor-0.2.31}/src/RepoAuditor/Plugins/GitHub/ClassicBranchProtectionRequirements/DismissStalePullRequestApprovals.py +3 -2
- {repoauditor-0.2.29 → repoauditor-0.2.31}/src/RepoAuditor/Plugins/GitHub/ClassicBranchProtectionRequirements/DoNotAllowBypassSettings.py +3 -1
- {repoauditor-0.2.29 → repoauditor-0.2.31}/src/RepoAuditor/Plugins/GitHub/ClassicBranchProtectionRequirements/EnsureStatusChecks.py +1 -2
- {repoauditor-0.2.29 → repoauditor-0.2.31}/src/RepoAuditor/Plugins/GitHub/ClassicBranchProtectionRequirements/Impl/ClassicEnableRequirementImpl.py +1 -2
- {repoauditor-0.2.29 → repoauditor-0.2.31}/src/RepoAuditor/Plugins/GitHub/ClassicBranchProtectionRequirements/Impl/ClassicValueRequirementImpl.py +1 -2
- {repoauditor-0.2.29 → repoauditor-0.2.31}/src/RepoAuditor/Plugins/GitHub/ClassicBranchProtectionRequirements/RequireApprovalMostRecentPush.py +3 -2
- {repoauditor-0.2.29 → repoauditor-0.2.31}/src/RepoAuditor/Plugins/GitHub/ClassicBranchProtectionRequirements/RequireApprovals.py +4 -2
- {repoauditor-0.2.29 → repoauditor-0.2.31}/src/RepoAuditor/Plugins/GitHub/ClassicBranchProtectionRequirements/RequireCodeOwnerReview.py +3 -2
- {repoauditor-0.2.29 → repoauditor-0.2.31}/src/RepoAuditor/Plugins/GitHub/ClassicBranchProtectionRequirements/RequireConversationResolution.py +3 -1
- {repoauditor-0.2.29 → repoauditor-0.2.31}/src/RepoAuditor/Plugins/GitHub/ClassicBranchProtectionRequirements/RequireLinearHistory.py +3 -1
- {repoauditor-0.2.29 → repoauditor-0.2.31}/src/RepoAuditor/Plugins/GitHub/ClassicBranchProtectionRequirements/RequirePullRequests.py +3 -1
- {repoauditor-0.2.29 → repoauditor-0.2.31}/src/RepoAuditor/Plugins/GitHub/ClassicBranchProtectionRequirements/RequireSignedCommits.py +3 -1
- {repoauditor-0.2.29 → repoauditor-0.2.31}/src/RepoAuditor/Plugins/GitHub/ClassicBranchProtectionRequirements/RequireStatusChecksToPass.py +3 -1
- {repoauditor-0.2.29 → repoauditor-0.2.31}/src/RepoAuditor/Plugins/GitHub/ClassicBranchProtectionRequirements/RequireUpToDateBranches.py +3 -2
- {repoauditor-0.2.29 → repoauditor-0.2.31}/src/RepoAuditor/Plugins/GitHub/DefaultBranchQuery.py +1 -2
- {repoauditor-0.2.29 → repoauditor-0.2.31}/src/RepoAuditor/Plugins/GitHub/DefaultBranchQueryRequirements/Protected.py +1 -2
- {repoauditor-0.2.29 → repoauditor-0.2.31}/src/RepoAuditor/Plugins/GitHub/Impl/EnableRequirementImpl.py +3 -5
- {repoauditor-0.2.29 → repoauditor-0.2.31}/src/RepoAuditor/Plugins/GitHub/Impl/ValueRequirementImpl.py +2 -4
- {repoauditor-0.2.29 → repoauditor-0.2.31}/src/RepoAuditor/Plugins/GitHub/Module.py +3 -4
- {repoauditor-0.2.29 → repoauditor-0.2.31}/src/RepoAuditor/Plugins/GitHub/StandardQuery.py +28 -23
- {repoauditor-0.2.29 → repoauditor-0.2.31}/src/RepoAuditor/Plugins/GitHub/StandardQueryRequirements/AutoMerge.py +3 -1
- {repoauditor-0.2.29 → repoauditor-0.2.31}/src/RepoAuditor/Plugins/GitHub/StandardQueryRequirements/DefaultBranch.py +3 -1
- {repoauditor-0.2.29 → repoauditor-0.2.31}/src/RepoAuditor/Plugins/GitHub/StandardQueryRequirements/DeleteHeadBranches.py +3 -1
- {repoauditor-0.2.29 → repoauditor-0.2.31}/src/RepoAuditor/Plugins/GitHub/StandardQueryRequirements/DependabotSecurityUpdates.py +3 -2
- {repoauditor-0.2.29 → repoauditor-0.2.31}/src/RepoAuditor/Plugins/GitHub/StandardQueryRequirements/Description.py +1 -3
- {repoauditor-0.2.29 → repoauditor-0.2.31}/src/RepoAuditor/Plugins/GitHub/StandardQueryRequirements/Impl/StandardEnableRequirementImpl.py +2 -3
- {repoauditor-0.2.29 → repoauditor-0.2.31}/src/RepoAuditor/Plugins/GitHub/StandardQueryRequirements/Impl/StandardValueRequirementImpl.py +1 -2
- {repoauditor-0.2.29 → repoauditor-0.2.31}/src/RepoAuditor/Plugins/GitHub/StandardQueryRequirements/License.py +3 -2
- {repoauditor-0.2.29 → repoauditor-0.2.31}/src/RepoAuditor/Plugins/GitHub/StandardQueryRequirements/MergeCommit.py +3 -1
- {repoauditor-0.2.29 → repoauditor-0.2.31}/src/RepoAuditor/Plugins/GitHub/StandardQueryRequirements/MergeCommitMessage.py +4 -2
- {repoauditor-0.2.29 → repoauditor-0.2.31}/src/RepoAuditor/Plugins/GitHub/StandardQueryRequirements/Private.py +1 -2
- {repoauditor-0.2.29 → repoauditor-0.2.31}/src/RepoAuditor/Plugins/GitHub/StandardQueryRequirements/RebaseMergeCommit.py +3 -1
- {repoauditor-0.2.29 → repoauditor-0.2.31}/src/RepoAuditor/Plugins/GitHub/StandardQueryRequirements/SecretScanning.py +3 -2
- {repoauditor-0.2.29 → repoauditor-0.2.31}/src/RepoAuditor/Plugins/GitHub/StandardQueryRequirements/SecretScanningPushProtection.py +3 -2
- {repoauditor-0.2.29 → repoauditor-0.2.31}/src/RepoAuditor/Plugins/GitHub/StandardQueryRequirements/SquashCommitMerge.py +3 -1
- {repoauditor-0.2.29 → repoauditor-0.2.31}/src/RepoAuditor/Plugins/GitHub/StandardQueryRequirements/SquashMergeCommitMessage.py +4 -2
- {repoauditor-0.2.29 → repoauditor-0.2.31}/src/RepoAuditor/Plugins/GitHub/StandardQueryRequirements/SuggestUpdatingPullRequestBranches.py +3 -1
- {repoauditor-0.2.29 → repoauditor-0.2.31}/src/RepoAuditor/Plugins/GitHub/StandardQueryRequirements/SupportDiscussions.py +3 -1
- {repoauditor-0.2.29 → repoauditor-0.2.31}/src/RepoAuditor/Plugins/GitHub/StandardQueryRequirements/SupportIssues.py +3 -1
- {repoauditor-0.2.29 → repoauditor-0.2.31}/src/RepoAuditor/Plugins/GitHub/StandardQueryRequirements/SupportProjects.py +3 -1
- {repoauditor-0.2.29 → repoauditor-0.2.31}/src/RepoAuditor/Plugins/GitHub/StandardQueryRequirements/SupportWikis.py +3 -1
- {repoauditor-0.2.29 → repoauditor-0.2.31}/src/RepoAuditor/Plugins/GitHub/StandardQueryRequirements/TemplateRepository.py +3 -1
- {repoauditor-0.2.29 → repoauditor-0.2.31}/src/RepoAuditor/Plugins/GitHub/StandardQueryRequirements/WebCommitSignoff.py +3 -1
- {repoauditor-0.2.29 → repoauditor-0.2.31}/src/RepoAuditor/Plugins/GitHubBase/Module.py +2 -2
- {repoauditor-0.2.29 → repoauditor-0.2.31}/src/RepoAuditor/Plugins/GitHubCustomization/Impl/ExistsRequirementImpl.py +1 -2
- {repoauditor-0.2.29 → repoauditor-0.2.31}/src/RepoAuditor/Plugins/GitHubPlugin.py +1 -2
- {repoauditor-0.2.29 → repoauditor-0.2.31}/src/RepoAuditor/Plugins/GitHubRulesets/Impl/EnableRulesetRequirementImpl.py +3 -3
- {repoauditor-0.2.29 → repoauditor-0.2.31}/src/RepoAuditor/Plugins/GitHubRulesets/RulesetQuery.py +2 -1
- {repoauditor-0.2.29 → repoauditor-0.2.31}/src/RepoAuditor/Plugins/GitHubRulesetsPlugin.py +0 -1
- {repoauditor-0.2.29 → repoauditor-0.2.31}/src/RepoAuditor/Query.py +3 -4
- {repoauditor-0.2.29 → repoauditor-0.2.31}/src/RepoAuditor/Requirement.py +2 -2
- {repoauditor-0.2.29 → repoauditor-0.2.31}/src/RepoAuditor/__init__.py +1 -1
- {repoauditor-0.2.29 → repoauditor-0.2.31}/.copier-answers.yml +0 -0
- {repoauditor-0.2.29 → repoauditor-0.2.31}/.github/CODEOWNERS +0 -0
- {repoauditor-0.2.29 → repoauditor-0.2.31}/.github/ISSUE_TEMPLATE/bug_report.md +0 -0
- {repoauditor-0.2.29 → repoauditor-0.2.31}/.github/ISSUE_TEMPLATE/config.yml +0 -0
- {repoauditor-0.2.29 → repoauditor-0.2.31}/.github/ISSUE_TEMPLATE/custom.md +0 -0
- {repoauditor-0.2.29 → repoauditor-0.2.31}/.github/ISSUE_TEMPLATE/feature_request.md +0 -0
- {repoauditor-0.2.29 → repoauditor-0.2.31}/.github/actions/release_impl/action.yml +0 -0
- {repoauditor-0.2.29 → repoauditor-0.2.31}/.github/pull_request_template.md +0 -0
- {repoauditor-0.2.29 → repoauditor-0.2.31}/.github/release_sources.yaml +0 -0
- {repoauditor-0.2.29 → repoauditor-0.2.31}/.github/workflows/CICD.yml +0 -0
- {repoauditor-0.2.29 → repoauditor-0.2.31}/.github/workflows/CICD_impl.yml +0 -0
- {repoauditor-0.2.29 → repoauditor-0.2.31}/.github/workflows/EndToEnd.yml +0 -0
- {repoauditor-0.2.29 → repoauditor-0.2.31}/.github/workflows/codeql.yml +0 -0
- {repoauditor-0.2.29 → repoauditor-0.2.31}/.gitignore +0 -0
- {repoauditor-0.2.29 → repoauditor-0.2.31}/.python-version +0 -0
- {repoauditor-0.2.29 → repoauditor-0.2.31}/CODE_OF_CONDUCT.md +0 -0
- {repoauditor-0.2.29 → repoauditor-0.2.31}/CONTRIBUTING.md +0 -0
- {repoauditor-0.2.29 → repoauditor-0.2.31}/DEVELOPMENT.md +0 -0
- {repoauditor-0.2.29 → repoauditor-0.2.31}/GOVERNANCE.md +0 -0
- {repoauditor-0.2.29 → repoauditor-0.2.31}/LICENSE +0 -0
- {repoauditor-0.2.29 → repoauditor-0.2.31}/MAINTAINERS.md +0 -0
- {repoauditor-0.2.29 → repoauditor-0.2.31}/README.md +0 -0
- {repoauditor-0.2.29 → repoauditor-0.2.31}/SECURITY.md +0 -0
- {repoauditor-0.2.29 → repoauditor-0.2.31}/minisign_key.pub +0 -0
- {repoauditor-0.2.29 → repoauditor-0.2.31}/src/AutoGitSemVer.yaml +0 -0
- {repoauditor-0.2.29 → repoauditor-0.2.31}/src/RepoAuditor/Impl/__init__.py +0 -0
- {repoauditor-0.2.29 → repoauditor-0.2.31}/src/RepoAuditor/Plugins/GitHub/ClassicBranchProtectionRequirements/Impl/__init__.py +0 -0
- {repoauditor-0.2.29 → repoauditor-0.2.31}/src/RepoAuditor/Plugins/GitHub/ClassicBranchProtectionRequirements/__init__.py +0 -0
- {repoauditor-0.2.29 → repoauditor-0.2.31}/src/RepoAuditor/Plugins/GitHub/DefaultBranchQueryRequirements/__init__.py +0 -0
- {repoauditor-0.2.29 → repoauditor-0.2.31}/src/RepoAuditor/Plugins/GitHub/Impl/Common.py +0 -0
- {repoauditor-0.2.29 → repoauditor-0.2.31}/src/RepoAuditor/Plugins/GitHub/Impl/__init__.py +0 -0
- {repoauditor-0.2.29 → repoauditor-0.2.31}/src/RepoAuditor/Plugins/GitHub/StandardQueryRequirements/Impl/__init__.py +0 -0
- {repoauditor-0.2.29 → repoauditor-0.2.31}/src/RepoAuditor/Plugins/GitHub/StandardQueryRequirements/__init__.py +0 -0
- {repoauditor-0.2.29 → repoauditor-0.2.31}/src/RepoAuditor/Plugins/GitHub/__init__.py +0 -0
- {repoauditor-0.2.29 → repoauditor-0.2.31}/src/RepoAuditor/Plugins/GitHubBase/__init__.py +0 -0
- {repoauditor-0.2.29 → repoauditor-0.2.31}/src/RepoAuditor/Plugins/GitHubCustomization/CustomizationQuery.py +3 -3
- {repoauditor-0.2.29 → repoauditor-0.2.31}/src/RepoAuditor/Plugins/GitHubCustomization/Impl/__init__.py +0 -0
- {repoauditor-0.2.29 → repoauditor-0.2.31}/src/RepoAuditor/Plugins/GitHubCustomization/Module.py +0 -0
- {repoauditor-0.2.29 → repoauditor-0.2.31}/src/RepoAuditor/Plugins/GitHubCustomization/Requirements/CodeOwners.py +0 -0
- {repoauditor-0.2.29 → repoauditor-0.2.31}/src/RepoAuditor/Plugins/GitHubCustomization/Requirements/Contributing.py +0 -0
- {repoauditor-0.2.29 → repoauditor-0.2.31}/src/RepoAuditor/Plugins/GitHubCustomization/Requirements/IssueTemplates.py +0 -0
- {repoauditor-0.2.29 → repoauditor-0.2.31}/src/RepoAuditor/Plugins/GitHubCustomization/Requirements/PullRequestTemplates.py +0 -0
- {repoauditor-0.2.29 → repoauditor-0.2.31}/src/RepoAuditor/Plugins/GitHubCustomization/Requirements/SecurityPolicy.py +0 -0
- {repoauditor-0.2.29 → repoauditor-0.2.31}/src/RepoAuditor/Plugins/GitHubCustomization/Requirements/__init__.py +0 -0
- {repoauditor-0.2.29 → repoauditor-0.2.31}/src/RepoAuditor/Plugins/GitHubCustomization/__init__.py +0 -0
- {repoauditor-0.2.29 → repoauditor-0.2.31}/src/RepoAuditor/Plugins/GitHubCustomizationPlugin.py +0 -0
- {repoauditor-0.2.29 → repoauditor-0.2.31}/src/RepoAuditor/Plugins/GitHubRulesets/Impl/__init__.py +0 -0
- {repoauditor-0.2.29 → repoauditor-0.2.31}/src/RepoAuditor/Plugins/GitHubRulesets/Module.py +0 -0
- {repoauditor-0.2.29 → repoauditor-0.2.31}/src/RepoAuditor/Plugins/GitHubRulesets/Requirements/RequirePullRequests.py +0 -0
- {repoauditor-0.2.29 → repoauditor-0.2.31}/src/RepoAuditor/Plugins/GitHubRulesets/Requirements/RequireSignedCommits.py +0 -0
- {repoauditor-0.2.29 → repoauditor-0.2.31}/src/RepoAuditor/Plugins/GitHubRulesets/Requirements/RequireStatusChecks.py +0 -0
- {repoauditor-0.2.29 → repoauditor-0.2.31}/src/RepoAuditor/Plugins/GitHubRulesets/Requirements/__init__.py +0 -0
- {repoauditor-0.2.29 → repoauditor-0.2.31}/src/RepoAuditor/Plugins/GitHubRulesets/__init__.py +0 -0
- {repoauditor-0.2.29 → repoauditor-0.2.31}/src/RepoAuditor/Plugins/__init__.py +0 -0
- {repoauditor-0.2.29 → repoauditor-0.2.31}/src/RepoAuditor/py.typed +0 -0
- {repoauditor-0.2.29 → repoauditor-0.2.31}/tests/CommandLineProcessor_UnitTest.py +0 -0
- {repoauditor-0.2.29 → repoauditor-0.2.31}/tests/EntryPoint_UnitTest.py +0 -0
- {repoauditor-0.2.29 → repoauditor-0.2.31}/tests/ExecuteModules_UnitTest.py +0 -0
- {repoauditor-0.2.29 → repoauditor-0.2.31}/tests/Module_UnitTest.py +0 -0
- {repoauditor-0.2.29 → repoauditor-0.2.31}/tests/Plugin_UnitTest.py +0 -0
- {repoauditor-0.2.29 → repoauditor-0.2.31}/tests/Plugins/GitHubCustomization_EndToEndTest.py +0 -0
- {repoauditor-0.2.29 → repoauditor-0.2.31}/tests/Plugins/GitHubCustomization_UnitTest.py +0 -0
- {repoauditor-0.2.29 → repoauditor-0.2.31}/tests/Plugins/GitHubModule_UnitTest.py +0 -0
- {repoauditor-0.2.29 → repoauditor-0.2.31}/tests/Plugins/GitHubRuleset_EndToEndTest.py +0 -0
- {repoauditor-0.2.29 → repoauditor-0.2.31}/tests/Plugins/GitHubRuleset_UnitTest.py +0 -0
- {repoauditor-0.2.29 → repoauditor-0.2.31}/tests/Plugins/GitHub_EndToEndTest.py +0 -0
- {repoauditor-0.2.29 → repoauditor-0.2.31}/tests/Plugins/__snapshots__/GitHubCustomization_EndToEndTest.ambr +0 -0
- {repoauditor-0.2.29 → repoauditor-0.2.31}/tests/Plugins/__snapshots__/GitHubRuleset_EndToEndTest.ambr +0 -0
- {repoauditor-0.2.29 → repoauditor-0.2.31}/tests/Plugins/__snapshots__/GitHub_EndToEndTest.ambr +0 -0
- {repoauditor-0.2.29 → repoauditor-0.2.31}/tests/Plugins/utilities.py +0 -0
- {repoauditor-0.2.29 → repoauditor-0.2.31}/tests/Query_UnitTest.py +0 -0
- {repoauditor-0.2.29 → repoauditor-0.2.31}/tests/Requirement_UnitTest.py +0 -0
- {repoauditor-0.2.29 → repoauditor-0.2.31}/tests/__snapshots__/ExecuteModules_UnitTest.ambr +0 -0
- {repoauditor-0.2.29 → repoauditor-0.2.31}/uv.lock +0 -0
|
@@ -11,6 +11,13 @@ repos:
|
|
|
11
11
|
require_serial: true
|
|
12
12
|
always_run: true
|
|
13
13
|
|
|
14
|
+
- id: uv run ruff check --select I --fix
|
|
15
|
+
name: ruff sort imports
|
|
16
|
+
entry: uv run ruff check --select I --fix
|
|
17
|
+
language: system
|
|
18
|
+
pass_filenames: false
|
|
19
|
+
always_run: true
|
|
20
|
+
|
|
14
21
|
- id: uv run ruff format --check
|
|
15
22
|
name: uv run ruff format --check
|
|
16
23
|
entry: uv run ruff format --check
|
|
@@ -11,7 +11,7 @@ from typing import Any, Protocol
|
|
|
11
11
|
|
|
12
12
|
from dbrownell_Common.Streams.DoneManager import DoneManager # type: ignore[import-untyped]
|
|
13
13
|
|
|
14
|
-
from .ExecuteModules import Execute, Module, ModuleInfo
|
|
14
|
+
from RepoAuditor.ExecuteModules import Execute, Module, ModuleInfo
|
|
15
15
|
|
|
16
16
|
|
|
17
17
|
# ----------------------------------------------------------------------
|
|
@@ -152,15 +152,17 @@ class CommandLineProcessor:
|
|
|
152
152
|
# Now we process the definitions to get the dynamic arguments
|
|
153
153
|
dynamic_args: dict[str, dict[str, Any]] = {}
|
|
154
154
|
|
|
155
|
+
num_acceptable_dynamic_args_parts = 2
|
|
156
|
+
|
|
155
157
|
for key, value in get_dynamic_args_func(dynamic_arg_definitions).items():
|
|
156
158
|
parts = key.split(argument_separator)
|
|
157
|
-
assert len(parts) >=
|
|
159
|
+
assert len(parts) >= num_acceptable_dynamic_args_parts
|
|
158
160
|
|
|
159
161
|
if parts[0] not in module_map:
|
|
160
162
|
msg = f"'{parts[0]}' is not a recognized module name."
|
|
161
163
|
raise ValueError(msg)
|
|
162
164
|
|
|
163
|
-
if len(parts) ==
|
|
165
|
+
if len(parts) == num_acceptable_dynamic_args_parts:
|
|
164
166
|
dynamic_args.setdefault(parts[0], {})[parts[1]] = value
|
|
165
167
|
else:
|
|
166
168
|
dynamic_args.setdefault(parts[0], {}).setdefault(None, {}).setdefault( # type: ignore[call-overload]
|
|
@@ -9,13 +9,13 @@
|
|
|
9
9
|
import textwrap
|
|
10
10
|
from typing import Optional
|
|
11
11
|
|
|
12
|
-
from dbrownell_Common.Streams.DoneManager import DoneManager # type: ignore[import-untyped]
|
|
13
12
|
from dbrownell_Common import TextwrapEx # type: ignore[import-untyped]
|
|
13
|
+
from dbrownell_Common.Streams.DoneManager import DoneManager # type: ignore[import-untyped]
|
|
14
14
|
from rich import print as rich_print
|
|
15
15
|
from rich.console import Group
|
|
16
16
|
from rich.panel import Panel
|
|
17
17
|
|
|
18
|
-
from .Module import EvaluateResult, Module
|
|
18
|
+
from RepoAuditor.Module import EvaluateResult, Module
|
|
19
19
|
|
|
20
20
|
|
|
21
21
|
def GetInternalPanelContent(
|
|
@@ -9,23 +9,22 @@
|
|
|
9
9
|
import sys
|
|
10
10
|
import textwrap
|
|
11
11
|
import traceback
|
|
12
|
-
|
|
13
12
|
from typing import Annotated, Optional
|
|
14
13
|
|
|
15
14
|
import pluggy
|
|
16
15
|
import typer
|
|
17
|
-
|
|
18
16
|
from click.exceptions import UsageError
|
|
19
|
-
from dbrownell_Common
|
|
20
|
-
|
|
21
|
-
|
|
17
|
+
from dbrownell_Common import (
|
|
18
|
+
TextwrapEx, # type: ignore [import-untyped]
|
|
19
|
+
TyperEx, # type: ignore [import-untyped]
|
|
20
|
+
)
|
|
21
|
+
from dbrownell_Common.Streams.DoneManager import DoneManager
|
|
22
|
+
from dbrownell_Common.Streams.DoneManager import Flags as DoneManagerFlags # type: ignore [import-untyped]
|
|
22
23
|
from typer.core import TyperGroup # type: ignore [import-untyped]
|
|
23
24
|
|
|
24
|
-
from RepoAuditor import APP_NAME, __version__
|
|
25
|
+
from RepoAuditor import APP_NAME, Plugin, __version__
|
|
25
26
|
from RepoAuditor.CommandLineProcessor import CommandLineProcessor, Module
|
|
26
27
|
from RepoAuditor.Display import DisplayResults
|
|
27
|
-
from RepoAuditor import Plugin
|
|
28
|
-
|
|
29
28
|
|
|
30
29
|
# ----------------------------------------------------------------------
|
|
31
30
|
ARGUMENT_SEPARATOR = "-"
|
|
@@ -182,7 +181,7 @@ def _VersionCallback(value: bool) -> None: # noqa: FBT001
|
|
|
182
181
|
epilog=_HelpEpilog(),
|
|
183
182
|
no_args_is_help=False,
|
|
184
183
|
)
|
|
185
|
-
def EntryPoint(
|
|
184
|
+
def EntryPoint( # noqa: PLR0913
|
|
186
185
|
ctx: typer.Context,
|
|
187
186
|
version: Annotated[ # noqa: ARG001, FBT002
|
|
188
187
|
bool,
|
|
@@ -8,10 +8,9 @@
|
|
|
8
8
|
|
|
9
9
|
import itertools
|
|
10
10
|
import sys
|
|
11
|
-
|
|
12
|
-
from dataclasses import dataclass
|
|
13
|
-
from typing import Any, cast, Optional
|
|
14
11
|
from collections.abc import Callable
|
|
12
|
+
from dataclasses import dataclass
|
|
13
|
+
from typing import Any, Optional, cast
|
|
15
14
|
|
|
16
15
|
from dbrownell_Common import ExecuteTasks # type: ignore[import-untyped]
|
|
17
16
|
from dbrownell_Common.InflectEx import inflect # type: ignore[import-untyped]
|
|
@@ -19,7 +18,7 @@ from dbrownell_Common.Streams.Capabilities import Capabilities # type: ignore[i
|
|
|
19
18
|
from dbrownell_Common.Streams.DoneManager import DoneManager # type: ignore[import-untyped]
|
|
20
19
|
from rich.progress import Progress, TimeElapsedColumn
|
|
21
20
|
|
|
22
|
-
from .Module import EvaluateResult, ExecutionStyle, Module, OnStatusFunc
|
|
21
|
+
from RepoAuditor.Module import EvaluateResult, ExecutionStyle, Module, OnStatusFunc
|
|
23
22
|
|
|
24
23
|
|
|
25
24
|
# ----------------------------------------------------------------------
|
|
@@ -211,7 +210,7 @@ def Execute(
|
|
|
211
210
|
# rather than referencing `sys.stdout` directly, but it is really hard to work with mocked
|
|
212
211
|
# stream as mocks will create mocks for everything called on the mock. Use sys.stdout
|
|
213
212
|
# directly to avoid that particular problem.
|
|
214
|
-
from unittest.mock import
|
|
213
|
+
from unittest.mock import MagicMock, Mock
|
|
215
214
|
|
|
216
215
|
assert stdout_context.stream is sys.stdout or isinstance(
|
|
217
216
|
stdout_context.stream, (Mock, MagicMock)
|
{repoauditor-0.2.29 → repoauditor-0.2.31}/src/RepoAuditor/Impl/ParallelSequentialProcessor.py
RENAMED
|
@@ -6,9 +6,9 @@
|
|
|
6
6
|
# -------------------------------------------------------------------------------
|
|
7
7
|
"""Contains functionality to process items in parallel and/or sequentially."""
|
|
8
8
|
|
|
9
|
-
from enum import auto, Enum
|
|
10
|
-
from typing import cast, TypeVar, Optional
|
|
11
9
|
from collections.abc import Callable
|
|
10
|
+
from enum import Enum, auto
|
|
11
|
+
from typing import Optional, TypeVar, cast
|
|
12
12
|
|
|
13
13
|
from dbrownell_Common import ExecuteTasks # type: ignore[import-untyped]
|
|
14
14
|
from dbrownell_Common.Streams.DoneManager import DoneManager # type: ignore[import-untyped]
|
|
@@ -37,9 +37,9 @@ def ParallelSequentialProcessor(
|
|
|
37
37
|
) -> list[OutputType]:
|
|
38
38
|
"""Process a list of items in parallel and/or sequentially."""
|
|
39
39
|
if dm is None:
|
|
40
|
-
with DoneManager.Create(StreamDecorator(None), "", line_prefix="") as
|
|
40
|
+
with DoneManager.Create(StreamDecorator(None), "", line_prefix="") as _dm:
|
|
41
41
|
return _Impl(
|
|
42
|
-
|
|
42
|
+
_dm,
|
|
43
43
|
items,
|
|
44
44
|
calculate_result_func,
|
|
45
45
|
max_num_threads,
|
|
@@ -7,15 +7,14 @@
|
|
|
7
7
|
"""Contains the Module object and types used in its definition."""
|
|
8
8
|
|
|
9
9
|
import threading
|
|
10
|
-
|
|
11
10
|
from abc import ABC, abstractmethod
|
|
12
11
|
from dataclasses import dataclass
|
|
13
12
|
from typing import Any, Optional
|
|
14
13
|
|
|
15
14
|
from dbrownell_Common.TyperEx import TypeDefinitionItemType # type: ignore[import-untyped]
|
|
16
15
|
|
|
17
|
-
from .Impl.ParallelSequentialProcessor import ParallelSequentialProcessor
|
|
18
|
-
from .Query import EvaluateResult, ExecutionStyle, OnStatusFunc, Query, StatusInfo
|
|
16
|
+
from RepoAuditor.Impl.ParallelSequentialProcessor import ParallelSequentialProcessor
|
|
17
|
+
from RepoAuditor.Query import EvaluateResult, ExecutionStyle, OnStatusFunc, Query, StatusInfo
|
|
19
18
|
|
|
20
19
|
|
|
21
20
|
# ----------------------------------------------------------------------
|
|
@@ -61,30 +61,46 @@ RESPONSE:
|
|
|
61
61
|
|
|
62
62
|
from typing import Any, Optional
|
|
63
63
|
|
|
64
|
+
import requests
|
|
64
65
|
from dbrownell_Common.Types import override # type: ignore[import-untyped]
|
|
65
66
|
|
|
66
|
-
from RepoAuditor.
|
|
67
|
-
|
|
68
|
-
from .ClassicBranchProtectionRequirements.
|
|
69
|
-
from .ClassicBranchProtectionRequirements.AllowForcePushes import AllowForcePushes
|
|
70
|
-
from .ClassicBranchProtectionRequirements.DismissStalePullRequestApprovals import (
|
|
67
|
+
from RepoAuditor.Plugins.GitHub.ClassicBranchProtectionRequirements.AllowDeletions import AllowDeletions
|
|
68
|
+
from RepoAuditor.Plugins.GitHub.ClassicBranchProtectionRequirements.AllowForcePushes import AllowForcePushes
|
|
69
|
+
from RepoAuditor.Plugins.GitHub.ClassicBranchProtectionRequirements.DismissStalePullRequestApprovals import (
|
|
71
70
|
DismissStalePullRequestApprovals,
|
|
72
71
|
)
|
|
73
|
-
from .ClassicBranchProtectionRequirements.DoNotAllowBypassSettings import
|
|
74
|
-
|
|
75
|
-
|
|
72
|
+
from RepoAuditor.Plugins.GitHub.ClassicBranchProtectionRequirements.DoNotAllowBypassSettings import (
|
|
73
|
+
DoNotAllowBypassSettings,
|
|
74
|
+
)
|
|
75
|
+
from RepoAuditor.Plugins.GitHub.ClassicBranchProtectionRequirements.EnsureStatusChecks import (
|
|
76
|
+
EnsureStatusChecks,
|
|
77
|
+
)
|
|
78
|
+
from RepoAuditor.Plugins.GitHub.ClassicBranchProtectionRequirements.RequireApprovalMostRecentPush import (
|
|
76
79
|
RequireApprovalMostRecentPush,
|
|
77
80
|
)
|
|
78
|
-
from .ClassicBranchProtectionRequirements.RequireApprovals import RequireApprovals
|
|
79
|
-
from .ClassicBranchProtectionRequirements.RequireCodeOwnerReview import
|
|
80
|
-
|
|
81
|
+
from RepoAuditor.Plugins.GitHub.ClassicBranchProtectionRequirements.RequireApprovals import RequireApprovals
|
|
82
|
+
from RepoAuditor.Plugins.GitHub.ClassicBranchProtectionRequirements.RequireCodeOwnerReview import (
|
|
83
|
+
RequireCodeOwnerReview,
|
|
84
|
+
)
|
|
85
|
+
from RepoAuditor.Plugins.GitHub.ClassicBranchProtectionRequirements.RequireConversationResolution import (
|
|
81
86
|
RequireConversationResolution,
|
|
82
87
|
)
|
|
83
|
-
from .ClassicBranchProtectionRequirements.RequireLinearHistory import
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
from .ClassicBranchProtectionRequirements.
|
|
87
|
-
|
|
88
|
+
from RepoAuditor.Plugins.GitHub.ClassicBranchProtectionRequirements.RequireLinearHistory import (
|
|
89
|
+
RequireLinearHistory,
|
|
90
|
+
)
|
|
91
|
+
from RepoAuditor.Plugins.GitHub.ClassicBranchProtectionRequirements.RequirePullRequests import (
|
|
92
|
+
RequirePullRequests,
|
|
93
|
+
)
|
|
94
|
+
from RepoAuditor.Plugins.GitHub.ClassicBranchProtectionRequirements.RequireSignedCommits import (
|
|
95
|
+
RequireSignedCommits,
|
|
96
|
+
)
|
|
97
|
+
from RepoAuditor.Plugins.GitHub.ClassicBranchProtectionRequirements.RequireStatusChecksToPass import (
|
|
98
|
+
RequireStatusChecksToPass,
|
|
99
|
+
)
|
|
100
|
+
from RepoAuditor.Plugins.GitHub.ClassicBranchProtectionRequirements.RequireUpToDateBranches import (
|
|
101
|
+
RequireUpToDateBranches,
|
|
102
|
+
)
|
|
103
|
+
from RepoAuditor.Query import ExecutionStyle, Query
|
|
88
104
|
|
|
89
105
|
|
|
90
106
|
# ----------------------------------------------------------------------
|
|
@@ -149,7 +165,7 @@ class ClassicBranchProtectionQuery(Query):
|
|
|
149
165
|
# and then see if rule sets are in use if the classic information is not found.
|
|
150
166
|
response = module_data["session"].get(f"/branches/{module_data['branch']}/protection")
|
|
151
167
|
|
|
152
|
-
if response.status_code ==
|
|
168
|
+
if response.status_code == requests.codes.NOT_FOUND:
|
|
153
169
|
# Does this branch use rule sets?
|
|
154
170
|
ruleset_response = module_data["session"].get(f"rules/branches/{module_data['branch']}")
|
|
155
171
|
|
|
@@ -8,7 +8,9 @@
|
|
|
8
8
|
|
|
9
9
|
import textwrap
|
|
10
10
|
|
|
11
|
-
from .Impl.ClassicEnableRequirementImpl import
|
|
11
|
+
from RepoAuditor.Plugins.GitHub.ClassicBranchProtectionRequirements.Impl.ClassicEnableRequirementImpl import (
|
|
12
|
+
ClassicEnableRequirementImpl,
|
|
13
|
+
)
|
|
12
14
|
|
|
13
15
|
|
|
14
16
|
# ----------------------------------------------------------------------
|
|
@@ -8,7 +8,9 @@
|
|
|
8
8
|
|
|
9
9
|
import textwrap
|
|
10
10
|
|
|
11
|
-
from .Impl.ClassicEnableRequirementImpl import
|
|
11
|
+
from RepoAuditor.Plugins.GitHub.ClassicBranchProtectionRequirements.Impl.ClassicEnableRequirementImpl import (
|
|
12
|
+
ClassicEnableRequirementImpl,
|
|
13
|
+
)
|
|
12
14
|
|
|
13
15
|
|
|
14
16
|
# ----------------------------------------------------------------------
|
|
@@ -7,10 +7,11 @@
|
|
|
7
7
|
"""Contains the DismissStalePullRequestApprovals object."""
|
|
8
8
|
|
|
9
9
|
import textwrap
|
|
10
|
-
|
|
11
10
|
from typing import Any, Optional
|
|
12
11
|
|
|
13
|
-
from .Impl.ClassicEnableRequirementImpl import
|
|
12
|
+
from RepoAuditor.Plugins.GitHub.ClassicBranchProtectionRequirements.Impl.ClassicEnableRequirementImpl import (
|
|
13
|
+
ClassicEnableRequirementImpl,
|
|
14
|
+
)
|
|
14
15
|
|
|
15
16
|
|
|
16
17
|
# ----------------------------------------------------------------------
|
|
@@ -8,7 +8,9 @@
|
|
|
8
8
|
|
|
9
9
|
import textwrap
|
|
10
10
|
|
|
11
|
-
from .Impl.ClassicEnableRequirementImpl import
|
|
11
|
+
from RepoAuditor.Plugins.GitHub.ClassicBranchProtectionRequirements.Impl.ClassicEnableRequirementImpl import (
|
|
12
|
+
ClassicEnableRequirementImpl,
|
|
13
|
+
)
|
|
12
14
|
|
|
13
15
|
|
|
14
16
|
# ----------------------------------------------------------------------
|
|
@@ -7,13 +7,12 @@
|
|
|
7
7
|
"""Contains the EnsureStatusChecks object."""
|
|
8
8
|
|
|
9
9
|
import textwrap
|
|
10
|
-
|
|
11
10
|
from typing import Any
|
|
12
11
|
|
|
13
12
|
import typer
|
|
14
|
-
|
|
15
13
|
from dbrownell_Common.TyperEx import TypeDefinitionItemType # type: ignore[import-untyped]
|
|
16
14
|
from dbrownell_Common.Types import override # type: ignore[import-untyped]
|
|
15
|
+
|
|
17
16
|
from RepoAuditor.Requirement import EvaluateResult, ExecutionStyle, Requirement
|
|
18
17
|
|
|
19
18
|
|
|
@@ -7,9 +7,8 @@
|
|
|
7
7
|
"""Contains the ClassicEnableRequirementImpl object."""
|
|
8
8
|
|
|
9
9
|
import textwrap
|
|
10
|
-
|
|
11
|
-
from typing import Any, Optional
|
|
12
10
|
from collections.abc import Callable
|
|
11
|
+
from typing import Any, Optional
|
|
13
12
|
|
|
14
13
|
from RepoAuditor.Plugins.GitHub.Impl.EnableRequirementImpl import EnableRequirementImpl
|
|
15
14
|
|
|
@@ -7,9 +7,8 @@
|
|
|
7
7
|
"""Contains the ClassicValueRequirementImpl object."""
|
|
8
8
|
|
|
9
9
|
import textwrap
|
|
10
|
-
|
|
11
|
-
from typing import Any, Optional
|
|
12
10
|
from collections.abc import Callable
|
|
11
|
+
from typing import Any, Optional
|
|
13
12
|
|
|
14
13
|
from RepoAuditor.Plugins.GitHub.Impl.ValueRequirementImpl import DoesNotApplyResult, ValueRequirementImpl
|
|
15
14
|
|
|
@@ -7,10 +7,11 @@
|
|
|
7
7
|
"""Contains the RequireApprovalMostRecentPush object."""
|
|
8
8
|
|
|
9
9
|
import textwrap
|
|
10
|
-
|
|
11
10
|
from typing import Any, Optional
|
|
12
11
|
|
|
13
|
-
from .Impl.ClassicEnableRequirementImpl import
|
|
12
|
+
from RepoAuditor.Plugins.GitHub.ClassicBranchProtectionRequirements.Impl.ClassicEnableRequirementImpl import (
|
|
13
|
+
ClassicEnableRequirementImpl,
|
|
14
|
+
)
|
|
14
15
|
|
|
15
16
|
|
|
16
17
|
# ----------------------------------------------------------------------
|
|
@@ -7,10 +7,12 @@
|
|
|
7
7
|
"""Contains the RequireApprovals object."""
|
|
8
8
|
|
|
9
9
|
import textwrap
|
|
10
|
-
|
|
11
10
|
from typing import Any
|
|
12
11
|
|
|
13
|
-
from .Impl.ClassicValueRequirementImpl import
|
|
12
|
+
from RepoAuditor.Plugins.GitHub.ClassicBranchProtectionRequirements.Impl.ClassicValueRequirementImpl import (
|
|
13
|
+
ClassicValueRequirementImpl,
|
|
14
|
+
DoesNotApplyResult,
|
|
15
|
+
)
|
|
14
16
|
|
|
15
17
|
|
|
16
18
|
# ----------------------------------------------------------------------
|
|
@@ -7,10 +7,11 @@
|
|
|
7
7
|
"""Contains the RequireCodeOwnerReview object."""
|
|
8
8
|
|
|
9
9
|
import textwrap
|
|
10
|
-
|
|
11
10
|
from typing import Any, Optional
|
|
12
11
|
|
|
13
|
-
from .Impl.ClassicEnableRequirementImpl import
|
|
12
|
+
from RepoAuditor.Plugins.GitHub.ClassicBranchProtectionRequirements.Impl.ClassicEnableRequirementImpl import (
|
|
13
|
+
ClassicEnableRequirementImpl,
|
|
14
|
+
)
|
|
14
15
|
|
|
15
16
|
|
|
16
17
|
# ----------------------------------------------------------------------
|
|
@@ -8,7 +8,9 @@
|
|
|
8
8
|
|
|
9
9
|
import textwrap
|
|
10
10
|
|
|
11
|
-
from .Impl.ClassicEnableRequirementImpl import
|
|
11
|
+
from RepoAuditor.Plugins.GitHub.ClassicBranchProtectionRequirements.Impl.ClassicEnableRequirementImpl import (
|
|
12
|
+
ClassicEnableRequirementImpl,
|
|
13
|
+
)
|
|
12
14
|
|
|
13
15
|
|
|
14
16
|
# ----------------------------------------------------------------------
|
|
@@ -8,7 +8,9 @@
|
|
|
8
8
|
|
|
9
9
|
import textwrap
|
|
10
10
|
|
|
11
|
-
from .Impl.ClassicEnableRequirementImpl import
|
|
11
|
+
from RepoAuditor.Plugins.GitHub.ClassicBranchProtectionRequirements.Impl.ClassicEnableRequirementImpl import (
|
|
12
|
+
ClassicEnableRequirementImpl,
|
|
13
|
+
)
|
|
12
14
|
|
|
13
15
|
|
|
14
16
|
# ----------------------------------------------------------------------
|
|
@@ -8,7 +8,9 @@
|
|
|
8
8
|
|
|
9
9
|
import textwrap
|
|
10
10
|
|
|
11
|
-
from .Impl.ClassicEnableRequirementImpl import
|
|
11
|
+
from RepoAuditor.Plugins.GitHub.ClassicBranchProtectionRequirements.Impl.ClassicEnableRequirementImpl import (
|
|
12
|
+
ClassicEnableRequirementImpl,
|
|
13
|
+
)
|
|
12
14
|
|
|
13
15
|
|
|
14
16
|
# ----------------------------------------------------------------------
|
|
@@ -8,7 +8,9 @@
|
|
|
8
8
|
|
|
9
9
|
import textwrap
|
|
10
10
|
|
|
11
|
-
from .Impl.ClassicEnableRequirementImpl import
|
|
11
|
+
from RepoAuditor.Plugins.GitHub.ClassicBranchProtectionRequirements.Impl.ClassicEnableRequirementImpl import (
|
|
12
|
+
ClassicEnableRequirementImpl,
|
|
13
|
+
)
|
|
12
14
|
|
|
13
15
|
|
|
14
16
|
# ----------------------------------------------------------------------
|
|
@@ -8,7 +8,9 @@
|
|
|
8
8
|
|
|
9
9
|
import textwrap
|
|
10
10
|
|
|
11
|
-
from .Impl.ClassicEnableRequirementImpl import
|
|
11
|
+
from RepoAuditor.Plugins.GitHub.ClassicBranchProtectionRequirements.Impl.ClassicEnableRequirementImpl import (
|
|
12
|
+
ClassicEnableRequirementImpl,
|
|
13
|
+
)
|
|
12
14
|
|
|
13
15
|
|
|
14
16
|
# ----------------------------------------------------------------------
|
|
@@ -7,10 +7,11 @@
|
|
|
7
7
|
"""Contains the RequireUpToDateBranches object."""
|
|
8
8
|
|
|
9
9
|
import textwrap
|
|
10
|
-
|
|
11
10
|
from typing import Any, Optional
|
|
12
11
|
|
|
13
|
-
from .Impl.ClassicEnableRequirementImpl import
|
|
12
|
+
from RepoAuditor.Plugins.GitHub.ClassicBranchProtectionRequirements.Impl.ClassicEnableRequirementImpl import (
|
|
13
|
+
ClassicEnableRequirementImpl,
|
|
14
|
+
)
|
|
14
15
|
|
|
15
16
|
|
|
16
17
|
# ----------------------------------------------------------------------
|
{repoauditor-0.2.29 → repoauditor-0.2.31}/src/RepoAuditor/Plugins/GitHub/DefaultBranchQuery.py
RENAMED
|
@@ -10,10 +10,9 @@ from typing import Any, Optional
|
|
|
10
10
|
|
|
11
11
|
from dbrownell_Common.Types import override # type: ignore[import-untyped]
|
|
12
12
|
|
|
13
|
+
from RepoAuditor.Plugins.GitHub.DefaultBranchQueryRequirements.Protected import Protected
|
|
13
14
|
from RepoAuditor.Query import ExecutionStyle, Query
|
|
14
15
|
|
|
15
|
-
from .DefaultBranchQueryRequirements.Protected import Protected
|
|
16
|
-
|
|
17
16
|
|
|
18
17
|
# ----------------------------------------------------------------------
|
|
19
18
|
class DefaultBranchQuery(Query):
|
|
@@ -7,13 +7,12 @@
|
|
|
7
7
|
"""Contains the Protected object."""
|
|
8
8
|
|
|
9
9
|
import textwrap
|
|
10
|
-
|
|
11
10
|
from typing import Any
|
|
12
11
|
|
|
13
12
|
import typer
|
|
14
|
-
|
|
15
13
|
from dbrownell_Common.TyperEx import TypeDefinitionItemType # type: ignore[import-untyped]
|
|
16
14
|
from dbrownell_Common.Types import override # type: ignore[import-untyped]
|
|
15
|
+
|
|
17
16
|
from RepoAuditor.Plugins.GitHub.Impl.Common import CreateIncompleteDataResult
|
|
18
17
|
from RepoAuditor.Requirement import EvaluateResult, ExecutionStyle, Requirement
|
|
19
18
|
|
|
@@ -6,25 +6,23 @@
|
|
|
6
6
|
# -------------------------------------------------------------------------------
|
|
7
7
|
"""Contains the EnableRequirementImpl object."""
|
|
8
8
|
|
|
9
|
-
from typing import Any, Optional
|
|
10
9
|
from collections.abc import Callable
|
|
10
|
+
from typing import Any, Optional
|
|
11
11
|
|
|
12
12
|
import typer
|
|
13
|
-
|
|
14
13
|
from dbrownell_Common.TyperEx import TypeDefinitionItemType # type: ignore[import-untyped]
|
|
15
14
|
from dbrownell_Common.Types import override # type: ignore[import-untyped]
|
|
16
15
|
|
|
16
|
+
from RepoAuditor.Plugins.GitHub.Impl.Common import CreateIncompleteDataResult
|
|
17
17
|
from RepoAuditor.Requirement import EvaluateResult, ExecutionStyle, Requirement
|
|
18
18
|
|
|
19
|
-
from .Common import CreateIncompleteDataResult
|
|
20
|
-
|
|
21
19
|
|
|
22
20
|
# ----------------------------------------------------------------------
|
|
23
21
|
class EnableRequirementImpl(Requirement):
|
|
24
22
|
"""Object that implements settings that can be enabled/disabled."""
|
|
25
23
|
|
|
26
24
|
# ----------------------------------------------------------------------
|
|
27
|
-
def __init__(
|
|
25
|
+
def __init__( # noqa: PLR0913
|
|
28
26
|
self,
|
|
29
27
|
name: str,
|
|
30
28
|
default_value: bool, # noqa: FBT001
|
|
@@ -6,19 +6,17 @@
|
|
|
6
6
|
# -------------------------------------------------------------------------------
|
|
7
7
|
"""Contains the ValueRequirementImpl object."""
|
|
8
8
|
|
|
9
|
+
from collections.abc import Callable
|
|
9
10
|
from dataclasses import dataclass
|
|
10
11
|
from typing import Any, Optional
|
|
11
|
-
from collections.abc import Callable
|
|
12
12
|
|
|
13
13
|
import typer
|
|
14
|
-
|
|
15
14
|
from dbrownell_Common.TyperEx import TypeDefinitionItemType # type: ignore[import-untyped]
|
|
16
15
|
from dbrownell_Common.Types import override # type: ignore[import-untyped]
|
|
17
16
|
|
|
17
|
+
from RepoAuditor.Plugins.GitHub.Impl.Common import CreateIncompleteDataResult
|
|
18
18
|
from RepoAuditor.Requirement import EvaluateResult, ExecutionStyle, Requirement
|
|
19
19
|
|
|
20
|
-
from .Common import CreateIncompleteDataResult
|
|
21
|
-
|
|
22
20
|
|
|
23
21
|
# ----------------------------------------------------------------------
|
|
24
22
|
@dataclass(frozen=True)
|
|
@@ -7,12 +7,11 @@
|
|
|
7
7
|
"""Contains the GitHubModule object."""
|
|
8
8
|
|
|
9
9
|
from RepoAuditor.Module import ExecutionStyle
|
|
10
|
+
from RepoAuditor.Plugins.GitHub.ClassicBranchProtectionQuery import ClassicBranchProtectionQuery
|
|
11
|
+
from RepoAuditor.Plugins.GitHub.DefaultBranchQuery import DefaultBranchQuery
|
|
12
|
+
from RepoAuditor.Plugins.GitHub.StandardQuery import StandardQuery
|
|
10
13
|
from RepoAuditor.Plugins.GitHubBase.Module import GitHubBaseModule
|
|
11
14
|
|
|
12
|
-
from .ClassicBranchProtectionQuery import ClassicBranchProtectionQuery
|
|
13
|
-
from .DefaultBranchQuery import DefaultBranchQuery
|
|
14
|
-
from .StandardQuery import StandardQuery
|
|
15
|
-
|
|
16
15
|
|
|
17
16
|
# ----------------------------------------------------------------------
|
|
18
17
|
class GitHubModule(GitHubBaseModule):
|