Skip to content

Commit

Permalink
Merge pull request #427 from consideRatio/pr/pyproject.toml-metadata
Browse files Browse the repository at this point in the history
Declare metadata in pyproject.toml, remove hatch-nodejs-version plugin
  • Loading branch information
consideRatio authored Nov 17, 2023
2 parents 0c57b27 + 1234bab commit 55d4a9f
Show file tree
Hide file tree
Showing 3 changed files with 24 additions and 16 deletions.
1 change: 1 addition & 0 deletions jupyter_server_proxy/__init__.py
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
from jupyter_server.utils import url_path_join as ujoin

from ._version import __version__ # noqa
from .api import IconHandler, ServersInfoHandler
from .config import ServerProxy as ServerProxyConfig
from .config import get_entrypoint_server_processes, make_handlers, make_server_process
Expand Down
4 changes: 4 additions & 0 deletions jupyter_server_proxy/_version.py
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"
35 changes: 19 additions & 16 deletions pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -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",
]

Expand All @@ -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" }
Expand Down Expand Up @@ -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",
Expand All @@ -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 = [
Expand Down Expand Up @@ -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"

Expand Down

0 comments on commit 55d4a9f

Please sign in to comment.