2018-02-21 17:49:10 +00:00
|
|
|
{ lib, buildPythonPackage, fetchFromGitHub
|
2020-01-14 20:14:49 +00:00
|
|
|
, python3, protobuf3_6
|
2018-02-21 17:49:10 +00:00
|
|
|
}:
|
|
|
|
|
2020-01-14 20:14:49 +00:00
|
|
|
let
|
|
|
|
python = python3.override {
|
|
|
|
packageOverrides = self: super: {
|
|
|
|
protobuf = super.protobuf.override {
|
|
|
|
protobuf = protobuf3_6;
|
|
|
|
};
|
|
|
|
};
|
|
|
|
};
|
|
|
|
in buildPythonPackage rec {
|
2018-02-21 17:49:10 +00:00
|
|
|
pname = "mysql-connector";
|
2020-01-14 20:14:49 +00:00
|
|
|
version = "8.0.19";
|
2018-02-21 17:49:10 +00:00
|
|
|
|
|
|
|
src = fetchFromGitHub {
|
|
|
|
owner = "mysql";
|
|
|
|
repo = "mysql-connector-python";
|
|
|
|
rev = version;
|
2020-01-14 20:14:49 +00:00
|
|
|
sha256 = "1jscmc5s7mwx43gvxjlqc30ylp5jjpmkqx7s3b9nllbh926p3ixg";
|
2018-02-21 17:49:10 +00:00
|
|
|
};
|
|
|
|
|
2020-01-14 20:14:49 +00:00
|
|
|
propagatedBuildInputs = with python.pkgs; [ protobuf dnspython ];
|
2018-02-21 17:49:10 +00:00
|
|
|
|
2018-04-19 21:42:45 +01:00
|
|
|
# Tests are failing (TODO: unknown reason)
|
|
|
|
# TypeError: __init__() missing 1 required positional argument: 'string'
|
|
|
|
# But the library should be working as expected.
|
2018-02-21 17:49:10 +00:00
|
|
|
doCheck = false;
|
|
|
|
|
|
|
|
meta = {
|
|
|
|
description = "A MySQL driver";
|
|
|
|
longDescription = ''
|
|
|
|
A MySQL driver that does not depend on MySQL C client libraries and
|
|
|
|
implements the DB API v2.0 specification.
|
|
|
|
'';
|
|
|
|
homepage = https://github.com/mysql/mysql-connector-python;
|
|
|
|
license = [ lib.licenses.gpl2 ];
|
|
|
|
maintainers = with lib.maintainers; [ primeos ];
|
|
|
|
};
|
|
|
|
}
|