You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Move _c_api_utils.py to version_converter package (#2401)
This PR moves `_c_api_utils.py` from `onnxscript/ir/passes/common/` to
`onnxscript/version_converter/` since it's only used by the version
converter module.
## Changes
- Moved `onnxscript/ir/passes/common/_c_api_utils.py` to
`onnxscript/version_converter/_c_api_utils.py`
- Updated import in `onnxscript/version_converter/__init__.py` from
`from onnxscript.ir.passes.common import _c_api_utils` to `from . import
_c_api_utils`
## Analysis
A codebase analysis confirmed that `_c_api_utils.py` is only imported
and used by the version converter:
- The file contains utilities for interfacing with ONNX C APIs,
specifically the `call_onnx_api` function
- It's only imported in `onnxscript/version_converter/__init__.py`
- It's not exported in any `__all__` lists
- No other modules reference or use this utility
Moving the file to the version converter package improves code
organization by colocating the utility with its sole consumer.
Fixes#2400.
<!-- START COPILOT CODING AGENT TIPS -->
---
💬 Share your feedback on Copilot coding agent for the chance to win a
$200 gift card! Click
[here](https://survey.alchemer.com/s3/8343779/Copilot-Coding-agent) to
start the survey.
---------
Co-authored-by: copilot-swe-agent[bot] <[email protected]>
Co-authored-by: justinchuby <[email protected]>
Co-authored-by: Justin Chu <[email protected]>
0 commit comments