1{ lib
2, stdenv
3, buildPythonPackage
4, fetchFromGitHub
5, jinja2
6, matplotlib
7, openpyxl
8, pandas
9, poetry-core
10, scipy
11, sqlalchemy
12, tabulate
13, pyarrow
14, pyreadstat
15, tables
16, pytestCheckHook
17, pythonOlder
18, types-pytz
19, typing-extensions
20, xarray
21}:
22
23buildPythonPackage rec {
24 pname = "pandas-stubs";
25 version = "1.5.0.221003";
26 format = "pyproject";
27
28 disabled = pythonOlder "3.8";
29
30 src = fetchFromGitHub {
31 owner = "pandas-dev";
32 repo = pname;
33 rev = "v${version}";
34 sha256 = "sha256-RV0pOTPtlwBmYs3nu8+lNwVpl/VC/VzcXKOQMg9C3qk=";
35 };
36
37 nativeBuildInputs = [
38 poetry-core
39 ];
40
41 propagatedBuildInputs = [
42 pandas
43 types-pytz
44 ];
45
46 checkInputs = [
47 jinja2
48 matplotlib
49 openpyxl
50 scipy
51 sqlalchemy
52 tabulate
53 pyarrow
54 tables
55 pyreadstat
56 pytestCheckHook
57 typing-extensions
58 xarray
59 ];
60
61 disabledTests = [
62 # AttributeErrors, missing dependencies, error and warning checks
63 "test_data_error"
64 "test_specification_error"
65 "test_setting_with_copy_error"
66 "test_setting_with_copy_warning"
67 "test_numexpr_clobbering_error"
68 "test_undefined_variable_error"
69 "test_indexing_error"
70 "test_pyperclip_exception"
71 "test_css_warning"
72 "test_possible_data_loss_error"
73 "test_closed_file_error"
74 "test_incompatibility_warning"
75 "test_attribute_conflict_warning"
76 "test_database_error"
77 "test_possible_precision_loss"
78 "test_value_label_type_mismatch"
79 "test_invalid_column_name"
80 "test_categorical_conversion_warning"
81 "test_join"
82 "test_isetframe"
83 "test_reset_index_150_changes"
84 "test_compare_150_changes"
85 "test_quantile_150_changes"
86 "test_resample_150_changes"
87 "test_index_astype"
88 "test_orc"
89 "test_orc_path"
90 "test_orc_buffer"
91 "test_orc_columns"
92 "test_orc_bytes"
93 "test_clipboard"
94 "test_clipboard_iterator"
95 "test_arrow_dtype"
96 "test_aggregate_series_combinations"
97 "test_aggregate_frame_combinations"
98 "test_types_rank"
99 "test_reset_index"
100 "test_types_assert_series_equal"
101 "test_show_version"
102 "test_dummies"
103 "test_from_dummies_args"
104 "test_rolling_step_method"
105 ] ++ lib.optionals stdenv.isDarwin [
106 "test_plotting" # Fatal Python error: Illegal instruction
107 ];
108
109 pythonImportsCheck = [
110 "pandas"
111 ];
112
113 meta = with lib; {
114 description = "Type annotations for Pandas";
115 homepage = "https://github.com/VirtusLab/pandas-stubs";
116 license = licenses.mit;
117 maintainers = with maintainers; [ malo ];
118 };
119}