1{ lib, buildPythonPackage, fetchFromGitHub, py, lxml, pytestCheckHook, wireshark-cli }: 2 3buildPythonPackage rec { 4 pname = "pyshark"; 5 version = "0.4.3"; 6 7 src = fetchFromGitHub { 8 owner = "KimiNewt"; 9 repo = pname; 10 rev = "v${version}"; 11 sha256 = "sha256-cveiFkkSplfQPgUEVWyV40KKHCtKJZsfvdV8JmEUmE4="; 12 }; 13 14 propagatedBuildInputs = [ 15 py 16 lxml 17 ]; 18 19 preConfigure = '' 20 cd src 21 ''; 22 23 preCheck = '' 24 cd .. 25 ''; 26 27 checkInputs = [ 28 pytestCheckHook 29 wireshark-cli 30 ]; 31 32 pythonImportsCheck = [ "pyshark" ]; 33 34 meta = with lib; { 35 description = "Python wrapper for tshark, allowing python packet parsing using wireshark dissectors"; 36 homepage = "https://github.com/KimiNewt/pyshark/"; 37 license = licenses.mit; 38 maintainers = with maintainers; [ petabyteboy ]; 39 }; 40}