-
Notifications
You must be signed in to change notification settings - Fork 5k
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
Use hatch backend #6425
Use hatch backend #6425
Conversation
We're blocked by pypa/hatch#243. |
Found a workaround using |
FYI just released https://github.com/pypa/hatch/releases/tag/hatchling-v1.0.0 Also I think you can copy what you did here ipython/ipyparallel@e3e896a |
Thanks, and congratulations! |
We can remove |
It's undocumented until I find an auto-generator for non-Click CLIs, but if build deps are met you can do |
Thanks! Perhaps https://sphinx-argparse.readthedocs.io/en/stable/? |
Ah, you are using |
@jtpio, any idea why the snapshot tests are failing? |
Thanks! |
Hmm, after adding the schemas the tests don't appear to start at all. |
hmm strange. For the UI tests the package is first installed with the following:
Will check locally. |
add flake8 config add artifacts cleanup use tbump to get current version cleanup for new dep versions clean up workflows switch back to bumpversion fix verion fixup fixup fixup fixup fix version check fixups try version handling again version cleanup fix typescript error undo bump2version changes include schemas and add build timeouts fix workflow syntax more workflow cleanup clean up config
Ah I thought CI was already uploading the built assets as artifacts. Maybe we could add the following step to the check release workflow so it's easier to inspect the sdist and wheel? - name: Upload Distributions
uses: actions/upload-artifact@v2
with:
name: notebook-jupyter-releaser-dist-${{ github.run_number }}
path: .jupyter_releaser_checkout/dist |
Good call. I also played with my wip comparison script and got this output now:
|
Here's the latest output:
|
Looking good! |
The Binder for this PR fails to build because of the following error: Which seems to be related to the |
This is likely to be fixed by jupyterlab/jupyterlab#12606. |
Yeah I think we need to use a |
Drat, now we have the issue that symlinks can't be created over existing files. With |
Hatchling resolves symlinks fyi |
The issue is the JupyterLab build command is trying to create symlinks over the files that are placed into |
Ah, the symlink error was actually from a file in this repository, the binder is working now. I actually think this PR is good to go now. |
source = "code" | ||
|
||
[tool.hatch.build.targets.wheel.shared-data] | ||
"notebook/labextension" = "share/jupyter/labextensions/@jupyter-notebook/lab-extension" |
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.
@blink1073 I'm not an expert on the filesystem layout for JupyterLab extensions, but should this be
"notebook/labextension" = "share/jupyter/labextensions/@jupyter-notebook/lab-extension" | |
"notebook/labextension" = "share/jupyter/labextensions/@jupyter-notebook" |
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.
Looks like this should be kept since it maps to "notebook/labextension"
on the left hand side?
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.
Yes, I agree
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.
Hmm, I could be wrong but I thought the output directory contents were supposed to end up in share/jupyter/labextensions/@jupyter-notebook/
If you look e.g. at the wheel for jupyterlab-katex
, the contents of /jupyterlab_katex-3.3.0.data/data/share/jupyter/labextensions/@jupyterlab/katex-extension/
is
schemas
static
install.json
package.json
whereas in notebook's wheel we currently have the following files in /notebook-7.0.0a4.data/data/share/jupyter/labextensions/@jupyter-notebook/
:
lab-extension
E.g. this is jupyterlab-myst
which works: https://github.com/agoose77/jupyterlab-myst/blob/320b15187ee605b1f948619e9e1f9cfa672eaf00/pyproject.toml#L57
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.
The extension is nested in our case, under @jupyter-notebook
. The full extension name is @jupyter-notebook/lab-extension
.
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.
Right, I'm with you. This is where the fact that /
is allowed in NPM package names threw me for a second!
jupyter_config.json
Outdated
@@ -1,4 +0,0 @@ | |||
{ | |||
"LabApp": { "collaborative": true, "expose_app_in_browser": true }, | |||
"JupyterNotebookApp": { "collaborative": true, "expose_app_in_browser": 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.
Probably we want to keep this file, so RTC can be tested on Binder?
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.
Restored
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.
Thanks!!
Looking good on Binder and also locally using the assets built by the releaser.
Left a small comment about the config for testing RTC on Binder, but otherwise looks good!
Starting a new pre-release with this change. |
Ah looks like something is wrong with the Python version: #6448 |
setuptools
/jupyter-packaging