Commit 1b932e0
authored
Additional validations + use inferenceBlockheight in NetworkInferences (#804)
<!-- < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < ☺
v ✰ Thanks for creating a PR! You're awesome! ✰
v Please note that maintainers will only review those PRs with a
completed PR template.
☺ > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > -->
## Purpose of Changes and their Description
* Additional validations on `validations.go`
* nonempty `infererValues` is required
* input data `blockheight` is required to be non-nil and non-zero
* inference and forecasts `blockheight` need to be aligned with bundle
`blockheight`
* fix usage of current block `ctx.Blockheight()` in
`inferenceBlockheight` in `NetworkInferences` responses.
## Are these changes tested and documented?
- [x] If tested, please describe how. If not, why tests are not needed.
-- unit tests fixed + cases added.
- [x] If documented, please describe where. If not, describe why docs
are not needed. -- no need to document, not relevant functional changes.
- [x] Added to `Unreleased` section of `CHANGELOG.md`?1 parent 56b42c0 commit 1b932e0
14 files changed
Lines changed: 388 additions & 131 deletions
File tree
- x/emissions
- keeper
- inference_synthesis
- msgserver
- queryserver
- module/rewards
- types
Lines changed: 2 additions & 1 deletion
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
856 | 856 | | |
857 | 857 | | |
858 | 858 | | |
| 859 | + | |
859 | 860 | | |
860 | 861 | | |
861 | 862 | | |
| |||
1048 | 1049 | | |
1049 | 1050 | | |
1050 | 1051 | | |
1051 | | - | |
| 1052 | + | |
1052 | 1053 | | |
1053 | 1054 | | |
1054 | 1055 | | |
| |||
Lines changed: 23 additions & 1 deletion
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
188 | 188 | | |
189 | 189 | | |
190 | 190 | | |
| 191 | + | |
| 192 | + | |
| 193 | + | |
| 194 | + | |
| 195 | + | |
| 196 | + | |
| 197 | + | |
| 198 | + | |
| 199 | + | |
| 200 | + | |
| 201 | + | |
| 202 | + | |
| 203 | + | |
| 204 | + | |
191 | 205 | | |
192 | 206 | | |
| 207 | + | |
193 | 208 | | |
194 | 209 | | |
195 | 210 | | |
| |||
199 | 214 | | |
200 | 215 | | |
201 | 216 | | |
202 | | - | |
| 217 | + | |
203 | 218 | | |
204 | 219 | | |
205 | 220 | | |
| |||
548 | 563 | | |
549 | 564 | | |
550 | 565 | | |
| 566 | + | |
551 | 567 | | |
552 | 568 | | |
553 | 569 | | |
| |||
599 | 615 | | |
600 | 616 | | |
601 | 617 | | |
| 618 | + | |
602 | 619 | | |
603 | 620 | | |
604 | 621 | | |
| |||
949 | 966 | | |
950 | 967 | | |
951 | 968 | | |
| 969 | + | |
952 | 970 | | |
953 | 971 | | |
954 | 972 | | |
| |||
1062 | 1080 | | |
1063 | 1081 | | |
1064 | 1082 | | |
| 1083 | + | |
1065 | 1084 | | |
1066 | 1085 | | |
1067 | 1086 | | |
| |||
1205 | 1224 | | |
1206 | 1225 | | |
1207 | 1226 | | |
| 1227 | + | |
1208 | 1228 | | |
1209 | 1229 | | |
1210 | 1230 | | |
| |||
1352 | 1372 | | |
1353 | 1373 | | |
1354 | 1374 | | |
| 1375 | + | |
1355 | 1376 | | |
1356 | 1377 | | |
1357 | 1378 | | |
| |||
1460 | 1481 | | |
1461 | 1482 | | |
1462 | 1483 | | |
| 1484 | + | |
1463 | 1485 | | |
1464 | 1486 | | |
1465 | 1487 | | |
| |||
Lines changed: 5 additions & 3 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
51 | 51 | | |
52 | 52 | | |
53 | 53 | | |
54 | | - | |
| 54 | + | |
55 | 55 | | |
56 | 56 | | |
57 | 57 | | |
| |||
67 | 67 | | |
68 | 68 | | |
69 | 69 | | |
70 | | - | |
71 | 70 | | |
72 | 71 | | |
73 | 72 | | |
| |||
83 | 82 | | |
84 | 83 | | |
85 | 84 | | |
86 | | - | |
| 85 | + | |
87 | 86 | | |
88 | 87 | | |
89 | 88 | | |
| |||
144 | 143 | | |
145 | 144 | | |
146 | 145 | | |
| 146 | + | |
147 | 147 | | |
148 | 148 | | |
149 | 149 | | |
| |||
215 | 215 | | |
216 | 216 | | |
217 | 217 | | |
| 218 | + | |
218 | 219 | | |
219 | 220 | | |
220 | 221 | | |
| |||
296 | 297 | | |
297 | 298 | | |
298 | 299 | | |
| 300 | + | |
299 | 301 | | |
300 | 302 | | |
301 | 303 | | |
| |||
Lines changed: 23 additions & 21 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
136 | 136 | | |
137 | 137 | | |
138 | 138 | | |
| 139 | + | |
| 140 | + | |
| 141 | + | |
| 142 | + | |
139 | 143 | | |
140 | | - | |
| 144 | + | |
141 | 145 | | |
142 | 146 | | |
143 | 147 | | |
144 | | - | |
145 | | - | |
146 | | - | |
147 | 148 | | |
148 | 149 | | |
149 | 150 | | |
| |||
376 | 377 | | |
377 | 378 | | |
378 | 379 | | |
| 380 | + | |
| 381 | + | |
| 382 | + | |
379 | 383 | | |
380 | | - | |
| 384 | + | |
381 | 385 | | |
382 | 386 | | |
383 | 387 | | |
384 | 388 | | |
385 | | - | |
386 | | - | |
387 | | - | |
388 | 389 | | |
389 | 390 | | |
390 | 391 | | |
| |||
455 | 456 | | |
456 | 457 | | |
457 | 458 | | |
458 | | - | |
459 | | - | |
460 | | - | |
| 459 | + | |
461 | 460 | | |
| 461 | + | |
462 | 462 | | |
463 | | - | |
| 463 | + | |
| 464 | + | |
| 465 | + | |
464 | 466 | | |
465 | 467 | | |
466 | 468 | | |
| |||
601 | 603 | | |
602 | 604 | | |
603 | 605 | | |
| 606 | + | |
| 607 | + | |
| 608 | + | |
| 609 | + | |
604 | 610 | | |
605 | | - | |
| 611 | + | |
606 | 612 | | |
607 | 613 | | |
608 | 614 | | |
609 | 615 | | |
610 | 616 | | |
611 | 617 | | |
612 | | - | |
613 | | - | |
614 | | - | |
615 | 618 | | |
616 | 619 | | |
617 | 620 | | |
| |||
693 | 696 | | |
694 | 697 | | |
695 | 698 | | |
696 | | - | |
697 | 699 | | |
698 | 700 | | |
699 | 701 | | |
| |||
745 | 747 | | |
746 | 748 | | |
747 | 749 | | |
| 750 | + | |
| 751 | + | |
| 752 | + | |
748 | 753 | | |
749 | | - | |
| 754 | + | |
750 | 755 | | |
751 | 756 | | |
752 | 757 | | |
753 | | - | |
754 | | - | |
755 | | - | |
756 | 758 | | |
757 | 759 | | |
758 | 760 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
541 | 541 | | |
542 | 542 | | |
543 | 543 | | |
544 | | - | |
| 544 | + | |
545 | 545 | | |
546 | 546 | | |
547 | 547 | | |
| |||
551 | 551 | | |
552 | 552 | | |
553 | 553 | | |
554 | | - | |
| 554 | + | |
555 | 555 | | |
556 | 556 | | |
557 | 557 | | |
| |||
0 commit comments