-
Notifications
You must be signed in to change notification settings - Fork 147
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
Declare metadata in pyproject.toml, remove hatch-nodejs-version plugin #427
Merged
consideRatio
merged 4 commits into
jupyterhub:main
from
consideRatio:pr/pyproject.toml-metadata
Nov 17, 2023
Merged
Changes from all commits
Commits
Show all changes
4 commits
Select commit
Hold shift + click to select a range
16bb77c
Declare metadata in pyproject.toml, remove hatch-nodejs-version plugin
consideRatio 09e6279
Add back all metadata to labextension/package.json
consideRatio 821036a
Define python package specific description in pyproject.toml
consideRatio 1234bab
Stop declaring version dynamically in pyproject.toml
consideRatio File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
# __version__ should be updated using tbump, based on configuration in | ||
# pyproject.toml, according to instructions in RELEASE.md. | ||
# | ||
__version__ = "4.1.1-0.dev" | ||
consideRatio marked this conversation as resolved.
Show resolved
Hide resolved
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -4,9 +4,8 @@ | |
[build-system] | ||
build-backend = "hatchling.build" | ||
requires = [ | ||
"hatch-jupyter-builder >=0.5", | ||
"hatch-nodejs-version", | ||
"hatchling >=1.4.0", | ||
"hatch-jupyter-builder >=0.8.3", | ||
"hatchling >=1.18.0", | ||
"jupyterlab >=4.0.6,<5.0.0a0", | ||
] | ||
|
||
|
@@ -17,12 +16,13 @@ requires = [ | |
# | ||
[project] | ||
name = "jupyter_server_proxy" | ||
dynamic = [ | ||
"authors", | ||
"description", | ||
"keywords", | ||
"urls", | ||
"version", | ||
version = "4.1.1-0.dev" | ||
description = "A Jupyter server extension to run additional processes and proxy to them that comes bundled JupyterLab extension to launch pre-defined processes." | ||
keywords = ["jupyter", "jupyterlab", "jupyterlab-extension"] | ||
authors = [ | ||
{ name = "Ryan Lovett", email = "[email protected]" }, | ||
{ name = "Yuvi Panda", email = "[email protected]" }, | ||
{ name = "Jupyter Development Team", email = "[email protected]" }, | ||
] | ||
readme = "README.md" | ||
license = { file = "LICENSE" } | ||
|
@@ -75,10 +75,14 @@ lab = [ | |
"notebook >=7", | ||
] | ||
|
||
[tool.hatch.version] | ||
source = "nodejs" | ||
path = "labextension/package.json" | ||
[project.urls] | ||
Documentation = "https://jupyter-server-proxy.readthedocs.io" | ||
Source = "https://github.com/jupyterhub/jupyter-server-proxy" | ||
Tracker = "https://github.com/jupyterhub/jupyter-server-proxy/issues" | ||
|
||
|
||
# hatch ref: https://hatch.pypa.io/latest/ | ||
# | ||
[tool.hatch.build.targets.sdist] | ||
artifacts = [ | ||
"jupyter_server_proxy/labextension", | ||
|
@@ -101,10 +105,6 @@ exclude = [ | |
# Set to true to allow testing of git+https://github.com/user/repo@sha dependencies | ||
allow-direct-references = false | ||
|
||
[tool.hatch.metadata.hooks.nodejs] | ||
path = "labextension/package.json" | ||
fields = ["description", "authors", "urls"] | ||
|
||
[tool.hatch.build.hooks.jupyter-builder] | ||
build-function = "hatch_jupyter_builder.npm_builder" | ||
ensured-targets = [ | ||
|
@@ -187,6 +187,9 @@ regex = ''' | |
message_template = "Bump to {new_version}" | ||
tag_template = "v{new_version}" | ||
|
||
[[tool.tbump.file]] | ||
src = "pyproject.toml" | ||
|
||
[[tool.tbump.file]] | ||
src = "labextension/package.json" | ||
|
||
|
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
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.
Perhaps add an
__all__
so this doesn't have to benoqa
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.
Would you like the
__all__
list everythign currently exported or only some attributes (possibly breaking)?Ideally, we'd have
__all__
listing only what was needed to be exported historically, but I'm not confident on constraining what we export at this point.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 guess once something has been hoisted to
__init__.py
, for whatever reason, it is part of the public API. Doing in-the-wild searching sounds more tiresome.This might be an appropriate time to consider getting on the recent push to get more of the stack working with
mypy
, with a backstop of theunused-imports
rules fromruff
, which can more generally be informed by sp-repo-review. This is likely better than making on-the-fly, case-by-case calls on specific repos.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.
That sounds interesting @bollwyvl! I'm not able to drive that effort as part of this PR though, feeling somewhat overloaded atm :/