-
Notifications
You must be signed in to change notification settings - Fork 112
setup uv workspace #542
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
setup uv workspace #542
Conversation
theomonnom
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
SInce we're not using setuptools anymore. I don't think the build-rtc CI is still going to work as-is: https://github.com/livekit/python-sdks/blob/main/.github/workflows/build-rtc.yml
| class CustomBuildHook(BuildHookInterface): | ||
| def initialize(self, version, build_data): | ||
| """Force platform-specific wheel due to native libraries""" | ||
| build_data["pure_python"] = False | ||
| build_data["infer_tag"] = True |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Before making any release we should double-check this is working as expected.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Let's make a rc build first
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I had a look at the artifacts built as part of the rtc-build workflow and they appeared to be fine, anything else we need to check?
the workflow is succeeding on this PR, what specifically should I double check? |
Just checking that the binaries are indeed inside the wheel would be sufficient |
xianshijing-lk
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
one comment, lgtm in general
| @echo "$(BOLD)$(CYAN)Installing dependencies...$(RESET)" | ||
| @uv sync --all-extras --dev | ||
| @echo "$(BOLD)$(GREEN)✓ Dependencies installed$(RESET)" | ||
|
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I just went thru the setup as I was doing some manual tests before making the new release.
I got into multiple problems as it was my first time to run the tests on python-sdk. like missing submodule, missing audio files due to lfs, ..etc
I wonder if it makes sense to add a section like
sync: ## Sync repo, deps, and assets to a working dev state (safe to re-run)
@echo "$(BOLD)$(CYAN)🔄 Syncing development environment...$(RESET)"
@git submodule update --init --recursive
@git lfs install
@git lfs pull
@UV sync --dev
@$(MAKE) download-ffi
@echo "$(BOLD)$(GREEN)✓ Sync complete$(RESET)"
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
sounds good, I slightly modified it and added it under the name bootstrap
in the hope that there isn't a reason this wasn't set up for this repo in the first place, this PR sets up uv workspaces for this monorepo and adopts them in the CI.
Replicates the approach used in the agents repo and accordingly also migrates the build backend to hatch