{% set name = "jupyterlab_server" %}
{% set version = "2.25.1" %}

package:
  name: {{ name|lower }}
  version: {{ version }}

source:
  url: https://pypi.io/packages/source/{{ name[0] }}/{{ name }}/{{ name }}-{{ version }}.tar.gz
  sha256: 6491283b0000698eae1a38c48507930560dfcf7461aea0015368698aab34dd9c

build:
  number: 0
  # jupyterlab_server isn't available on s390x yet.
  skip: true  # [py<38 or s390x]
  script: {{ PYTHON }} -m pip install . --no-deps --no-build-isolation --ignore-installed --no-cache-dir -vvv

requirements:
  host:
    - python
    - pip
    - hatchling >=1.7
  run:
    - python
    - babel >=2.10
    - importlib-metadata >=4.8.3  # [py<310]
    - jinja2 >=3.0.3
    - json5 >=0.9.0
    - jsonschema >=4.18.0
    - jupyter_server >=1.21,<3
    - packaging >=21.3
    - requests >=2.31

test:
  requires:
    - pip
  imports:
    - jupyterlab_server
  commands:
    - python -m pip check 
  # downstreams:
    # Additional testing for downstream package jupyterlab
    #- jupyterlab

about:
  home: https://github.com/jupyterlab/jupyterlab_server
  license: BSD-3-Clause
  license_family: BSD
  license_file: LICENSE
  summary: A set of server components for JupyterLab and JupyterLab like applications.
  description: |
    JupyterLab Server sits between JupyterLab and Jupyter Server, and provides a
    set of REST API handlers and utilities that are used by JupyterLab. It is a
    separate project in order to accommodate creating JupyterLab-like
    applications from a more limited scope.
  dev_url: https://github.com/jupyterlab/jupyterlab_server
  doc_url: https://jupyterlab-server.readthedocs.io

extra:
  skip-lints:
    # `packaging` is required, noted as a dependency by upstream:
    # https://github.com/jupyterlab/jupyterlab_server/blob/v2.22.0/pyproject.toml#L36
    # It is worth noting that the project still builds without it.
    - python_build_tool_in_run
  recipe-maintainers:
    - jasongrout
    - blink1073
    - afshin
    - SylvainCorlay
    - bollwyvl
    - jtpio
