Bug #7818

500 error in API v1 user/role functional tests: "Too deeply nested"

Added by Dominic Cleal about 3 years ago. Updated about 3 years ago.

Status:Closed
Priority:Immediate
Assigned To:Dominic Cleal
Category:Tests
Target version:Sprint 30
Difficulty: Bugzilla link:
Found in release: Pull request:https://github.com/theforeman/foreman/pull/1821
Story points-
Velocity based estimate-
Release1.6.1Release relationshipAuto

Description

Logs show this error:

Too deeply nested.
(ActionView::Template::Error)
/usr/local/rvm/gems/ruby-2.0.0-p353@test_develop_pr_core-1/gems/rabl-0.9.0/lib/rabl/engine.rb:240:in `dump'
/usr/local/rvm/gems/ruby-2.0.0-p353@test_develop_pr_core-1/gems/rabl-0.9.0/lib/rabl/engine.rb:240:in `format_json'
/usr/local/rvm/gems/ruby-2.0.0-p353@test_develop_pr_core-1/gems/rabl-0.9.0/lib/rabl/engine.rb:64:in `to_json'
/usr/local/rvm/gems/ruby-2.0.0-p353@test_develop_pr_core-1/gems/rabl-0.9.0/lib/rabl/engine.rb:39:in `block in render'
/usr/local/rvm/gems/ruby-2.0.0-p353@test_develop_pr_core-1/gems/rabl-0.9.0/lib/rabl/engine.rb:285:in `cache_results'
/usr/local/rvm/gems/ruby-2.0.0-p353@test_develop_pr_core-1/gems/rabl-0.9.0/lib/rabl/engine.rb:39:in `render'
/var/lib/workspace/workspace/test_develop_pr_core/database/postgresql/puppet/3.0/ruby/2.0.0/app/views/api/v1/users/create.json.rabl:2:in `_app_views api_v_users_create_json_rabl___4493772589656306360_147762980'

Seems to be due to oj 2.10.3 which started causing the error. Release notes mention "Rational recursive loop caused by active support fixed".

Associated revisions

Revision 1155fbf1
Added by Dominic Cleal about 3 years ago

fixes #7818 - explicitly render role permissions to fix oj 2.10.3 error

Revision 87ba11c7
Added by Dominic Cleal about 3 years ago

fixes #7818 - explicitly render role permissions to fix oj 2.10.3 error

(cherry picked from commit 1155fbf13a6c6cbcb9f4cdfc2f0907eaddaf2cc5)

History

#1 Updated by The Foreman Bot about 3 years ago

  • Status changed from Assigned to Ready For Testing
  • Pull request https://github.com/theforeman/foreman/pull/1821 added

#2 Updated by Dominic Cleal about 3 years ago

  • Release set to 1.6.1

#3 Updated by Dominic Cleal about 3 years ago

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

Also available in: Atom PDF