Commit a8541e1
committed
Check dependencies at runtime as declared in setup.py.
The goal is to list the requirements exactly once in code (in
setupext.py) and once in the docs (in INSTALL.rst).
Instead of manually importing and checking that (python) dependencies
are installed with the correct versions, rely on pkg_resources, which
allows automatically keeping things in sync with setupext, as well as
correctly check e.g. the complex version requirements on pyparsing.
Remove the overly complex way to specify the minimum numpy version.
Add comments reminding to update INSTALL.rst when the requirements are
changed in setupext.py; reorder dependencies in INSTALL.rst in a more
logical order.
Remove unneeded reference to MATLAB being a registered trademark.
Note that if you are running Matplotlib from source by manipulating
PYTHONPATH, then it will not appear to pkg_resources. In this case,
there is no check for other dependencies (you are assumed to be
responsible enough for that). Conversely, Matplotlib will fail to
import if it is installed into site-packages but some dependency (six,
etc.) is only available in PYTHONPATH instead of being correctly
installed. I think this is acceptable (or we could just completely drop
the import checks and let bad installs fail with normal ImportErrors).1 parent c01f862 commit a8541e1
File tree
4 files changed
+58
-69
lines changed- doc
- lib/matplotlib
4 files changed
+58
-69
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
137 | 137 | | |
138 | 138 | | |
139 | 139 | | |
140 | | - | |
| 140 | + | |
141 | 141 | | |
142 | 142 | | |
143 | | - | |
144 | | - | |
| 143 | + | |
| 144 | + | |
| 145 | + | |
145 | 146 | | |
146 | | - | |
147 | | - | |
148 | | - | |
149 | | - | |
150 | | - | |
151 | | - | |
152 | 147 | | |
| 148 | + | |
| 149 | + | |
| 150 | + | |
| 151 | + | |
| 152 | + | |
| 153 | + | |
153 | 154 | | |
154 | 155 | | |
155 | 156 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
323 | 323 | | |
324 | 324 | | |
325 | 325 | | |
326 | | - | |
327 | | - | |
328 | | - | |
329 | | - | |
330 | 326 | | |
331 | 327 | | |
332 | 328 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
94 | 94 | | |
95 | 95 | | |
96 | 96 | | |
97 | | - | |
98 | | - | |
99 | | - | |
100 | | - | |
101 | 97 | | |
102 | 98 | | |
103 | 99 | | |
104 | 100 | | |
105 | 101 | | |
| 102 | + | |
| 103 | + | |
| 104 | + | |
| 105 | + | |
| 106 | + | |
| 107 | + | |
| 108 | + | |
| 109 | + | |
| 110 | + | |
| 111 | + | |
| 112 | + | |
| 113 | + | |
| 114 | + | |
| 115 | + | |
106 | 116 | | |
107 | 117 | | |
108 | 118 | | |
| |||
120 | 130 | | |
121 | 131 | | |
122 | 132 | | |
123 | | - | |
124 | | - | |
| 133 | + | |
125 | 134 | | |
126 | 135 | | |
127 | 136 | | |
| |||
137 | 146 | | |
138 | 147 | | |
139 | 148 | | |
| 149 | + | |
| 150 | + | |
| 151 | + | |
| 152 | + | |
| 153 | + | |
| 154 | + | |
| 155 | + | |
| 156 | + | |
| 157 | + | |
| 158 | + | |
| 159 | + | |
| 160 | + | |
| 161 | + | |
| 162 | + | |
| 163 | + | |
| 164 | + | |
| 165 | + | |
| 166 | + | |
| 167 | + | |
| 168 | + | |
| 169 | + | |
| 170 | + | |
| 171 | + | |
| 172 | + | |
| 173 | + | |
| 174 | + | |
| 175 | + | |
140 | 176 | | |
141 | 177 | | |
142 | 178 | | |
143 | | - | |
| 179 | + | |
144 | 180 | | |
145 | | - | |
146 | | - | |
147 | | - | |
148 | | - | |
149 | | - | |
| 181 | + | |
150 | 182 | | |
151 | 183 | | |
152 | 184 | | |
| |||
191 | 223 | | |
192 | 224 | | |
193 | 225 | | |
194 | | - | |
195 | | - | |
196 | | - | |
| 226 | + | |
197 | 227 | | |
198 | 228 | | |
199 | 229 | | |
200 | 230 | | |
201 | | - | |
202 | | - | |
203 | | - | |
204 | | - | |
205 | | - | |
206 | | - | |
207 | | - | |
208 | | - | |
209 | | - | |
210 | | - | |
211 | | - | |
212 | | - | |
213 | | - | |
214 | | - | |
215 | | - | |
216 | | - | |
217 | | - | |
218 | | - | |
219 | | - | |
220 | | - | |
221 | | - | |
222 | | - | |
223 | | - | |
224 | | - | |
225 | | - | |
226 | | - | |
227 | | - | |
228 | | - | |
229 | 231 | | |
230 | 232 | | |
231 | 233 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
107 | 107 | | |
108 | 108 | | |
109 | 109 | | |
110 | | - | |
111 | | - | |
112 | | - | |
113 | | - | |
114 | | - | |
115 | | - | |
116 | | - | |
117 | | - | |
118 | | - | |
119 | | - | |
120 | | - | |
121 | | - | |
122 | 110 | | |
123 | 111 | | |
124 | 112 | | |
| |||
925 | 913 | | |
926 | 914 | | |
927 | 915 | | |
928 | | - | |
| 916 | + | |
| 917 | + | |
929 | 918 | | |
930 | 919 | | |
931 | 920 | | |
| |||
1391 | 1380 | | |
1392 | 1381 | | |
1393 | 1382 | | |
| 1383 | + | |
1394 | 1384 | | |
1395 | 1385 | | |
1396 | 1386 | | |
| |||
0 commit comments