Extract index generation into a separate module from upload_package_repo.py#3566
Conversation
Can you please post the link to the entry point allowing to browse the index files? |
|
@araravik-psd, please review. This addresses #3328, more refactoring might will be needed to fully address #3329. |
Sure, based on the log in here:
This should be the link below. However, I got |
In that case something went wrong here and you'll need to check via the AWS console. CF should be set-up correctly as I see redirects to index.html files for other runs working at https://rocm.devreleases.amd.com/rpm/. |
I think I was looking at the wrong entry point above. These two links are working fine: CC: @araravik-psd |
There was a problem hiding this comment.
LGTM
The jobs are showing the index files uploaded properly.
Generating indexes from S3: s3://therock-dev-packages/rpm/20260224-22322854136/ (recursive)
Uploading index: rpm/20260224-22322854136/x86_64/repodata/index.html
Uploading index: rpm/20260224-22322854136/x86_64/index.html
Uploading index: rpm/20260224-22322854136/index.html
Generated and uploaded 3 index files from S3 state
Generating top index from S3: s3://therock-dev-packages/rpm/
Uploading top index: rpm/index.html
Closes #3328 Follow up PR for #3566 Add unittests for `generate_package_indexes_test.py` script ``` pytest build_tools/packaging/tests/generate_package_indexes_test.py -vv =================================================================================== test session starts =================================================================================== platform linux -- Python 3.12.12, pytest-8.4.2, pluggy-1.6.0 -- /usr/bin/python3 cachedir: .pytest_cache rootdir: /home/nod/ergurses/TheRock/build_tools configfile: pyproject.toml collected 4 items build_tools/packaging/tests/generate_package_indexes_test.py::GeneratePackageIndexesTest::test_generate_index_from_s3_creates_indexes_and_links PASSED [ 25%] build_tools/packaging/tests/generate_package_indexes_test.py::GeneratePackageIndexesTest::test_generate_index_from_s3_respects_max_depth PASSED [ 50%] build_tools/packaging/tests/generate_package_indexes_test.py::GeneratePackageIndexesTest::test_generate_index_html_skips_dotfiles PASSED [ 75%] build_tools/packaging/tests/generate_package_indexes_test.py::GeneratePackageIndexesTest::test_generate_top_index_from_s3_lists_subfolders PASSED [100%] ==================================================================================== 4 passed in 0.11s ==================================================================================== ```
Motivation
Progress on #3328
This PR extracts the HTML index generation logic from
upload_package_repo.pyinto a separate module,generate_package_indexes.py.Technical Details
Test Plan
Run on CI
Test Result
Test: https://github.com/ROCm/TheRock/actions/runs/22338748161/job/64637174767
Submission Checklist