Commit 3c695504 authored by Doron Behar's avatar Doron Behar
Browse files

python311Packages.pint: 0.23 -> 0.24

Switched to fetchFromGitHub, because upstream didn't add a release to
pypi, only on GitHub.
parent 12844b00
Loading
Loading
Loading
Loading
+16 −14
Original line number Diff line number Diff line
{
  lib,
  buildPythonPackage,
  fetchPypi,
  fetchFromGitHub,
  pythonOlder,

  # build-system
@@ -10,6 +10,9 @@

  # propagates
  typing-extensions,
  appdirs,
  flexcache,
  flexparser,

  # tests
  pytestCheckHook,
@@ -22,15 +25,16 @@

buildPythonPackage rec {
  pname = "pint";
  version = "0.23";
  version = "0.24";
  format = "pyproject";

  disabled = pythonOlder "3.6";

  src = fetchPypi {
    inherit version;
    pname = "Pint";
    hash = "sha256-4VCbkWBtvFJSfGAKTvdP+sEv/3Boiv8g6QckCTRuybQ=";
  src = fetchFromGitHub {
    owner = "hgrecco";
    repo = "pint";
    rev = "refs/tags/${version}";
    hash = "sha256-zMcLC3SSl/W7+xX4ah3ZV7fN/LIGJzatqH4MNK8/fec=";
  };

  nativeBuildInputs = [
@@ -38,7 +42,12 @@ buildPythonPackage rec {
    setuptools-scm
  ];

  propagatedBuildInputs = [ typing-extensions ];
  propagatedBuildInputs = [
    appdirs
    flexcache
    flexparser
    typing-extensions
  ];

  nativeCheckInputs = [
    pytestCheckHook
@@ -55,13 +64,6 @@ buildPythonPackage rec {
    export HOME=$(mktemp -d)
  '';

  disabledTests = [
    # https://github.com/hgrecco/pint/issues/1898
    "test_load_definitions_stage_2"
    # pytest8 deprecation
    "test_nonnumeric_magnitudes"
  ];

  meta = with lib; {
    changelog = "https://github.com/hgrecco/pint/blob/${version}/CHANGES";
    description = "Physical quantities module";