This repository was archived by the owner on Feb 5, 2026. It is now read-only.
-
-
Notifications
You must be signed in to change notification settings - Fork 466
This repository was archived by the owner on Feb 5, 2026. It is now read-only.
package in rye workspace cannot depend on another workspace package for build-system requirements #813
Copy link
Copy link
Open
Description
Steps to Reproduce
pyproject.toml
[project]
name = "my-workspace"
version = "0.0.0"
[tool.rye]
virtual = true
[tool.rye.workspace]
members = [
"src/my-setuptools-extension",
"src/my-app",
]src/my-setuptools-extension/pyproject.toml
[build-system]
requires = [
"setuptools",
"wheel",
]
build-backend = "setuptools.build_meta"
[project]
name = "my-setuptools-extension"
version = "0.0.0"
dependencies = [
"setuptools",
]
[project.entry-points."distutils.commands"]
build_webassets = "my_setuptools_ext:BuildWebAssetsCommand"src/my-app/pyproject.toml
[build-system]
requires = [
"setuptools",
"wheel",
"my-setuptools-extension",
]
build-backend = "setuptools.build_meta"
[project]
name = "my-app"
version = "0.0.0"src/my-app/setup.py
This step is optional and here for completeness.
import setuptools # noqa: F401 isort:skip must import before distutils
from distutils.command.build import build as _BuildCommand
from setuptools import setup
from setuptools.command.develop import develop as _DevelopCommand
from setuptools.command.sdist import sdist as _SDistCommand
class SDistCommand(_SDistCommand):
sub_commands = [('build_webassets', None)] + _SDistCommand.sub_commands
class BuildCommand(_BuildCommand):
sub_commands = [('build_webassets', None)] + _DevelopCommand.sub_commands
class DevelopCommand(_DevelopCommand):
def run(self):
self.run_command('build_webassets')
_DevelopCommand.run(self)
setup(
cmdclass={
'sdist': SDistCommand,
'develop': DevelopCommand,
'build': BuildCommand,
}
)Expected Result
The workspace should support build-system.requires such that it is built and made available for other packages in the workspace to use.
Actual Result
❯ rye sync
Initializing new virtualenv in /Users/luser/scratch/rye-test/.venv
Python version: cpython@3.12.1
Generating production lockfile: /Users/luser/scratch/rye-test/requirements.lock
error: Failed to build editables
Caused by: Failed to build editable: file:///Users/luser/scratch/rye-test/src/my-app
Caused by: Failed to install requirements from build-system.requires (resolve)
Caused by: No solution found when resolving: setuptools, wheel, my-setuptools-extension
Caused by: Because my-setuptools-extension was not found in the package registry and you require my-setuptools-extension, we can conclude that the requirements are unsatisfiable.
error: could not write production lockfile for workspace
Caused by:
failed to generate lockfile
Rye isn't solving this problem and assuming the requirements are in a remote registry.
Version Info
rye 0.27.0
commit: 0.27.0 (2024-02-26)
platform: macos (aarch64)
self-python: cpython@3.12
symlink support: true
uv enabled: true
Additional info
In our current repo, we do this by running a specific build step plus find-links:
$ env/bin/pip wheel -w wheels src/my-setuptools-extension
$ env/bin/pip install --find-links wheels -e src/my-app
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
No labels