For sqlboiler to work, they have R and L fields. Those fields are other structs (or pointer to them). And the relation can circle.
This results for some structs in infinity loops.
Respecting the csv ignore "-" would resolve this.
This PR aims to do that.
After running our code we get no more infinity loops.
example output struct
type Pilot struct {
ID int `boil:"id" json:"id" toml:"id" yaml:"id"`
Name string `boil:"name" json:"name" toml:"name" yaml:"name"`
R *pilotR `boil:"-" json:"-" toml:"-" yaml:"-"`
L pilotR `boil:"-" json:"-" toml:"-" yaml:"-"`
}
We auto-create structs using https://github.com/volatiletech/sqlboiler.
And load in data using e.g. csv via gocsv.
For sqlboiler to work, they have
R
andL
fields. Those fields are other structs (or pointer to them). And the relation can circle.This results for some structs in infinity loops.
Respecting the csv ignore
"-"
would resolve this.This PR aims to do that.
After running our code we get no more infinity loops.
example output struct
Probably fixes #168