4a7f99d55d
Part of: https://github.com/NixOS/nixpkgs/issues/108938 meta = with stdenv.lib; is a widely used pattern. We want to slowly remove the `stdenv.lib` indirection and encourage people to use `lib` directly. Thus let’s start with the meta field. This used a rewriting script to mostly automatically replace all occurances of this pattern, and add the `lib` argument to the package header if it doesn’t exist yet. The script in its current form is available at https://cs.tvl.fyi/depot@2f807d7f141068d2d60676a89213eaa5353ca6e0/-/blob/users/Profpatsch/nixpkgs-rewriter/default.nix
40 lines
1.0 KiB
Nix
40 lines
1.0 KiB
Nix
{ lib, stdenv, fetchPypi, buildPythonPackage, base58, ecdsa, pycryptodome, requests, six, setuptools }:
|
|
|
|
buildPythonPackage rec {
|
|
pname = "block-io";
|
|
version = "1.1.15";
|
|
|
|
src = fetchPypi {
|
|
inherit pname version;
|
|
sha256 = "97ea037a67af72037cb08cec7e0a9f7866ecdfaa1a8c8ebcc0f4b9359a1516d7";
|
|
};
|
|
|
|
propagatedBuildInputs = [
|
|
base58
|
|
ecdsa
|
|
pycryptodome
|
|
requests
|
|
six
|
|
setuptools
|
|
];
|
|
|
|
preConfigure = ''
|
|
substituteInPlace setup.py \
|
|
--replace "ecdsa==0.15" "ecdsa>=0.15" \
|
|
--replace "base58==1.0.3" "base58>=1.0.3"
|
|
'';
|
|
|
|
# Tests needs a BlockIO API key to run properly
|
|
# https://github.com/BlockIo/block_io-python/blob/79006bc8974544b70a2d8e9f19c759941d32648e/test.py#L18
|
|
doCheck = false;
|
|
|
|
pythonImportsCheck = [ "block_io" ];
|
|
|
|
meta = with lib; {
|
|
description = "Integrate Bitcoin, Dogecoin and Litecoin in your Python applications using block.io";
|
|
homepage = "https://github.com/BlockIo/block_io-python";
|
|
license = licenses.mit;
|
|
maintainers = with maintainers; [ nyanloutre ];
|
|
};
|
|
}
|