Commit Graph

9 Commits

Author SHA1 Message Date
Vincent Bernat
18beb310ee chore: replace interface{} with any 2025-07-29 07:42:49 +02:00
Vincent Bernat
a449736a62 build: use Go 1.22 range over ints
Done with:

```
git grep -l 'for.*:= 0.*++' \
  | xargs sed -i -E 's/for (.*) := 0; \1 < (.*); \1\+\+/for \1 := range \2/'
```

And a few manual fixes due to unused variables. There is something fishy
in BMP rib test. Add a comment about that. This is not equivalent (as
with range, random is evaluated once, while in the original loop, it is
evaluated at each iteration). I believe the intent was to behave like
with range.
2024-08-14 10:11:35 +02:00
Vincent Bernat
e842202b82 common/helpers: test validation of SubnetMap with a complex type 2023-09-05 23:06:12 +02:00
Vincent Bernat
3ea9814214 common/schema: fix validation of NotMainTableOnly option
Fix #454
2023-02-14 15:27:51 +01:00
Vincent Bernat
d3b1ae7ad2 common/schema: allow to move some data in or out the main table 2023-01-26 00:33:57 +01:00
Vincent Bernat
bf99e2211e common/helpers: correctly validate netip.Addr/netip.Prefix
validate is only able to validate non-struct types (or recurse inside
struct). So, if we want to use "required" on some of them, we need a
custom type.

Fix #263
2022-11-15 18:38:41 +01:00
Vincent Bernat
e93b57034c orchestrator/clickhouse: fix Networks field validation 2022-08-24 10:10:22 +02:00
Vincent Bernat
d9a8262f76 common/helpers: make validation work for SubnetMap 2022-08-14 15:06:53 +02:00
Vincent Bernat
6121aaea15 config: use a validator for better configuration validation 2022-06-30 01:23:29 +02:00