gemini-code-assist[bot] commented on code in PR #135:
URL: https://github.com/apache/tvm-ffi/pull/135#discussion_r2433612420


##########
pyproject.toml:
##########
@@ -43,14 +43,25 @@ GitHub = "https://github.com/apache/tvm-ffi";
 torch = ["torch", "setuptools", "ninja"]
 cpp = ["ninja"]
 # note pytorch does not yet ship with 3.14t
-test = [
+test = ["pytest", "numpy", "ninja", "torch>=2.9"]
+
+[dependency-groups]

Review Comment:
   ![medium](https://www.gstatic.com/codereviewagent/medium-priority.svg)
   
   The `[dependency-groups]` table is not standard according to PEP 621. 
Optional dependencies should be defined under 
`[project.optional-dependencies]`. This project already uses 
`[project.optional-dependencies]` for the `test` extra. For consistency and to 
follow standards, the `dev` group (and the existing `docs` group) should be 
moved there.
   
   This would make them installable via `pip install .[dev]` and `pip install 
.[docs]`.



##########
pyproject.toml:
##########
@@ -83,12 +94,14 @@ tvm-ffi-config = "tvm_ffi.config:__main__"
 tvm-ffi-stubgen = "tvm_ffi.stub.stubgen:__main__"
 
 [build-system]
-requires = ["scikit-build-core>=0.10.0", "cython", "cmake>=3.18"]
+requires = ["scikit-build-core>=0.10.0", "cython", "cmake>=3.18", "ninja"]
 build-backend = "scikit_build_core.build"
 
 [tool.scikit-build]
 wheel.py-api = "cp312"
 minimum-version = "build-system.requires"
+ninja.version = ">=1.11"
+ninja.make-fallback = false

Review Comment:
   ![medium](https://www.gstatic.com/codereviewagent/medium-priority.svg)
   
   According to the `scikit-build-core` documentation, the recommended way to 
specify a version for a build tool like Ninja is to add it with a version 
specifier to `build-system.requires`. The `tool.scikit-build.ninja.version` 
setting is only used if `ninja` is *not* present in `build-system.requires`.
   
   To avoid redundancy and potential conflicts, you should specify the version 
constraint for `ninja` directly in `build-system.requires` and remove the 
`ninja.version` key from `[tool.scikit-build]`.
   
   ```suggestion
   requires = ["scikit-build-core>=0.10.0", "cython", "cmake>=3.18", 
"ninja>=1.11"]
   build-backend = "scikit_build_core.build"
   
   [tool.scikit-build]
   wheel.py-api = "cp312"
   minimum-version = "build-system.requires"
   ninja.make-fallback = false
   ```



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to