[PR #87] [MERGED] feat: add submodule version+data hash info to --version --debug output #226

Closed
opened 2026-03-15 11:54:29 +03:00 by kerem · 0 comments
Owner

📋 Pull Request Information

Original PR: https://github.com/awslabs/iam-policy-autopilot/pull/87
Author: @hwei0
Created: 12/17/2025
Status: Merged
Merged: 1/12/2026
Merged by: @hwei0

Base: mainHead: main


📝 Commits (10+)

📊 Changes

10 files changed (+283 additions, -12 deletions)

View changed files

📝 Cargo.toml (+5 -2)
📝 iam-policy-autopilot-cli/src/commands.rs (+26 -1)
📝 iam-policy-autopilot-cli/src/main.rs (+21 -0)
📝 iam-policy-autopilot-policy-generation/Cargo.toml (+5 -0)
📝 iam-policy-autopilot-policy-generation/build.rs (+129 -9)
iam-policy-autopilot-policy-generation/src/api/get_submodule_version.rs (+28 -0)
📝 iam-policy-autopilot-policy-generation/src/api/mod.rs (+2 -0)
📝 iam-policy-autopilot-policy-generation/src/api/model.rs (+4 -0)
📝 iam-policy-autopilot-policy-generation/src/embedded_data.rs (+49 -0)
iam-policy-autopilot-policy-generation/src/shared_submodule_model.rs (+14 -0)

📄 Description

Issue #, if available:
#82

Description of changes:

added custom --version output to publish boto3, botocore git tag+commit+data hash (data hash is the hash of the simplified data files). This information will only be exposed if the hidden --debug flag is set; current --version behaviour without the --deubg flag will remain unchanged.

example output

./target/debug/iam-policy-autopilot --version --debug
0.1.2
boto3 version: commit_id=0ca53211df7d2bb2213436a6b19e8cf0b44dee7d, commit_tag=1.42.11, data_hash=8309474F524E2F3DE2F90ADA66F1C5C887358CC503846073663BA311783FF495
botocore version: commit_id=7c770fb210913ff9fa9b35470161c3278786085b, commit_tag=None, data_hash=615E77E2C8C1DD6FD471416D712F4FE5A8E66B45150DC5D4BDC192736A8A42F1

By submitting this pull request, I confirm that you can use, modify, copy, and redistribute this contribution, under the terms of your choice.


🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.

## 📋 Pull Request Information **Original PR:** https://github.com/awslabs/iam-policy-autopilot/pull/87 **Author:** [@hwei0](https://github.com/hwei0) **Created:** 12/17/2025 **Status:** ✅ Merged **Merged:** 1/12/2026 **Merged by:** [@hwei0](https://github.com/hwei0) **Base:** `main` ← **Head:** `main` --- ### 📝 Commits (10+) - [`912c890`](https://github.com/awslabs/iam-policy-autopilot/commit/912c890e670adcca79532fcc3f2333db76c51be3) feat: add version flag and submodule version+data info - [`9f79162`](https://github.com/awslabs/iam-policy-autopilot/commit/9f791626e9e873b49c7ebe0b887d9aca89377019) Merge branch 'main' of https://github.com/hwei0/iam-policy-autopilot - [`a6077d4`](https://github.com/awslabs/iam-policy-autopilot/commit/a6077d4458f34eb6d3fa348f1b65c94d11fa50c2) refactor: address comments in PR#87 - [`869f80a`](https://github.com/awslabs/iam-policy-autopilot/commit/869f80ab3195966c0d02f5ab933e76ba6c05a69e) refactor: fix clippy - [`fbf5280`](https://github.com/awslabs/iam-policy-autopilot/commit/fbf5280d56f0cd2ca4961f8dd01e51baeecadf87) fix: add openssl, libssl-dev dependenies to pr build workflow - [`59b4b63`](https://github.com/awslabs/iam-policy-autopilot/commit/59b4b638fda4dfbeb25a3e117a545bfa49d5cb6c) fix: try to resolve build failure with openssl vendored https://github.com/cross-rs/cross/wiki/Recipes#openssl - [`6af7ee6`](https://github.com/awslabs/iam-policy-autopilot/commit/6af7ee619794ef00d2761f181d7d3c5211af5bb0) Merge branch 'awslabs:main' into main - [`01b266b`](https://github.com/awslabs/iam-policy-autopilot/commit/01b266bada4b4ba9d3fdfe207a01c2a41e7fe9e6) refactor: reset BTreeMap to HashMap in build.rs serde structs, add comments to structs in build.rs - [`c4a739c`](https://github.com/awslabs/iam-policy-autopilot/commit/c4a739cd4acb90ca0f947b42304ee1e90b4327ff) refactor: reset to btree - [`340b7e7`](https://github.com/awslabs/iam-policy-autopilot/commit/340b7e705e9be42ab0b9fdae9a1e784388b7aaec) refactor: share submodule struct beteeen build.rs and api/model.rs in policy-generation; other refactors ### 📊 Changes **10 files changed** (+283 additions, -12 deletions) <details> <summary>View changed files</summary> 📝 `Cargo.toml` (+5 -2) 📝 `iam-policy-autopilot-cli/src/commands.rs` (+26 -1) 📝 `iam-policy-autopilot-cli/src/main.rs` (+21 -0) 📝 `iam-policy-autopilot-policy-generation/Cargo.toml` (+5 -0) 📝 `iam-policy-autopilot-policy-generation/build.rs` (+129 -9) ➕ `iam-policy-autopilot-policy-generation/src/api/get_submodule_version.rs` (+28 -0) 📝 `iam-policy-autopilot-policy-generation/src/api/mod.rs` (+2 -0) 📝 `iam-policy-autopilot-policy-generation/src/api/model.rs` (+4 -0) 📝 `iam-policy-autopilot-policy-generation/src/embedded_data.rs` (+49 -0) ➕ `iam-policy-autopilot-policy-generation/src/shared_submodule_model.rs` (+14 -0) </details> ### 📄 Description *Issue #, if available:* #82 *Description of changes:* added custom `--version` output to publish boto3, botocore git tag+commit+data hash (data hash is the hash of the simplified data files). **This information will only be exposed if the hidden `--debug` flag is set; current --version behaviour without the `--deubg` flag will remain unchanged.** example output ``` ./target/debug/iam-policy-autopilot --version --debug 0.1.2 boto3 version: commit_id=0ca53211df7d2bb2213436a6b19e8cf0b44dee7d, commit_tag=1.42.11, data_hash=8309474F524E2F3DE2F90ADA66F1C5C887358CC503846073663BA311783FF495 botocore version: commit_id=7c770fb210913ff9fa9b35470161c3278786085b, commit_tag=None, data_hash=615E77E2C8C1DD6FD471416D712F4FE5A8E66B45150DC5D4BDC192736A8A42F1 ``` By submitting this pull request, I confirm that you can use, modify, copy, and redistribute this contribution, under the terms of your choice. --- <sub>🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.</sub>
kerem 2026-03-15 11:54:29 +03:00
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
starred/iam-policy-autopilot#226
No description provided.