mirror of
https://github.com/NixOS/nixpkgs.git
synced 2025-02-27 22:44:56 +00:00
Merge pull request #330786 from pyrox0/denose/locationsharinglib
python312Packages.locationsharinglib: drop nose dependency; modernize
This commit is contained in:
commit
97c2642c24
@ -1,65 +1,53 @@
|
||||
{
|
||||
lib,
|
||||
betamax,
|
||||
buildPythonPackage,
|
||||
cachetools,
|
||||
coloredlogs,
|
||||
emoji,
|
||||
fetchPypi,
|
||||
nose,
|
||||
pythonOlder,
|
||||
pytz,
|
||||
requests,
|
||||
setuptools,
|
||||
}:
|
||||
|
||||
buildPythonPackage rec {
|
||||
pname = "locationsharinglib";
|
||||
version = "5.0.3";
|
||||
format = "setuptools";
|
||||
pyproject = true;
|
||||
|
||||
disabled = pythonOlder "3.7";
|
||||
disabled = pythonOlder "3.9";
|
||||
|
||||
src = fetchPypi {
|
||||
inherit pname version;
|
||||
hash = "sha256-ar5/gyDnby0aceqqHe8lTQaHafOub+IPKglmct4xEGM=";
|
||||
};
|
||||
|
||||
propagatedBuildInputs = [
|
||||
postPatch = ''
|
||||
# Tests requirements want to pull in multiple modules which we don't need
|
||||
substituteInPlace setup.py \
|
||||
--replace-fail "tests_require=test_requirements" "tests_require=[]"
|
||||
cp .VERSION locationsharinglib/.VERSION
|
||||
'';
|
||||
|
||||
build-system = [ setuptools ];
|
||||
|
||||
dependencies = [
|
||||
coloredlogs
|
||||
requests
|
||||
cachetools
|
||||
pytz
|
||||
];
|
||||
|
||||
nativeCheckInputs = [
|
||||
betamax
|
||||
emoji
|
||||
nose
|
||||
];
|
||||
|
||||
postPatch = ''
|
||||
# Tests requirements want to pull in multiple modules which we don't need
|
||||
substituteInPlace setup.py \
|
||||
--replace "tests_require=test_requirements" "tests_require=[]"
|
||||
substituteInPlace requirements.txt \
|
||||
--replace "coloredlogs>=15.0.1" "coloredlogs" \
|
||||
--replace "pytz>=2023.3" "pytz"
|
||||
'';
|
||||
|
||||
checkPhase = ''
|
||||
runHook preCheck
|
||||
# Only coverage no real unit tests
|
||||
nosetests
|
||||
runHook postCheck
|
||||
'';
|
||||
# There are no tests
|
||||
doCheck = false;
|
||||
|
||||
pythonImportsCheck = [ "locationsharinglib" ];
|
||||
|
||||
meta = with lib; {
|
||||
meta = {
|
||||
description = "Python package to retrieve coordinates from a Google account";
|
||||
homepage = "https://locationsharinglib.readthedocs.io/";
|
||||
changelog = "https://github.com/costastf/locationsharinglib/blob/${version}/HISTORY.rst";
|
||||
license = licenses.mit;
|
||||
maintainers = with maintainers; [ fab ];
|
||||
license = lib.licenses.mit;
|
||||
maintainers = with lib.maintainers; [ fab ];
|
||||
};
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user