fix(hipdnn): expose python error code bindings#9290
Conversation
❌ PR Check — Action Required
📖 Need help? See the Policy FAQ for details on every check and how to fix failures. |
|
🚫 Please fix the failed policies before requesting reviews. The following policy checks failed:
The |
|
|
||
|
|
||
| def _error_code_names_from_header() -> list[str]: | ||
| error_header = _hipdnn_project_root() / "frontend/include/hipdnn_frontend/Error.hpp" |
There was a problem hiding this comment.
This may be harder to do later when the bindings move out, but for now this is the best we got for making sure the bindings don't get out of sync with the cpp
Codecov Report✅ All modified and coverable lines are covered by tests. ❌ Your project status has failed because the head coverage (76.84%) is below the target coverage (80.00%). You can increase the head coverage or adjust the target coverage. Additional details and impacted files@@ Coverage Diff @@
## develop #9290 +/- ##
========================================
Coverage 65.07% 65.07%
========================================
Files 2685 2685
Lines 422262 422262
Branches 62741 62741
========================================
+ Hits 274750 274754 +4
+ Misses 126793 126791 -2
+ Partials 20719 20717 -2
*This pull request uses carry forward flags. Click here to find out more. 🚀 New features to boost your workflow:
|
Summary
hipdnn_frontend::ErrorCodevalue through the Pythonhipdnn.ErrorCodenanobind enum.frontend/include/hipdnn_frontend/Error.hppand verifies each one is usable withhipdnn.Error.Risk assessment
Testing summary
uvx --system-certs pre-commit run --files projects/hipdnn/python/hipdnn_frontend/test/test_error_paths.py projects/hipdnn/python/src/types_bindings.cpp— passed.frontend/include/hipdnn_frontend/Error.hppagainstpython/src/types_bindings.cpp— passed.cmake -B build-superbuild -GNinja -DROCM_LIBS_ENABLE_COMPONENTS="hipdnn;miopen-provider" -DCMAKE_BUILD_TYPE=Release -DCMAKE_TOOLCHAIN_FILE=cmake/toolchains/rocm-clang.cmake -DCMAKE_INSTALL_PREFIX=/home/tvy/dev/WIP/worktrees/rocm-libraries/ALMIOPEN-2257/superbuild/install— blocked locally:/opt/rocm/lib/llvm/binis absent on this workstation.pytestred/green run was not available before environment setup because the workstation had nopytestcommand and no builthipdnn_frontend_pythonextension.Testing checklist
Technical changes
projects/hipdnn/python/src/types_bindings.cpp: adds missingErrorCodeenum values to the Python binding.projects/hipdnn/python/hipdnn_frontend/test/test_error_paths.py: addsTestErrorCodeBindingsto prevent future C++/Python enum drift.JIRA ID: ALMIOPEN-2257