review-sensei-github 0.1.1__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.
- review_sensei_github-0.1.1/PKG-INFO +29 -0
- review_sensei_github-0.1.1/README.md +11 -0
- review_sensei_github-0.1.1/pyproject.toml +36 -0
- review_sensei_github-0.1.1/setup.cfg +4 -0
- review_sensei_github-0.1.1/src/review_sensei_github/__init__.py +189 -0
- review_sensei_github-0.1.1/src/review_sensei_github/__main__.py +10 -0
- review_sensei_github-0.1.1/src/review_sensei_github/application.py +2465 -0
- review_sensei_github-0.1.1/src/review_sensei_github/approval.py +653 -0
- review_sensei_github-0.1.1/src/review_sensei_github/auth.py +514 -0
- review_sensei_github-0.1.1/src/review_sensei_github/broker.py +519 -0
- review_sensei_github-0.1.1/src/review_sensei_github/broker_client.py +439 -0
- review_sensei_github-0.1.1/src/review_sensei_github/checks.py +496 -0
- review_sensei_github-0.1.1/src/review_sensei_github/cli.py +156 -0
- review_sensei_github-0.1.1/src/review_sensei_github/command_bodies.py +1244 -0
- review_sensei_github-0.1.1/src/review_sensei_github/commands.py +82 -0
- review_sensei_github-0.1.1/src/review_sensei_github/conversation.py +2066 -0
- review_sensei_github-0.1.1/src/review_sensei_github/doctor.py +36 -0
- review_sensei_github-0.1.1/src/review_sensei_github/eligibility_parts.py +378 -0
- review_sensei_github-0.1.1/src/review_sensei_github/errors.py +198 -0
- review_sensei_github-0.1.1/src/review_sensei_github/feedback_attestation.py +217 -0
- review_sensei_github-0.1.1/src/review_sensei_github/fixtures/__init__.py +1 -0
- review_sensei_github-0.1.1/src/review_sensei_github/fixtures/historical-v4-uninstall.yml +62 -0
- review_sensei_github-0.1.1/src/review_sensei_github/fixtures/merge-focused-v4-caller.yml +359 -0
- review_sensei_github-0.1.1/src/review_sensei_github/fixtures/merge-focused-v4-config.yml +19 -0
- review_sensei_github-0.1.1/src/review_sensei_github/fixtures/released-v4-resolve-trigger-runner-switch.yml +341 -0
- review_sensei_github-0.1.1/src/review_sensei_github/fixtures/sensei-only-v5-caller.yml +280 -0
- review_sensei_github-0.1.1/src/review_sensei_github/http.py +494 -0
- review_sensei_github-0.1.1/src/review_sensei_github/human_assessment.py +1077 -0
- review_sensei_github-0.1.1/src/review_sensei_github/human_file_review.py +879 -0
- review_sensei_github-0.1.1/src/review_sensei_github/jwt.py +136 -0
- review_sensei_github-0.1.1/src/review_sensei_github/learning_pr.py +2782 -0
- review_sensei_github-0.1.1/src/review_sensei_github/observed.py +900 -0
- review_sensei_github-0.1.1/src/review_sensei_github/oidc.py +370 -0
- review_sensei_github-0.1.1/src/review_sensei_github/openrouter_workflow.py +46 -0
- review_sensei_github-0.1.1/src/review_sensei_github/operation_comments.py +357 -0
- review_sensei_github-0.1.1/src/review_sensei_github/operation_entry.py +522 -0
- review_sensei_github-0.1.1/src/review_sensei_github/operation_host.py +2050 -0
- review_sensei_github-0.1.1/src/review_sensei_github/pending.py +263 -0
- review_sensei_github-0.1.1/src/review_sensei_github/prose_publication.py +353 -0
- review_sensei_github-0.1.1/src/review_sensei_github/publication.py +2941 -0
- review_sensei_github-0.1.1/src/review_sensei_github/publication_parts.py +242 -0
- review_sensei_github-0.1.1/src/review_sensei_github/reply_budget.py +97 -0
- review_sensei_github-0.1.1/src/review_sensei_github/reservation_recovery.py +221 -0
- review_sensei_github-0.1.1/src/review_sensei_github/review_hooks.py +37 -0
- review_sensei_github-0.1.1/src/review_sensei_github/session_ledger.py +2180 -0
- review_sensei_github-0.1.1/src/review_sensei_github/setup.py +2863 -0
- review_sensei_github-0.1.1/src/review_sensei_github/trigger.py +294 -0
- review_sensei_github-0.1.1/src/review_sensei_github/webhooks.py +327 -0
- review_sensei_github-0.1.1/src/review_sensei_github.egg-info/PKG-INFO +29 -0
- review_sensei_github-0.1.1/src/review_sensei_github.egg-info/SOURCES.txt +52 -0
- review_sensei_github-0.1.1/src/review_sensei_github.egg-info/dependency_links.txt +1 -0
- review_sensei_github-0.1.1/src/review_sensei_github.egg-info/entry_points.txt +2 -0
- review_sensei_github-0.1.1/src/review_sensei_github.egg-info/requires.txt +2 -0
- review_sensei_github-0.1.1/src/review_sensei_github.egg-info/top_level.txt +1 -0
|
@@ -0,0 +1,29 @@
|
|
|
1
|
+
Metadata-Version: 2.4
|
|
2
|
+
Name: review-sensei-github
|
|
3
|
+
Version: 0.1.1
|
|
4
|
+
Summary: GitHub Actions runtime for ReviewSensei: broker, session ledger, and publication.
|
|
5
|
+
Author: Mohamad Alsabbagh
|
|
6
|
+
License-Expression: MIT
|
|
7
|
+
Project-URL: Homepage, https://github.com/malsabbagh/review-sensei
|
|
8
|
+
Project-URL: Source, https://github.com/malsabbagh/review-sensei
|
|
9
|
+
Project-URL: Changelog, https://github.com/malsabbagh/review-sensei/blob/main/CHANGELOG.md
|
|
10
|
+
Keywords: code-review,github,reviewsensei
|
|
11
|
+
Classifier: Development Status :: 3 - Alpha
|
|
12
|
+
Classifier: Programming Language :: Python :: 3
|
|
13
|
+
Classifier: Programming Language :: Python :: 3.11
|
|
14
|
+
Requires-Python: >=3.11
|
|
15
|
+
Description-Content-Type: text/markdown
|
|
16
|
+
Requires-Dist: cryptography<51,>=44
|
|
17
|
+
Requires-Dist: review-sensei==0.6.23
|
|
18
|
+
|
|
19
|
+
# review-sensei-github
|
|
20
|
+
|
|
21
|
+
GitHub Actions runtime for [ReviewSensei](https://github.com/malsabbagh/review-sensei).
|
|
22
|
+
|
|
23
|
+
This distribution is the runner side of the hosted review: the OIDC broker
|
|
24
|
+
client, the session ledger, and GitHub publication. It is not the local review
|
|
25
|
+
engine. Install `review-sensei` for a local review against an LLM provider.
|
|
26
|
+
|
|
27
|
+
The reusable workflow installs the exact version this repository declares in
|
|
28
|
+
`packages/python/review-sensei-github/pyproject.toml`. That version depends on
|
|
29
|
+
one exact `review-sensei` release.
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
# review-sensei-github
|
|
2
|
+
|
|
3
|
+
GitHub Actions runtime for [ReviewSensei](https://github.com/malsabbagh/review-sensei).
|
|
4
|
+
|
|
5
|
+
This distribution is the runner side of the hosted review: the OIDC broker
|
|
6
|
+
client, the session ledger, and GitHub publication. It is not the local review
|
|
7
|
+
engine. Install `review-sensei` for a local review against an LLM provider.
|
|
8
|
+
|
|
9
|
+
The reusable workflow installs the exact version this repository declares in
|
|
10
|
+
`packages/python/review-sensei-github/pyproject.toml`. That version depends on
|
|
11
|
+
one exact `review-sensei` release.
|
|
@@ -0,0 +1,36 @@
|
|
|
1
|
+
[build-system]
|
|
2
|
+
requires = ["setuptools>=77.0"]
|
|
3
|
+
build-backend = "setuptools.build_meta"
|
|
4
|
+
|
|
5
|
+
[project]
|
|
6
|
+
name = "review-sensei-github"
|
|
7
|
+
version = "0.1.1"
|
|
8
|
+
description = "GitHub Actions runtime for ReviewSensei: broker, session ledger, and publication."
|
|
9
|
+
readme = "README.md"
|
|
10
|
+
requires-python = ">=3.11"
|
|
11
|
+
license = "MIT"
|
|
12
|
+
authors = [{ name = "Mohamad Alsabbagh" }]
|
|
13
|
+
keywords = ["code-review", "github", "reviewsensei"]
|
|
14
|
+
classifiers = [
|
|
15
|
+
"Development Status :: 3 - Alpha",
|
|
16
|
+
"Programming Language :: Python :: 3",
|
|
17
|
+
"Programming Language :: Python :: 3.11",
|
|
18
|
+
]
|
|
19
|
+
dependencies = [
|
|
20
|
+
"cryptography>=44,<51",
|
|
21
|
+
"review-sensei==0.6.23",
|
|
22
|
+
]
|
|
23
|
+
|
|
24
|
+
[project.urls]
|
|
25
|
+
Homepage = "https://github.com/malsabbagh/review-sensei"
|
|
26
|
+
Source = "https://github.com/malsabbagh/review-sensei"
|
|
27
|
+
Changelog = "https://github.com/malsabbagh/review-sensei/blob/main/CHANGELOG.md"
|
|
28
|
+
|
|
29
|
+
[project.scripts]
|
|
30
|
+
review-sensei-github = "review_sensei_github.cli:main"
|
|
31
|
+
|
|
32
|
+
[tool.setuptools.packages.find]
|
|
33
|
+
where = ["src"]
|
|
34
|
+
|
|
35
|
+
[tool.setuptools.package-data]
|
|
36
|
+
review_sensei_github = ["fixtures/*.yml"]
|
|
@@ -0,0 +1,189 @@
|
|
|
1
|
+
"""GitHub App identity, installation-time setup, and webhook safety.
|
|
2
|
+
|
|
3
|
+
This package is a narrow transport/auth boundary outside the provider-neutral
|
|
4
|
+
review core. It owns GitHub App JWTs, installation-token exchange, token
|
|
5
|
+
caching, webhook signature verification, sanitized webhook failures, and
|
|
6
|
+
idempotent installation-time setup pull request bootstrap for optional
|
|
7
|
+
App-identity comments, reviews, or setup.
|
|
8
|
+
"""
|
|
9
|
+
|
|
10
|
+
from .application import GitHubApplication, GitHubWriteOptions
|
|
11
|
+
from .auth import (
|
|
12
|
+
AppInstallationToken,
|
|
13
|
+
EnvPrivateKeySource,
|
|
14
|
+
FilePrivateKeySource,
|
|
15
|
+
GitHubAppAuth,
|
|
16
|
+
GitHubTokenTransport,
|
|
17
|
+
InstallationToken,
|
|
18
|
+
InstallationTokenScope,
|
|
19
|
+
PrivateKeySource,
|
|
20
|
+
RequestedPermissions,
|
|
21
|
+
)
|
|
22
|
+
from .broker import (
|
|
23
|
+
DEFAULT_BROKER_AUDIENCE,
|
|
24
|
+
ApprovedWorkflow,
|
|
25
|
+
AuditRecord,
|
|
26
|
+
AuditSink,
|
|
27
|
+
BrokerPolicy,
|
|
28
|
+
ForkChecker,
|
|
29
|
+
GitHubForkChecker,
|
|
30
|
+
GitHubInstallationLookup,
|
|
31
|
+
InMemoryAuditSink,
|
|
32
|
+
InMemoryInstallationMapping,
|
|
33
|
+
InstallationMapping,
|
|
34
|
+
OIDCBroker,
|
|
35
|
+
RateLimiter,
|
|
36
|
+
TokenBucketRateLimiter,
|
|
37
|
+
)
|
|
38
|
+
from .broker_client import BrokerClient
|
|
39
|
+
from .conversation import ConversationPublisher, PreparedConversation, ReplyResult
|
|
40
|
+
from .errors import (
|
|
41
|
+
BrokerPolicyError,
|
|
42
|
+
BrokerRateLimitError,
|
|
43
|
+
BrokerRejectionError,
|
|
44
|
+
GitHubAuthConfigurationError,
|
|
45
|
+
GitHubAuthError,
|
|
46
|
+
GitHubAuthInsufficientPermissionError,
|
|
47
|
+
GitHubAuthTransientError,
|
|
48
|
+
GitHubAuthUnavailableInstallationError,
|
|
49
|
+
GitHubBrokerClientError,
|
|
50
|
+
GitHubConversationError,
|
|
51
|
+
GitHubConversationTransientError,
|
|
52
|
+
GitHubHTTPError,
|
|
53
|
+
GitHubHTTPPaginationLimitError,
|
|
54
|
+
GitHubHTTPResponseTooLargeError,
|
|
55
|
+
GitHubHTTPTransientError,
|
|
56
|
+
GitHubLearningProposalError,
|
|
57
|
+
GitHubLearningProposalTransientError,
|
|
58
|
+
GitHubOIDCAudienceError,
|
|
59
|
+
GitHubOIDCClaimsError,
|
|
60
|
+
GitHubOIDCError,
|
|
61
|
+
GitHubOIDCExpiredError,
|
|
62
|
+
GitHubOIDCInvalidTokenError,
|
|
63
|
+
GitHubOIDCIssuerError,
|
|
64
|
+
GitHubOIDCSignatureError,
|
|
65
|
+
GitHubPublicationError,
|
|
66
|
+
GitHubPublicationTransientError,
|
|
67
|
+
GitHubSetupError,
|
|
68
|
+
GitHubSetupTransientError,
|
|
69
|
+
GitHubWebhookError,
|
|
70
|
+
GitHubWebhookSignatureError,
|
|
71
|
+
)
|
|
72
|
+
from .http import GitHubHttp
|
|
73
|
+
from .jwt import JWTAlgorithms, decode_jwt_parts, jwt_encode_rs256
|
|
74
|
+
from .learning_pr import LearningPRPublisher, LearningPRResult
|
|
75
|
+
from .oidc import (
|
|
76
|
+
DEFAULT_OIDC_ISSUER,
|
|
77
|
+
HttpJwksFetcher,
|
|
78
|
+
JwksFetcher,
|
|
79
|
+
VerifiedOIDCClaims,
|
|
80
|
+
verify_oidc_token,
|
|
81
|
+
)
|
|
82
|
+
from .publication import PublicationResult, ReviewPublisher
|
|
83
|
+
from .session_ledger import GitHubIssueCommentSessionLedger
|
|
84
|
+
from .setup import (
|
|
85
|
+
GitHubSetupClient,
|
|
86
|
+
GitHubSetupTransport,
|
|
87
|
+
SetupFile,
|
|
88
|
+
SetupPlan,
|
|
89
|
+
SetupPlanBuilder,
|
|
90
|
+
SetupPullRequestResult,
|
|
91
|
+
SetupPullRequestService,
|
|
92
|
+
)
|
|
93
|
+
from .webhooks import (
|
|
94
|
+
DeliveryLedger,
|
|
95
|
+
EnvWebhookSecretSource,
|
|
96
|
+
InMemoryDeliveryLedger,
|
|
97
|
+
VerifiedDelivery,
|
|
98
|
+
WebhookSecretSource,
|
|
99
|
+
WebhookVerifier,
|
|
100
|
+
)
|
|
101
|
+
|
|
102
|
+
__all__ = [
|
|
103
|
+
"AppInstallationToken",
|
|
104
|
+
"ApprovedWorkflow",
|
|
105
|
+
"AuditRecord",
|
|
106
|
+
"AuditSink",
|
|
107
|
+
"BrokerClient",
|
|
108
|
+
"BrokerPolicy",
|
|
109
|
+
"BrokerPolicyError",
|
|
110
|
+
"BrokerRateLimitError",
|
|
111
|
+
"BrokerRejectionError",
|
|
112
|
+
"ConversationPublisher",
|
|
113
|
+
"PreparedConversation",
|
|
114
|
+
"DEFAULT_BROKER_AUDIENCE",
|
|
115
|
+
"DEFAULT_OIDC_ISSUER",
|
|
116
|
+
"EnvPrivateKeySource",
|
|
117
|
+
"FilePrivateKeySource",
|
|
118
|
+
"ForkChecker",
|
|
119
|
+
"GitHubApplication",
|
|
120
|
+
"GitHubAppAuth",
|
|
121
|
+
"GitHubBrokerClientError",
|
|
122
|
+
"GitHubAuthConfigurationError",
|
|
123
|
+
"GitHubAuthError",
|
|
124
|
+
"GitHubAuthInsufficientPermissionError",
|
|
125
|
+
"GitHubAuthTransientError",
|
|
126
|
+
"GitHubAuthUnavailableInstallationError",
|
|
127
|
+
"GitHubConversationError",
|
|
128
|
+
"GitHubConversationTransientError",
|
|
129
|
+
"GitHubForkChecker",
|
|
130
|
+
"GitHubHTTPError",
|
|
131
|
+
"GitHubHTTPPaginationLimitError",
|
|
132
|
+
"GitHubHTTPResponseTooLargeError",
|
|
133
|
+
"GitHubHTTPTransientError",
|
|
134
|
+
"GitHubHttp",
|
|
135
|
+
"GitHubIssueCommentSessionLedger",
|
|
136
|
+
"GitHubInstallationLookup",
|
|
137
|
+
"GitHubLearningProposalError",
|
|
138
|
+
"GitHubLearningProposalTransientError",
|
|
139
|
+
"GitHubOIDCAudienceError",
|
|
140
|
+
"GitHubOIDCClaimsError",
|
|
141
|
+
"GitHubOIDCError",
|
|
142
|
+
"GitHubOIDCExpiredError",
|
|
143
|
+
"GitHubOIDCInvalidTokenError",
|
|
144
|
+
"GitHubOIDCIssuerError",
|
|
145
|
+
"GitHubOIDCSignatureError",
|
|
146
|
+
"GitHubPublicationError",
|
|
147
|
+
"GitHubPublicationTransientError",
|
|
148
|
+
"GitHubSetupClient",
|
|
149
|
+
"GitHubSetupError",
|
|
150
|
+
"GitHubSetupTransientError",
|
|
151
|
+
"GitHubSetupTransport",
|
|
152
|
+
"GitHubTokenTransport",
|
|
153
|
+
"InstallationToken",
|
|
154
|
+
"InstallationTokenScope",
|
|
155
|
+
"InstallationMapping",
|
|
156
|
+
"InMemoryAuditSink",
|
|
157
|
+
"InMemoryInstallationMapping",
|
|
158
|
+
"DeliveryLedger",
|
|
159
|
+
"EnvWebhookSecretSource",
|
|
160
|
+
"InMemoryDeliveryLedger",
|
|
161
|
+
"JWTAlgorithms",
|
|
162
|
+
"LearningPRPublisher",
|
|
163
|
+
"LearningPRResult",
|
|
164
|
+
"PrivateKeySource",
|
|
165
|
+
"PublicationResult",
|
|
166
|
+
"RequestedPermissions",
|
|
167
|
+
"ReplyResult",
|
|
168
|
+
"ReviewPublisher",
|
|
169
|
+
"GitHubWriteOptions",
|
|
170
|
+
"HttpJwksFetcher",
|
|
171
|
+
"JwksFetcher",
|
|
172
|
+
"OIDCBroker",
|
|
173
|
+
"RateLimiter",
|
|
174
|
+
"SetupFile",
|
|
175
|
+
"SetupPlan",
|
|
176
|
+
"SetupPlanBuilder",
|
|
177
|
+
"SetupPullRequestResult",
|
|
178
|
+
"SetupPullRequestService",
|
|
179
|
+
"TokenBucketRateLimiter",
|
|
180
|
+
"VerifiedDelivery",
|
|
181
|
+
"VerifiedOIDCClaims",
|
|
182
|
+
"WebhookSecretSource",
|
|
183
|
+
"WebhookVerifier",
|
|
184
|
+
"decode_jwt_parts",
|
|
185
|
+
"jwt_encode_rs256",
|
|
186
|
+
"verify_oidc_token",
|
|
187
|
+
"GitHubWebhookError",
|
|
188
|
+
"GitHubWebhookSignatureError",
|
|
189
|
+
]
|