Project

General

Profile

Actions

Bug #1010

closed

import new classes does not show error-message

Added by Alexander Rusa almost 13 years ago. Updated almost 13 years ago.

Status:
Closed
Priority:
Normal
Assignee:
Category:
Web Interface
Target version:
Difficulty:
Triaged:
Fixed in Releases:
Found in Releases:

Description

If I click on "Import new puppet classes and environments" at the Puppet Classes page and foreman doesn't find the modules-directory it doesn't print an error-message.

If I do the same on the Environments page it does show an error ("Unable to find directory ... in environment ...")

Actions #1

Updated by Ohad Levy almost 13 years ago

Can you try this patch?

diff --git a/app/controllers/puppetclasses_controller.rb b/app/controllers/puppetclasses_controller.rb
index 746b382..3b41947 100644
--- a/app/controllers/puppetclasses_controller.rb
+++ b/app/controllers/puppetclasses_controller.rb
@@ -7,7 +7,6 @@ class PuppetclassesController < ApplicationController
   def index
     begin
       values = Puppetclass.search_for(params[:search], :order => params[:order])
-      flash.clear
     rescue => e
       error e.to_s
       values = Puppetclass.search_for "" 
Actions #2

Updated by Alexander Rusa almost 13 years ago

I deleted the "flash.clear" and now it shows the error correctly but i didn't manage to apply the patch by using git apply - maybe this is because I haven't got enough practice with git patches ;-)

$ git apply --check <patch>
error: patch failed: app/controllers/puppetclasses_controller.rb:7
error: app/controllers/puppetclasses_controller.rb: patch does not apply
Actions #3

Updated by Ohad Levy almost 13 years ago

  • Category set to Web Interface
  • Target version set to 0.4

naa.. it wasnt a proper git patch.

I'll add it to the repo officially, so you would simply get it with a git pull.

you would probably need to do git checkout app/controllers/puppetclasses_controller.rb first (so git could apply the patch).

Actions #4

Updated by Ohad Levy almost 13 years ago

  • Assignee set to Ohad Levy
Actions #5

Updated by Ohad Levy almost 13 years ago

  • Status changed from New to Closed
  • % Done changed from 0 to 100
Actions

Also available in: Atom PDF