Bug 727627

Summary: Cannot navigate to sync page after starting a sync
Product: Red Hat Satellite 6 Reporter: Corey Welton <cwelton>
Component: WebUIAssignee: Shannon Hughes <shughes>
Status: CLOSED CURRENTRELEASE QA Contact: Katello QA List <katello-qa-list>
Severity: unspecified Docs Contact:
Priority: unspecified    
Version: 6.0.0CC: jweiss, mmccune, sghai, shughes
Target Milestone: UnspecifiedKeywords: Regression, Triaged
Target Release: Unused   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2012-08-22 17:51:30 UTC Type: ---
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Bug Depends On:    
Bug Blocks: 747354    

Description Corey Welton 2011-08-02 16:13:54 UTC
Description of problem:
If user initiates a sync and then tries to navigate back to it, a "NoMethodError" page is thrown. User cannot not navigate back

Version-Release number of selected component (if applicable):


How reproducible:


Steps to Reproduce:
1.  Configure a provider, either a RH or (possibly) something else.
2.  Begin sync.
3.  Wait a few minutes, navigate away from sync UI
4. Navigate back
  
Actual results:
NoMethodError in Sync managementController#index

undefined method `to_sym' for nil:NilClass

Rails.root: /usr/lib64/katello
Application Trace | Framework Trace | Full Trace

app/helpers/translation_helper.rb:15:in `relative_time_in_words'
app/controllers/sync_management_controller.rb:112:in `format_date'
app/controllers/sync_management_controller.rb:98:in `format_sync_progress'
app/controllers/sync_management_controller.rb:46:in `index'
app/controllers/sync_management_controller.rb:44:in `each'
app/controllers/sync_management_controller.rb:44:in `index'
app/controllers/sync_management_controller.rb:40:in `each'
app/controllers/sync_management_controller.rb:40:in `index'
lib/util/threadsession.rb:77:in `thread_locals'

Request

Parameters:

None

Show session dump

Show env dump
Response

Headers:

None



Expected results:
User can navigate back to sync page

Additional info:

Comment 1 Jeff Weiss 2011-08-03 19:39:04 UTC
*** Bug 727674 has been marked as a duplicate of this bug. ***

Comment 2 Mike McCune 2011-08-15 18:30:30 UTC
Fixed in 11623e48fceb9d9af60d9b39fd6bf46ed8e4080b

commit 11623e48fceb9d9af60d9b39fd6bf46ed8e4080b
Author: Mike McCune <mmccune@redhat.com>
Date:   Mon Aug 15 11:29:08 2011 -0700

    switching to a simpler string substitution that wont blow up on nil

diff --git a/src/app/helpers/translation_helper.rb b/src/app/helpers/translation_helper.rb
index c49c16b..241aa5e 100644
--- a/src/app/helpers/translation_helper.rb
+++ b/src/app/helpers/translation_helper.rb
@@ -12,11 +12,7 @@
 
 module TranslationHelper
   def relative_time_in_words(time)
-    begin
-      _("%{relative_time} ago") % {:relative_time => time_ago_in_words(time)}
-    rescue NoMethodError => e
-      Rails.logger.error "Error converting to relative_time_in_words: " + e
-    end
+    _("%s ago") % time_ago_in_words(time)
   end

Comment 3 Sachin Ghai 2011-08-18 08:56:00 UTC
Verified with latest katello build:

[root@dhcp201-207 ~]# rpm -qa | grep katello
katello-0.1.64-1.git.0.0b431ff.fc15.noarch
[root@dhcp201-207 ~]# 

I started a repo sync. After few minutes, I navigate to "provider" tab and then navigate back to sync UI tab, didn't see any error on UI.

To confirm, I directly navigated to system tab and then back sync UI, this time again reported error was not reproducible.