Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
18 changes: 10 additions & 8 deletions pkgs/development/python-modules/limits/default.nix
Original file line number Diff line number Diff line change
Expand Up @@ -27,22 +27,20 @@

buildPythonPackage rec {
pname = "limits";
version = "5.2.0";
version = "5.4.0";
pyproject = true;

disabled = pythonOlder "3.8";

src = fetchFromGitHub {
owner = "alisaifee";
repo = "limits";
tag = version;
# Upstream uses versioneer, which relies on git attributes substitution.
# This leads to non-reproducible archives on github. Remove the substituted
# file here, and recreate it later based on our version info.
hash = "sha256-EHLqkd5Muazr52/oYaLklFVvF+AzJWGbFaaIG+T0ulE=";
postFetch = ''
rm "$out/limits/_version.py"
'';
hash = "sha256-0D44XaSZtebMnn9mqXbaE7FB7usdu/eZ/4UE3Ye0oyA=";
};

patches = [
Expand Down Expand Up @@ -102,15 +100,19 @@ buildPythonPackage rec {

pytestFlagsArray = [ "--benchmark-disable" ];

disabledTests = [ "test_moving_window_memcached" ];
disabledTests = [
"test_moving_window_memcached"
# Flaky: compares time to magic value
"test_sliding_window_counter_previous_window"
];

pythonImportsCheck = [ "limits" ];

meta = with lib; {
meta = {
description = "Rate limiting using various strategies and storage backends such as redis & memcached";
homepage = "https://github.com/alisaifee/limits";
changelog = "https://github.com/alisaifee/limits/releases/tag/${src.tag}";
license = licenses.mit;
maintainers = [ ];
license = lib.licenses.mit;
maintainers = with lib.maintainers; [ sarahec ];
};
}
34 changes: 23 additions & 11 deletions pkgs/development/python-modules/valkey/default.nix
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
{
lib,
stdenv,
fetchFromGitHub,
buildPythonPackage,
pythonOlder,
Expand Down Expand Up @@ -32,8 +33,6 @@ buildPythonPackage rec {
version = "6.1.0";
pyproject = true;

disabled = pythonOlder "3.7";

src = fetchFromGitHub {
owner = "valkey-io";
repo = "valkey-py";
Expand Down Expand Up @@ -78,19 +77,32 @@ buildPythonPackage rec {

pytestFlagsArray = [ "-m 'not onlycluster and not ssl'" ];

disabledTests = [
# valkey.sentinel.MasterNotFoundError: No master found for 'valkey-py-test'
"test_get_from_cache"
"test_cache_decode_response"
# Expects another valkey instance on port 6380 *shrug*
"test_psync"
disabledTests =
[
# valkey.sentinel.MasterNotFoundError: No master found for 'valkey-py-test'
"test_get_from_cache"
"test_cache_decode_response"
# Expects another valkey instance on port 6380 *shrug*
"test_psync"
]
++ lib.optionals stdenv.hostPlatform.isDarwin [
# OSError: AF_UNIX path too long
"test_uds_connect"
"test_network_connection_failure"
];

disabledTestPaths = lib.optionals stdenv.hostPlatform.isDarwin [
# AttributeError: Can't get local object 'TestMultiprocessing.test_valkey_client.<locals>.target'
"tests/test_multiprocessing.py"
];

meta = with lib; {
__darwinAllowLocalNetworking = true;

meta = {
description = "Python client for Redis key-value store";
homepage = "https://github.com/valkey-io/valkey-py";
changelog = "https://github.com/valkey-io/valkey-py/releases/tag/${src.tag}";
license = with licenses; [ mit ];
maintainers = with maintainers; [ hexa ];
license = lib.licenses.mit;
maintainers = with lib.maintainers; [ hexa ];
};
}