Project

General

Profile

Bug #15871

Migration fails when standard roles are deleted

Added by Lukas Zapletal about 3 years ago. Updated about 3 years ago.

Status:
Closed
Priority:
Normal
Category:
Discovery plugin
Target version:
Difficulty:
Triaged:
No
Bugzilla link:
Team Backlog:
Fixed in Releases:
Found in Releases:

Description

When they are missing, getting:

undefined method `add_permissions!' for nil:NilClass
/home/lzap/work/foreman_discovery/db/migrate/20160719124942_add_missing_view_permissions.rb:9:in `up'
/home/lzap/.rbenv/versions/2.3.1/bin/bundle:23:in `load'
/home/lzap/.rbenv/versions/2.3.1/bin/bundle:23:in `<main>'
NoMethodError: undefined method `add_permissions!' for nil:NilClass
/home/lzap/work/foreman_discovery/db/migrate/20160719124942_add_missing_view_permissions.rb:9:in `up'
/home/lzap/.rbenv/versions/2.3.1/bin/bundle:23:in `load'
/home/lzap/.rbenv/versions/2.3.1/bin/bundle:23:in `<main>'
Tasks: TOP => db:migrate

Associated revisions

Revision 3af1f18d (diff)
Added by Lukas Zapletal about 3 years ago

Fixes #15871 - role permissions migration fixed

History

#1 Updated by The Foreman Bot about 3 years ago

  • Status changed from New to Ready For Testing
  • Assignee set to Lukas Zapletal
  • Pull request https://github.com/theforeman/foreman_discovery/pull/290 added

#2 Updated by Anonymous about 3 years ago

  • Status changed from Ready For Testing to Closed
  • % Done changed from 0 to 100

Also available in: Atom PDF