Repository navigation
ci: fixes to the Lab environment publishing flow - #456
Conversation
The existing pyqasm environments use names like "pyqasm (v1.2.1)". The workflow now names new ones the same way, with kernel display name "Python 3 [pyqasm vX.Y.Z]". The backport rule reads the version from both name formats, in any case. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Argus reviewAuto-review is off for this repo. Tick the box below to run a review on this PR.
Estimated cost
Tip: you can also comment |
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
|
Important Review skippedAuto reviews are disabled on this repository. Please check the settings in the CodeRabbit UI or the ⚙️ Run configuration
You can disable this status message by setting the Use the checkbox below for a quick retry:
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
The test, lint and docs extras pulled in about 50 developer packages (pytest, pylint, mypy, black, sphinx, a second qbraid-cli) that no notebook uses. The environment now gets pyqasm with every other extra its release declares, plus ipykernel: 48 packages instead of 100. That is the live 1.2.1 environment plus the cli and pulse extras. matplotlib still comes from the visualization extra, so the explicit entry is gone. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Codecov Report✅ All modified and coverable lines are covered by tests. 📢 Thoughts on this report? Let us know! |
`qbraid envs create --logo` only takes a qBraid provider name, and pyqasm is not a provider. The new optional QBRAID_ENV_LOGO_URL variable takes the https URL of a PNG logo instead. Preflight checks that it serves image/png. After create, the script stores the URL on the local registry entry, which upload sends to the API, and writes it as the local kernel icon. Lab downloads the kernel icon from the API's logo on install. If the logo is missing after upload, the script sets it through the environment update route. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Use the pyqasm light and dark PNGs from qbraid-static-assets as the catalog logo. Lab uses the light one as the kernel icon. The optional QBRAID_ENV_LOGO_URL variable still overrides both. Drop QBRAID_ENV_LOGO, since pyqasm is not a qBraid provider. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
qbraid envs create copies the Python logo-svg.svg into the kernel directory. JupyterLab shows logo-svg ahead of logo-64x64.png, so the launcher kept the Python icon. Remove the SVG after setting the PNGs. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
|
|
Summary of changes
Follow-up to #455. This PR collects fixes to the Lab environment publishing flow (
publish-lab-env.yml,bin/publish_lab_env.py). It stays open while the staging and production runs find what needs to change.Changes so far
pyqasm (vX.Y.Z)instead ofpyqasm X.Y.Z, to match the existing pyqasm environments. The kernel display name isPython 3 [pyqasm vX.Y.Z]. The preflight duplicate-name check follows the new name.pyqasm (v1.2.1)as pyqasm.test,lintanddocsextras added about 50 developer packages: pytest, pylint, mypy, black, sphinx and a second qbraid-cli. The environment now gets pyqasm with every other extra the release declares, plusipykernel.pyqasm[cli,pulse,visualization], ipykernelThe 7 extra packages over 1.2.1 come from the
cliextra (typer, rich, click helpers) and thepulseextra (openpulse). A new user-facing extra is picked up from PyPI without a code change.pyqasm logo:
qbraid envs create --logoonly takes a qBraid provider name, and pyqasm is not a provider. The script now sets the pyqasm light and dark PNGs from qbraid-static-assets as the logo by default (pyqasm-light-no-text.png,pyqasm-dark-no-text.png). An optional variable,QBRAID_ENV_LOGO_URL, takes the https URL of a PNG and overrides both.QBRAID_ENV_LOGOis gone.image/png. Lab saves kernel icons as PNG files.logo-svg.svgthat the CLI copies into the kernel directory. JupyterLab showslogo-svgahead of the PNGs, so the launcher kept the Python icon.Neither GitHub Environment sets
QBRAID_ENV_LOGO_URL, so runs use the defaults.First staging run
Every step passed:
ubuntu-24.04with the system Python 3.12.3pyqasm_vq5daq, approved, and set as the latest of the default qBraid environment groupThe environment has since been deleted from staging.
Testing
createrun withqbraid-cli[envs]==0.16.10accepted the new name. The stored kernel display name isPython 3 [pyqasm v1.3.0]. The same run installed the new package set, and the smoke test passed on it.createrun with a logo URL wrote it as the kernel icon and stored it on the registry entry. Both default URLs serveimage/png, and the light one downloads byte for byte as the kernel icon.black,pylint(10.00) andactionlintpass. Mocked unit tests (46) pass, including acreatetest that fails without the SVG removal. They cover both name formats, the dev-extras exclusion, the default logos and override, the logo checks, and the upload fallback.