Getting "ActiveRecord::RecordInvalid: Validation failed: Namespace route can't be blank" on fresh install
This could totally be something wonky with my personal environment but I had issues with the seed data for the admin user. For some reason, a Route
object for the root User
's Namespace
was not created. I kept getting the error ActiveRecord::RecordInvalid: Validation failed: Namespace route can't be blank
. I tried nuking and recreating my DB a few times to no avail.
In the end, the way I fixed it was by booting the app and running rails console
. then:
u = User.first
ns = u.namespace
r = Route.new(path: "root", source: ns)
r.save
I'm not sure if this was something on my end, or something that needs to be tweaked in the db/fixtures/development
directory but wanted to write something here in case others ran into it also.