Skip to content

Commit 579a173

Browse files
committed
Update fork with upstream changes
2 parents c15940b + d8b9f16 commit 579a173

102 files changed

Lines changed: 6722 additions & 1196 deletions

File tree

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

.codacy.yml

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,9 @@
1+
---
2+
engines:
3+
bandit:
4+
enabled: true
5+
arguments:
6+
- "-s"
7+
- "B101"
8+
exclude_paths:
9+
- tests/**

.coderabbit.yaml

Lines changed: 1178 additions & 137 deletions
Large diffs are not rendered by default.

.github/ISSUE_TEMPLATE/01_good_first_issue_candidate.yml

Lines changed: 5 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -36,7 +36,7 @@ body:
3636
label: 🆕🐥 Newcomer Friendly
3737
description: Who is this issue for?
3838
value: |
39-
This **[Good First Issue](https://github.com/hiero-ledger/hiero-sdk-python/issues?q=is%3Aissue%20state%3Aopen%20label%3A%22Good%20First%20Issue%22%20no%3Aassignee)** is a guided, well-scoped task intended for new contributors to the Hiero Python SDK.
39+
This **[Good First Issue](https://github.com/hiero-ledger/hiero-sdk-python/issues?q=is%3Aissue%20state%3Aopen%20label%3A%22Good%20First%20Issue%22%20no%3Aassignee)** is a guided, well-scoped task intended for new human contributors to the Hiero Python SDK.
4040
4141
#### What you’ll do
4242
- ✅ understand how the repository is structured
@@ -269,7 +269,7 @@ body:
269269
270270
- [ ] **Connect** origin with upstream: [Guide](https://github.com/hiero-ledger/hiero-sdk-python/blob/main/docs/sdk_developers/training/workflow/03_staying_in_sync.md)
271271
272-
- [ ] **Install Packages** and protobufs: [Guide](https://github.com/hiero-ledger/hiero-sdk-python/blob/main/docs/sdk_developers/training/setup/02_installing_hiero_python_sdk.md) (or [Windows Setup Guide](https://github.com/hiero-ledger/hiero-sdk-python/blob/main/docs/sdk_developers/training/setup/setup_windows.md) for Windows users)
272+
- [ ] **Install Packages** and protobufs: [Guide](https://github.com/hiero-ledger/hiero-sdk-python/blob/main/docs/sdk_developers/training/setup/02_installing_hiero_python_sdk.md) (or [Windows Setup Guide](https://github.com/hiero-ledger/hiero-sdk-python/blob/main/docs/sdk_developers/setup_windows.md) for Windows users)
273273
274274
- [ ] **Sync Main** pull any recent upstream changes: [Guide](https://github.com/hiero-ledger/hiero-sdk-python/blob/main/docs/sdk_developers/rebasing.md)
275275
@@ -284,7 +284,7 @@ body:
284284
description: Provide a contribution workflow suitable for new contributors.
285285
value: |
286286
#### ✅ Get ready
287-
- [ ] **Claim the issue:** comment `/assign`: [Guide](https://github.com/hiero-ledger/hiero-sdk-python/blob/main/docs/sdk_developers/training/workflow/04_assigning_issues.md)
287+
- [ ] **Claim the issue:** comment `/assign`: [Guide](https://github.com/hiero-ledger/hiero-sdk-python/blob/main/docs/sdk_developers/training/workflow/04_assigning_issues.md). Pull requests created without being assigned will be automatically closed.
288288
289289
- [ ] **Double check the Issue and AI plan:** carefully re-read the issue description and the CodeRabbit AI plan
290290
@@ -310,7 +310,7 @@ body:
310310
311311
- [ ] **Complete the PR description:** briefly describe your changes, [Guide](https://github.com/hiero-ledger/hiero-sdk-python/blob/main/docs/sdk_developers/training/workflow/11_submit_pull_request.md)
312312
313-
- [ ] **Link the Issue:** link the issue the PR solves in the PR description, [Guide](https://github.com/hiero-ledger/hiero-sdk-python/blob/main/docs/sdk_developers/how_to_link_issues.md)
313+
- [ ] **Link the Issue:** link the issue the PR solves in the PR description, [Guide](https://github.com/hiero-ledger/hiero-sdk-python/blob/main/docs/sdk_developers/how_to_link_issues.md). Pull requests created without a linked issue will be automatically closed.
314314
315315
- [ ] **Submit the pull request:** click `**Create pull request**` 🎉
316316
@@ -394,12 +394,7 @@ body:
394394
label: 🤖 AI usage guidelines
395395
description: Guidance on using AI tools responsibly for this issue.
396396
value: |
397-
You’re welcome to use AI tools while working on this issue.
398-
399-
Many contributors do — especially for:
400-
- understanding unfamiliar code
401-
- drafting small refactors
402-
- sanity-checking approaches
397+
Humans are welcome to use AI tools while working on this issue but we do not accept AI bot-authored PRs.
403398
404399
**Use AI responsibly:**
405400
- review suggestions carefully

.github/ISSUE_TEMPLATE/02_good_first_issue.yml

Lines changed: 5 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@ body:
2020
label: 🆕🐥 Newcomer Friendly
2121
description: Who is this issue for?
2222
value: |
23-
This **[Good First Issue](https://github.com/hiero-ledger/hiero-sdk-python/issues?q=is%3Aissue%20state%3Aopen%20label%3A%22Good%20First%20Issue%22%20no%3Aassignee)** is a guided, well-scoped task intended for new contributors to the Hiero Python SDK.
23+
This **[Good First Issue](https://github.com/hiero-ledger/hiero-sdk-python/issues?q=is%3Aissue%20state%3Aopen%20label%3A%22Good%20First%20Issue%22%20no%3Aassignee)** is a guided, well-scoped task intended for new human contributors to the Hiero Python SDK.
2424
2525
#### What you’ll do
2626
- ✅ understand how the repository is structured
@@ -253,7 +253,7 @@ body:
253253
254254
- [ ] **Connect** origin with upstream: [Guide](https://github.com/hiero-ledger/hiero-sdk-python/blob/main/docs/sdk_developers/training/workflow/03_staying_in_sync.md)
255255
256-
- [ ] **Install Packages** and protobufs: [Guide](https://github.com/hiero-ledger/hiero-sdk-python/blob/main/docs/sdk_developers/training/setup/02_installing_hiero_python_sdk.md) (or [Windows Setup Guide](https://github.com/hiero-ledger/hiero-sdk-python/blob/main/docs/sdk_developers/training/setup/setup_windows.md) for Windows users)
256+
- [ ] **Install Packages** and protobufs: [Guide](https://github.com/hiero-ledger/hiero-sdk-python/blob/main/docs/sdk_developers/training/setup/02_installing_hiero_python_sdk.md) (or [Windows Setup Guide](https://github.com/hiero-ledger/hiero-sdk-python/blob/main/docs/sdk_developers/setup_windows.md) for Windows users)
257257
258258
- [ ] **Sync Main** pull any recent upstream changes: [Guide](https://github.com/hiero-ledger/hiero-sdk-python/blob/main/docs/sdk_developers/rebasing.md)
259259
@@ -268,7 +268,7 @@ body:
268268
description: Provide a contribution workflow suitable for new contributors.
269269
value: |
270270
#### ✅ Get ready
271-
- [ ] **Claim the issue:** comment `/assign`: [Guide](https://github.com/hiero-ledger/hiero-sdk-python/blob/main/docs/sdk_developers/training/workflow/04_assigning_issues.md)
271+
- [ ] **Claim the issue:** comment `/assign`: [Guide](https://github.com/hiero-ledger/hiero-sdk-python/blob/main/docs/sdk_developers/training/workflow/04_assigning_issues.md). Pull requests created without being assigned will be automatically closed.
272272
273273
- [ ] **Double check the Issue and AI plan:** carefully re-read the issue description and the CodeRabbit AI plan
274274
@@ -294,7 +294,7 @@ body:
294294
295295
- [ ] **Complete the PR description:** briefly describe your changes, [Guide](https://github.com/hiero-ledger/hiero-sdk-python/blob/main/docs/sdk_developers/training/workflow/11_submit_pull_request.md)
296296
297-
- [ ] **Link the Issue:** link the issue the PR solves in the PR description, [Guide](https://github.com/hiero-ledger/hiero-sdk-python/blob/main/docs/sdk_developers/how_to_link_issues.md)
297+
- [ ] **Link the Issue:** link the issue the PR solves in the PR description, [Guide](https://github.com/hiero-ledger/hiero-sdk-python/blob/main/docs/sdk_developers/how_to_link_issues.md). Pull requests created without a linked issue will be automatically closed.
298298
299299
- [ ] **Submit the pull request:** click `**Create pull request**` 🎉
300300
@@ -378,12 +378,7 @@ body:
378378
label: 🤖 AI usage guidelines
379379
description: Guidance on using AI tools responsibly for this issue.
380380
value: |
381-
You’re welcome to use AI tools while working on this issue.
382-
383-
Many contributors do — especially for:
384-
- understanding unfamiliar code
385-
- drafting small refactors
386-
- sanity-checking approaches
381+
Humans are welcome to use AI tools while working on this issue but we do not accept AI bot-authored PRs.
387382
388383
**Use AI responsibly:**
389384
- review suggestions carefully

.github/scripts/bot-assignment-check.sh

Lines changed: 20 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -35,8 +35,26 @@ issue_has_gfi() {
3535
[[ "$has" == "true" ]]
3636
}
3737

38+
# Count open assignments for a user
39+
# For triage users (mentors), excludes issues with 'mentor-duty' label
40+
# This allows mentors to be assigned to mentorship issues without consuming their assignment limit
3841
assignments_count() {
39-
gh issue list --repo "${REPO}" --assignee "${ASSIGNEE}" --state open --limit 100 --json number --jq 'length'
42+
local permission="${1:-none}"
43+
44+
if [[ "$permission" == "triage" ]]; then
45+
echo "Triage user detected — excluding mentor-duty issues from count." >&2
46+
# For triage users, exclude issues with 'mentor-duty' label
47+
gh api "repos/${REPO}/issues?per_page=100&page=1" \
48+
-f assignee="${ASSIGNEE}" \
49+
-f state=open \
50+
--jq '.[]
51+
| select(.pull_request == null)
52+
| select(any(.labels[]; .name == "mentor-duty") | not)
53+
| .number' | grep -c . || echo 0
54+
else
55+
# For non-triage users, count all open assignments
56+
gh issue list --repo "${REPO}" --assignee "${ASSIGNEE}" --state open --limit 100 --json number --jq 'length'
57+
fi
4058
}
4159

4260
remove_assignee() {
@@ -118,7 +136,7 @@ if is_spam_user; then
118136
echo "User is in spam list. Applying restricted assignment rules."
119137
fi
120138

121-
COUNT="$(assignments_count)"
139+
COUNT="$(assignments_count "$PERMISSION")"
122140

123141
# Apply assignment rules
124142
if [[ "$SPAM" == "true" ]]; then

0 commit comments

Comments
 (0)