Commit 7c93089
authored
use
* don't raise separately for the data
* don't raise if we quantify with the same unit
* add more tests
* fix a bug in the registry detection algorithm
It failed to detect unit objects in the attributes
* also ignore None values as new units
* don't complain if we try to attach the same units
* same for dataset
* changelog
* use assert_units_equal as well
* properly link the docs [skip-ci].pint.quantify() as a identity operator (#175)1 parent 7a10ea4 commit 7c93089
File tree
5 files changed
+113
-48
lines changed- docs
- pint_xarray
- tests
5 files changed
+113
-48
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
12 | 12 | | |
13 | 13 | | |
14 | 14 | | |
| 15 | + | |
| 16 | + | |
| 17 | + | |
15 | 18 | | |
16 | 19 | | |
17 | 20 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
2 | 2 | | |
3 | 3 | | |
4 | 4 | | |
5 | | - | |
| 5 | + | |
6 | 6 | | |
7 | 7 | | |
8 | 8 | | |
| |||
71 | 71 | | |
72 | 72 | | |
73 | 73 | | |
74 | | - | |
75 | | - | |
76 | | - | |
77 | | - | |
78 | | - | |
79 | | - | |
80 | | - | |
81 | | - | |
82 | | - | |
83 | | - | |
84 | 74 | | |
85 | 75 | | |
86 | 76 | | |
| |||
109 | 99 | | |
110 | 100 | | |
111 | 101 | | |
112 | | - | |
113 | | - | |
| 102 | + | |
| 103 | + | |
114 | 104 | | |
115 | 105 | | |
116 | 106 | | |
| |||
133 | 123 | | |
134 | 124 | | |
135 | 125 | | |
136 | | - | |
| 126 | + | |
137 | 127 | | |
138 | 128 | | |
139 | 129 | | |
| |||
321 | 311 | | |
322 | 312 | | |
323 | 313 | | |
324 | | - | |
325 | | - | |
326 | | - | |
327 | | - | |
328 | | - | |
329 | | - | |
330 | | - | |
331 | 314 | | |
332 | 315 | | |
333 | 316 | | |
| |||
347 | 330 | | |
348 | 331 | | |
349 | 332 | | |
350 | | - | |
| 333 | + | |
351 | 334 | | |
352 | 335 | | |
353 | 336 | | |
354 | | - | |
| 337 | + | |
355 | 338 | | |
356 | 339 | | |
357 | 340 | | |
| |||
373 | 356 | | |
374 | 357 | | |
375 | 358 | | |
376 | | - | |
| 359 | + | |
377 | 360 | | |
378 | 361 | | |
379 | 362 | | |
| |||
1062 | 1045 | | |
1063 | 1046 | | |
1064 | 1047 | | |
1065 | | - | |
| 1048 | + | |
1066 | 1049 | | |
1067 | 1050 | | |
1068 | 1051 | | |
| |||
1088 | 1071 | | |
1089 | 1072 | | |
1090 | 1073 | | |
1091 | | - | |
| 1074 | + | |
1092 | 1075 | | |
1093 | 1076 | | |
1094 | 1077 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
33 | 33 | | |
34 | 34 | | |
35 | 35 | | |
| 36 | + | |
| 37 | + | |
| 38 | + | |
36 | 39 | | |
37 | 40 | | |
38 | 41 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
11 | 11 | | |
12 | 12 | | |
13 | 13 | | |
14 | | - | |
15 | 14 | | |
16 | 15 | | |
17 | 16 | | |
| |||
111 | 110 | | |
112 | 111 | | |
113 | 112 | | |
114 | | - | |
| 113 | + | |
115 | 114 | | |
116 | | - | |
117 | | - | |
| 115 | + | |
| 116 | + | |
| 117 | + | |
| 118 | + | |
| 119 | + | |
| 120 | + | |
| 121 | + | |
| 122 | + | |
| 123 | + | |
| 124 | + | |
| 125 | + | |
| 126 | + | |
| 127 | + | |
| 128 | + | |
| 129 | + | |
| 130 | + | |
| 131 | + | |
| 132 | + | |
| 133 | + | |
| 134 | + | |
| 135 | + | |
| 136 | + | |
| 137 | + | |
| 138 | + | |
| 139 | + | |
| 140 | + | |
| 141 | + | |
| 142 | + | |
| 143 | + | |
| 144 | + | |
| 145 | + | |
| 146 | + | |
| 147 | + | |
| 148 | + | |
| 149 | + | |
| 150 | + | |
| 151 | + | |
| 152 | + | |
| 153 | + | |
| 154 | + | |
| 155 | + | |
| 156 | + | |
| 157 | + | |
| 158 | + | |
| 159 | + | |
| 160 | + | |
| 161 | + | |
| 162 | + | |
| 163 | + | |
| 164 | + | |
| 165 | + | |
| 166 | + | |
| 167 | + | |
| 168 | + | |
118 | 169 | | |
119 | 170 | | |
120 | 171 | | |
| |||
135 | 186 | | |
136 | 187 | | |
137 | 188 | | |
138 | | - | |
139 | | - | |
140 | | - | |
141 | | - | |
142 | | - | |
143 | | - | |
144 | | - | |
145 | | - | |
146 | | - | |
147 | | - | |
148 | | - | |
149 | | - | |
150 | | - | |
151 | | - | |
152 | | - | |
153 | | - | |
154 | 189 | | |
155 | 190 | | |
156 | 191 | | |
| |||
308 | 343 | | |
309 | 344 | | |
310 | 345 | | |
311 | | - | |
312 | | - | |
| 346 | + | |
| 347 | + | |
| 348 | + | |
| 349 | + | |
| 350 | + | |
| 351 | + | |
| 352 | + | |
| 353 | + | |
| 354 | + | |
| 355 | + | |
| 356 | + | |
| 357 | + | |
| 358 | + | |
| 359 | + | |
| 360 | + | |
| 361 | + | |
| 362 | + | |
| 363 | + | |
| 364 | + | |
| 365 | + | |
| 366 | + | |
| 367 | + | |
| 368 | + | |
| 369 | + | |
| 370 | + | |
| 371 | + | |
| 372 | + | |
| 373 | + | |
| 374 | + | |
313 | 375 | | |
314 | 376 | | |
315 | 377 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
78 | 78 | | |
79 | 79 | | |
80 | 80 | | |
| 81 | + | |
| 82 | + | |
| 83 | + | |
| 84 | + | |
| 85 | + | |
| 86 | + | |
| 87 | + | |
| 88 | + | |
| 89 | + | |
| 90 | + | |
| 91 | + | |
| 92 | + | |
| 93 | + | |
| 94 | + | |
81 | 95 | | |
82 | 96 | | |
83 | 97 | | |
| |||
0 commit comments