Skip to content
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

chore: verbose pypi deploys to catch errors #14441

Merged
merged 2 commits into from
Feb 7, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .github/actions/python/pypi-deploy/action.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ runs:
fi
fi
status=0
QUIET=1 BUILD_NUMBER=${OT_BUILD} make -C ${{ inputs.project }} clean deploy twine_repository_url=${{ inputs.repository_url }} pypi_username=opentrons pypi_password=${{ inputs.password }} || status=$?
CI=1 QUIET=1 BUILD_NUMBER=${OT_BUILD} make -C ${{ inputs.project }} clean deploy twine_repository_url=${{ inputs.repository_url }} pypi_username=opentrons pypi_password=${{ inputs.password }} || status=$?
if [[ ${status} != 0 ]] && [[ ${{ inputs.repository_url }} =~ "test.pypi.org" ]]; then
echo "upload failures allowed to test pypi"
exit 0
Expand Down
4 changes: 2 additions & 2 deletions api/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -199,8 +199,8 @@ emulator:
-$(python) -m opentrons.hardware_control.emulation.app

.PHONY: deploy
deploy: wheel
$(call python_upload_package,$(twine_auth_args),$(twine_repository_url),$(wheel_file))
deploy: wheel sdist
$(call python_upload_package,$(twine_auth_args),$(twine_repository_url),$(wheel_file),$(sdist_file))

# User must currently specify host, e.g.: `make term host=169.254.202.176`
.PHONY: term
Expand Down
4 changes: 2 additions & 2 deletions hardware/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -144,5 +144,5 @@ emulator:
echo "Nothing here yet"

.PHONY: deploy
deploy: wheel
$(call python_upload_package,$(twine_auth_args),$(twine_repository_url),$(wheel_file))
deploy: wheel sdist
$(call python_upload_package,$(twine_auth_args),$(twine_repository_url),$(wheel_file),$(sdist_file))
3 changes: 2 additions & 1 deletion scripts/python.mk
Original file line number Diff line number Diff line change
Expand Up @@ -68,8 +68,9 @@ endef
# parameter 1: auth arguments for twine
# parameter 2: repository url
# parameter 3: the wheel file to upload
# parameter 4: the sdist to upload
define python_upload_package
$(python) -m twine upload --repository-url $(2) $(1) $(3)
$(python) -m twine upload $(and $(CI),--verbose) --repository-url $(2) $(1) $(3) $(4)
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'd be down for --verbose to be unconditional, if that simplifies things.

endef

# Get an enhanced version dict of the project
Expand Down
4 changes: 2 additions & 2 deletions shared-data/python/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -118,8 +118,8 @@ push-ot3: push-no-restart-ot3
$(call restart-server,$(host),$(ssh_key),$(ssh_opts),opentrons-robot-server)

.PHONY: deploy
deploy: wheel
$(call python_upload_package,$(twine_auth_args),$(twine_repository_url),$(wheel_file))
deploy: wheel sdist
$(call python_upload_package,$(twine_auth_args),$(twine_repository_url),$(wheel_file),$(sdist_file))

.PHONY: test
test:
Expand Down
Loading