Unverified Commit d2ea2056 authored by Fabian Affolter's avatar Fabian Affolter Committed by GitHub
Browse files

Merge pull request #330489 from Sigmanificient/memray

memray: 1.11.0 -> 1.13.4
parents 241225a0 d77e3ba3
Loading
Loading
Loading
Loading
+41 −28
Original line number Diff line number Diff line
{ lib
, fetchFromGitHub
, libunwind
, lz4
, pkg-config
, python3
{
  lib,
  elfutils,
  fetchFromGitHub,
  libunwind,
  lz4,
  pkg-config,
  python3Packages,
}:

python3.pkgs.buildPythonApplication rec {
python3Packages.buildPythonApplication rec {
  pname = "memray";
  version = "1.11.0";
  format = "setuptools";
  version = "1.13.4";
  pyproject = true;

  src = fetchFromGitHub {
    owner = "bloomberg";
    repo = "memray";
    rev = "refs/tags/v${version}";
    hash = "sha256-DaJ1Hhg7q4ckA5feUx0twOsmy28v5aBBCTUAkn43xAo=";
    hash = "sha256-8ztnXNdsthoMvooWoJLKrB9yGHjkYhQ2jiwF3KujAnw=";
  };

  nativeBuildInputs = [
    pkg-config
  build-system = with python3Packages; [
    distutils
    setuptools
  ];

  nativeBuildInputs = [ pkg-config ];

  buildInputs = [
    libunwind
    lz4
  ] ++ (with python3.pkgs; [
    cython
  ]);
    elfutils # for `-ldebuginfod`
  ] ++ (with python3Packages; [ cython ]);

  propagatedBuildInputs = with python3.pkgs; [
  dependencies = with python3Packages; [
    pkgconfig
    textual
    jinja2
    rich
  ];

  nativeCheckInputs = with python3.pkgs; [
  nativeCheckInputs =
    with python3Packages;
    [
      ipython
      pytestCheckHook
  ] ++ lib.optionals (pythonOlder "3.12") [
    greenlet
  ];
      pytest-cov # fix Unknown pytest.mark.no_cover
    ]
    ++ lib.optionals (pythonOlder "3.12") [ greenlet ];

  pythonImportsCheck = [
    "memray"
  ];
  pythonImportsCheck = [ "memray" ];

  pytestFlagsArray = [
    "tests"
  ];
  pytestFlagsArray = [ "tests" ];

  disabledTests = [
    # Import issue
    "test_header_allocator"
    "test_hybrid_stack_of_allocations_inside_ceval"

    # snapshot-based tests are too fragile
    # see https://github.com/bloomberg/memray/issues/654
    "TestTUILooks"
    "test_tui_basic"
    "test_tui_pause"
    "test_tui_gradient"
    "test_merge_threads"
    "test_unmerge_threads"
  ];

  disabledTestPaths = [