2023-04-26 10:55:59 +02:00
|
|
|
{
|
|
|
|
lib,
|
|
|
|
buildPythonPackage,
|
2024-01-23 16:39:09 +01:00
|
|
|
fetchFromGitHub,
|
2023-09-10 00:03:24 +02:00
|
|
|
flit-core,
|
2024-01-23 16:39:09 +01:00
|
|
|
pytestCheckHook,
|
|
|
|
pythonOlder,
|
2023-04-26 10:55:59 +02:00
|
|
|
}:
|
|
|
|
|
|
|
|
buildPythonPackage rec {
|
|
|
|
pname = "asyncinotify";
|
2024-12-09 23:43:50 +01:00
|
|
|
version = "4.2.0";
|
2024-01-23 16:39:09 +01:00
|
|
|
pyproject = true;
|
2023-04-26 10:55:59 +02:00
|
|
|
|
2024-01-23 16:39:09 +01:00
|
|
|
disabled = pythonOlder "3.7";
|
|
|
|
|
|
|
|
src = fetchFromGitHub {
|
|
|
|
owner = "absperf";
|
2023-04-26 10:55:59 +02:00
|
|
|
repo = "asyncinotify";
|
2025-01-03 21:24:13 +01:00
|
|
|
tag = "v${version}";
|
2024-12-09 23:43:50 +01:00
|
|
|
hash = "sha256-RHzjUoVhDxI7kYD5HWkb0f8X6BjjTTCAvSvASPy6FGk=";
|
2023-04-26 10:55:59 +02:00
|
|
|
};
|
|
|
|
|
2024-08-08 03:09:53 -07:00
|
|
|
build-system = [ flit-core ];
|
2023-09-10 00:03:24 +02:00
|
|
|
|
2024-01-23 16:39:09 +01:00
|
|
|
nativeCheckInputs = [ pytestCheckHook ];
|
|
|
|
|
|
|
|
pythonImportsCheck = [ "asyncinotify" ];
|
|
|
|
|
|
|
|
pytestFlagsArray = [ "test.py" ];
|
2023-04-26 10:55:59 +02:00
|
|
|
|
|
|
|
meta = with lib; {
|
python313Packages.asyncinotify: mark unsupported on darwin
```
Check whether the following modules can be imported: asyncinotify
Traceback (most recent call last):
File "<string>", line 1, in <module>
File "<string>", line 1, in <lambda>
File "/nix/store/vfdk6q81hdjqjfiqz8f92hibdck3kmn6-python3-3.12.10/lib/python3.12/importlib/__init__.py", line 90, in import_module
return _bootstrap._gcd_import(name[level:], package, level)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "<frozen importlib._bootstrap>", line 1387, in _gcd_import
File "<frozen importlib._bootstrap>", line 1360, in _find_and_load
File "<frozen importlib._bootstrap>", line 1331, in _find_and_load_unlocked
File "<frozen importlib._bootstrap>", line 935, in _load_unlocked
File "<frozen importlib._bootstrap_external>", line 999, in exec_module
File "<frozen importlib._bootstrap>", line 488, in _call_with_frames_removed
File "/nix/store/bk44appr4dabadspjahk3l0ad29vhq8s-python3.12-asyncinotify-4.2.0/lib/python3.12/site-packages/asyncinotify/__init__.py", line 23, in <module>
from . import _ffi
File "/nix/store/bk44appr4dabadspjahk3l0ad29vhq8s-python3.12-asyncinotify-4.2.0/lib/python3.12/site-packages/asyncinotify/_ffi.py", line 36, in <module>
libc.inotify_init.restype = check_return
^^^^^^^^^^^^^^^^^
File "/nix/store/vfdk6q81hdjqjfiqz8f92hibdck3kmn6-python3-3.12.10/lib/python3.12/ctypes/__init__.py", line 392, in __getattr__
func = self.__getitem__(name)
^^^^^^^^^^^^^^^^^^^^^^
File "/nix/store/vfdk6q81hdjqjfiqz8f92hibdck3kmn6-python3-3.12.10/lib/python3.12/ctypes/__init__.py", line 397, in __getitem__
func = self._FuncPtr((name_or_ordinal, self))
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
AttributeError: dlsym(0x3312f2768, inotify_init): symbol not found
```
2025-05-17 13:26:04 +02:00
|
|
|
badPlatforms = [
|
|
|
|
# Unsupported and crashing on import in dlsym with symbol not found
|
|
|
|
"aarch64-darwin"
|
|
|
|
"x86_64-darwin"
|
|
|
|
];
|
2024-01-23 16:39:09 +01:00
|
|
|
description = "Module for inotify";
|
|
|
|
homepage = "https://github.com/absperf/asyncinotify/";
|
|
|
|
changelog = "https://github.com/absperf/asyncinotify/releases/tag/v${version}";
|
2024-08-08 03:13:56 -07:00
|
|
|
license = licenses.mpl20;
|
2023-04-26 10:55:59 +02:00
|
|
|
maintainers = with maintainers; [ cynerd ];
|
|
|
|
};
|
|
|
|
}
|