1{
2 lib,
3 buildPythonPackage,
4 fetchFromGitHub,
5 setuptools,
6 fs,
7 google-cloud-storage,
8 google-crc32c,
9 pytestCheckHook,
10 pytest-cov-stub,
11 requests,
12}:
13
14buildPythonPackage rec {
15 pname = "gcp-storage-emulator";
16 version = "2024.08.03";
17 pyproject = true;
18
19 src = fetchFromGitHub {
20 owner = "oittaa";
21 repo = "gcp-storage-emulator";
22 tag = "v${version}";
23 hash = "sha256-Lp9Wvod0wSE2+cnvLXguhagT30ax9TivyR8gC/kB7w0=";
24 };
25
26 build-system = [
27 setuptools
28 ];
29
30 dependencies = [
31 fs
32 google-crc32c
33 ];
34
35 nativeCheckInputs = [
36 google-cloud-storage
37 pytest-cov-stub
38 pytestCheckHook
39 requests
40 ];
41
42 disabledTests = [
43 "test_invalid_crc32c_hash" # AssertionError
44 ];
45
46 pythonImportsCheck = [
47 "gcp_storage_emulator"
48 ];
49
50 meta = {
51 description = "Local emulator for Google Cloud Storage";
52 homepage = "https://github.com/oittaa/gcp-storage-emulator";
53 license = lib.licenses.bsd3;
54 maintainers = with lib.maintainers; [ ];
55 mainProgram = "gcp-storage-emulator";
56 };
57}