Unverified Commit f3cc7197 authored by Florian's avatar Florian Committed by GitHub
Browse files

Merge pull request #329403 from gador/datalad-gooey-init

datalad-gooey:  init at unstable-2024-02-20 
parents 556126cb e89304a6
Loading
Loading
Loading
Loading
+64 −0
Original line number Diff line number Diff line
{
  buildPythonPackage,
  lib,
  git,
  fetchFromGitHub,
  darwin,
  setuptools,
  stdenv,
  git-annex,
  pyside6,
  pyqtdarktheme,
  datalad-next,
  outdated,
  datalad,
  pytestCheckHook,
  pytest-qt,
}:

buildPythonPackage {
  pname = "datalad-gooey";
  # many bug fixes on `master` but no new release
  version = "unstable-2024-02-20";
  pyproject = true;

  src = fetchFromGitHub {
    owner = "datalad";
    repo = "datalad-gooey";
    rev = "5bd6b9257ff1569439d2a77663271f5d665e61b6";
    hash = "sha256-8779SLcV4wwJ3124lteGzvimDxgijyxa818ZrumPMs4=";
  };

  build-system = [ setuptools ];

  dependencies = [
    pyside6
    pyqtdarktheme
    datalad-next
    outdated
    datalad
  ] ++ lib.optionals stdenv.isDarwin [ darwin.apple_sdk.frameworks.AppleScriptKit ];

  pythonRemoveDeps = [ "applescript" ];

  preCheck = ''
    export HOME=$TMPDIR
  '';

  nativeCheckInputs = [
    pytestCheckHook
    pytest-qt
    git
    git-annex
  ];

  pythonImportsCheck = [ "datalad_gooey" ];

  meta = {
    description = "Graphical user interface (GUI) for DataLad";
    homepage = "https://github.com/datalad/datalad-gooey";
    license = lib.licenses.mit;
    maintainers = with lib.maintainers; [ gador ];
    mainProgram = "datalad-gooey";
  };
}
+115 −0
Original line number Diff line number Diff line
{
  annexremote,
  buildPythonPackage,
  datalad,
  datasalad,
  fetchFromGitHub,
  git,
  git-annex,
  humanize,
  lib,
  more-itertools,
  psutil,
  pytestCheckHook,
  setuptools,
  openssh,
  unzip,
  versioneer,
  webdavclient3,
}:

buildPythonPackage rec {
  pname = "datalad-next";
  version = "1.5.0";
  pyproject = true;

  src = fetchFromGitHub {
    owner = "datalad";
    repo = "datalad-next";
    rev = "refs/tags/${version}";
    hash = "sha256-fqP6nG2ncDRg48kvlsmPjNBOzfQp9+7wTcGvsYVrRzA=";
  };

  postPatch = ''
    # Remove vendorized versioneer.py
    rm versioneer.py
  '';

  nativeBuildInputs = [ git ];

  build-system = [
    setuptools
    versioneer
  ];

  dependencies = [
    annexremote
    datasalad
    datalad
    humanize
    more-itertools
  ];

  preCheck = ''
    export HOME=$TMPDIR
  '';

  nativeCheckInputs = [
    pytestCheckHook
    webdavclient3
    psutil
    git-annex
    datalad
    openssh
    unzip
  ];

  disabledTests = [
    # remotes available after datalad-next install (through `console_scripts`), but not yet in $PATH during test
    "test_uncurl_addurl_unredirected"
    "test_uncurl"
    "test_uncurl_ria_access"
    "test_uncurl_store"
    "test_uncurl_remove"
    "test_uncurl_testremote"
    "test_replace_add_archive_content"
    "test_annex_remote"
    "test_export_remote"
    "test_annex_remote_autorepush"
    "test_export_remote_autorepush"
    "test_typeweb_annex"
    "test_typeweb_annex_uncompressed"
    "test_typeweb_export"
    "test_submodule_url"
    "test_uncurl_progress_reporting_to_annex"
    "test_archivist_retrieval"
    "test_archivist_retrieval_legacy"

    # hardcoded /bin path
    "test_auto_if_wanted_data_transfer_path_restriction"

    # requires internet access
    "test_push_wanted"
    "test_auto_data_transfer"
    "test_http_url_operations"
    "test_transparent_decompression"
    "test_compressed_file_stay_compressed"
    "test_ls_file_collection_tarfile"
    "test_iter_tar"
  ];

  disabledTestPaths = [
    # requires internet access
    "datalad_next/commands/tests/test_download.py"
    "datalad_next/archive_operations/tests/test_tarfile.py"
  ];
  pythonImportsCheck = [ "datalad_next" ];

  meta = {
    description = "DataLad extension with a staging area for additional functionality, or for improved performance and user experience";
    changelog = "https://github.com/datalad/datalad-next/blob/main/CHANGELOG.md";
    homepage = "https://github.com/datalad/datalad-next";
    license = lib.licenses.mit;
    maintainers = with lib.maintainers; [ gador ];
  };
}
+55 −10
Original line number Diff line number Diff line
{
  buildPythonPackage,
  lib,
  setuptools,
  stdenv,
  fetchFromGitHub,
  installShellFiles,
  python3,
  git,
  coreutils,
  versioneer,
  # core
  platformdirs,
  chardet,
  iso8601,
  humanize,
  fasteners,
  packaging,
  patool,
  tqdm,
  annexremote,
  looseversion,
  git-annex,
  # downloaders
  boto3,
  keyrings-alt,
  keyring,
  msgpack,
  requests,
  # publish
  python-gitlab,
  # misc
  argcomplete,
  pyperclip,
  python-dateutil,
  # duecredit
  duecredit,
  # python>=3.8
  distro,
  # win
  colorama,
  # python-version-dependent
  pythonOlder,
  importlib-resources,
  importlib-metadata,
  typing-extensions,
  # tests
  pytestCheckHook,
  p7zip,
  curl,
  coreutils,
  httpretty,
}:

python3.pkgs.buildPythonApplication rec {
buildPythonPackage rec {
  pname = "datalad";
  version = "1.1.1";

@@ -25,6 +64,8 @@ python3.pkgs.buildPythonApplication rec {
  postPatch = ''
    substituteInPlace datalad/distribution/create_sibling.py \
      --replace-fail "/bin/ls" "${coreutils}/bin/ls"
    # Remove vendorized versioneer.py
    rm versioneer.py
  '';

  nativeBuildInputs = [
@@ -32,10 +73,12 @@ python3.pkgs.buildPythonApplication rec {
    git
  ];

  build-system = [ python3.pkgs.setuptools ];
  build-system = [
    setuptools
    versioneer
  ];

  dependencies =
    with python3.pkgs;
    [
      # core
      platformdirs
@@ -68,15 +111,17 @@ python3.pkgs.buildPythonApplication rec {
      argcomplete
      pyperclip
      python-dateutil

      # duecredit
      duecredit

      # python>=3.8
      distro
    ]
    ++ lib.optionals stdenv.hostPlatform.isWindows [ colorama ]
    ++ lib.optionals (python3.pythonOlder "3.9") [ importlib-resources ]
    ++ lib.optionals (python3.pythonOlder "3.10") [ importlib-metadata ]
    ++ lib.optionals (python3.pythonOlder "3.11") [ typing_extensions ];
    ++ lib.optionals (pythonOlder "3.9") [ importlib-resources ]
    ++ lib.optionals (pythonOlder "3.10") [ importlib-metadata ]
    ++ lib.optionals (pythonOlder "3.11") [ typing-extensions ];

  postInstall = ''
    installShellCompletion --cmd datalad \
@@ -180,10 +225,10 @@ python3.pkgs.buildPythonApplication rec {

  nativeCheckInputs = [
    p7zip
    python3.pkgs.pytestCheckHook
    pytestCheckHook
    git-annex
    curl
    python3.pkgs.httpretty
    httpretty
  ];

  pythonImportsCheck = [ "datalad" ];
+46 −0
Original line number Diff line number Diff line
{
  buildPythonPackage,
  fetchFromGitHub,
  hatchling,
  hatch-vcs,
  lib,
  more-itertools,
  psutil,
  pytestCheckHook,
  unzip,
}:

buildPythonPackage rec {
  pname = "datasalad";
  version = "0.2.1";
  pyproject = true;

  src = fetchFromGitHub {
    owner = "datalad";
    repo = "datasalad";
    rev = "refs/tags/v${version}";
    hash = "sha256-qgHWTokNBzJcBbEPCA/YfklzqyX1lM2yro7ElqBfrig=";
  };

  build-system = [
    hatchling
    hatch-vcs
  ];

  nativeCheckInputs = [
    pytestCheckHook
    more-itertools
    psutil
    unzip
  ];

  pythonImportsCheck = [ "datasalad" ];

  meta = {
    description = "Pure-Python library with a collection of utilities for working with Git and git-annex";
    changelog = "https://github.com/datalad/datasalad/blob/main/CHANGELOG.md";
    homepage = "https://github.com/datalad/datasalad";
    license = lib.licenses.mit;
    maintainers = with lib.maintainers; [ gador ];
  };
}
+40 −0
Original line number Diff line number Diff line
{
  buildPythonPackage,
  fetchFromGitHub,
  lib,
  littleutils,
  requests,
  setuptools-scm,
}:

buildPythonPackage rec {
  pname = "outdated";
  version = "0.2.2";
  pyproject = true;

  src = fetchFromGitHub {
    owner = "alexmojaki";
    repo = "outdated";
    rev = "refs/tags/v${version}";
    hash = "sha256-5VpPmgIcVtY97F0Hb0m9MuSW0zjaUJ18ATA4GBRw+jc=";
  };

  build-system = [ setuptools-scm ];

  dependencies = [
    littleutils
    requests
  ];

  # checks rely on internet connection
  doCheck = false;

  pythonImportsCheck = [ "outdated" ];

  meta = {
    description = "Mini-library which, given a package name and a version, checks if it's the latest version available on PyPI";
    homepage = "https://github.com/alexmojaki/outdated";
    license = lib.licenses.mit;
    maintainers = with lib.maintainers; [ gador ];
  };
}
Loading