diff options
Diffstat (limited to 'pkgs/development/python-modules/dropbox/default.nix')
-rw-r--r-- | pkgs/development/python-modules/dropbox/default.nix | 63 |
1 files changed, 41 insertions, 22 deletions
diff --git a/pkgs/development/python-modules/dropbox/default.nix b/pkgs/development/python-modules/dropbox/default.nix index 762b9b7ff8cf2..4e3683fc485b4 100644 --- a/pkgs/development/python-modules/dropbox/default.nix +++ b/pkgs/development/python-modules/dropbox/default.nix @@ -1,35 +1,43 @@ -{ lib -, buildPythonPackage -, pythonOlder -, fetchFromGitHub -, requests -, setuptools -, six -, stone -, mock -, pytest-mock -, pytestCheckHook -, sphinxHook +{ + lib, + buildPythonPackage, + pythonOlder, + fetchFromGitHub, + setuptools, + requests, + six, + stone, + mock, + pytest-mock, + pytestCheckHook, + sphinxHook, + sphinx-rtd-theme, + pythonRelaxDepsHook, }: buildPythonPackage rec { pname = "dropbox"; - version = "11.36.2"; - format = "setuptools"; + version = "12.0.2"; + pyproject = true; disabled = pythonOlder "3.7"; - outputs = ["out" "doc"]; + + outputs = [ + "out" + "doc" + ]; src = fetchFromGitHub { owner = "dropbox"; repo = "dropbox-sdk-python"; rev = "refs/tags/v${version}"; - hash = "sha256-d++lxsbwPxnz1JPguWkImHXB+GQpMa9Uo3JNIxIe2ok="; + hash = "sha256-9Fsh06V226vIyJhrlLkh9Xr4UGoEIISnIFCtuKqI218="; }; - propagatedBuildInputs = [ + build-system = [ setuptools ]; + + dependencies = [ requests - setuptools six stone ]; @@ -42,16 +50,25 @@ buildPythonPackage rec { postPatch = '' substituteInPlace setup.py \ - --replace "'pytest-runner == 5.2.0'," "" + --replace "'pytest-runner==5.2.0'," "" ''; doCheck = true; - pythonImportsCheck = [ - "dropbox" + pythonImportsCheck = [ "dropbox" ]; + + nativeBuildInputs = [ + sphinxHook + sphinx-rtd-theme + pythonRelaxDepsHook ]; - nativeBuildInputs = [ sphinxHook ]; + # Version 12.0.0 re-introduced Python 2 support and set some very restrictive version bounds + # https://github.com/dropbox/dropbox-sdk-python/commit/75596daf316b4a806f18057e2797a15bdf83cf6d + # This will be the last major version to support Python 2, so version bounds might be more reasonable again in the future. + pythonRelaxDeps = [ + "stone" + ]; # Set SCOPED_USER_DROPBOX_TOKEN environment variable to a valid value. disabledTests = [ @@ -73,6 +90,8 @@ buildPythonPackage rec { "test_as_user" "test_as_admin" "test_clone_when_team_linked" + "test_bad_pins" + "test_bad_pins_session" ]; meta = with lib; { |