Project

General

Profile

Actions

Bug #11328

closed

"Name has already been taken" error when importing Puppet classes

Added by Juan Pablo Lorier over 8 years ago. Updated about 8 years ago.

Status:
Duplicate
Priority:
High
Assignee:
-
Category:
Puppet integration
Target version:
-
Difficulty:
Triaged:
Fixed in Releases:
Found in Releases:

Description

Hi,

I added a new class to common and when importing I get all the classes, even the ones I already have in katello.
This is the trace:
ActiveRecord::RecordInvalid
Validation failed: Name has already been taken
app/services/puppet_class_importer.rb:272:in `find_or_create_env'
app/services/puppet_class_importer.rb:192:in `add_classes_to_foreman'
app/services/puppet_class_importer.rb:59:in `block in obsolete_and_new'
app/services/puppet_class_importer.rb:57:in `each'
app/services/puppet_class_importer.rb:57:in `obsolete_and_new'
app/controllers/concerns/foreman/controller/environments.rb:30:in `obsolete_and_new'
app/controllers/concerns/application_shared.rb:13:in `set_timezone'
app/models/concerns/foreman/thread_session.rb:32:in `clear_thread'
lib/middleware/catch_json_parse_errors.rb:9:in `call'


Related issues 3 (2 open1 closed)

Related to Foreman - Bug #14339: PuppetClassImporter doesn't respect access control or taxonomiesNew03/23/2016Actions
Has duplicate Foreman - Bug #11453: Warning! Validation failed: Name has already been takenDuplicate08/23/2015Actions
Is duplicate of Foreman - Bug #10906: Puppet environment import returns 500 because it exists in different organizationNew06/23/2015Actions
Actions #1

Updated by Dominic Cleal over 8 years ago

  • Subject changed from Error importing classes Katello 2.2 to "Name has already been taken" error when importing Puppet classes
  • Category set to Puppet integration
Actions #2

Updated by Dominic Cleal over 8 years ago

  • Has duplicate Bug #11453: Warning! Validation failed: Name has already been taken added
Actions #3

Updated by Sean O'Keeffe about 8 years ago

  • Related to Bug #14339: PuppetClassImporter doesn't respect access control or taxonomies added
Actions #4

Updated by Dominic Cleal about 8 years ago

  • Is duplicate of Bug #10906: Puppet environment import returns 500 because it exists in different organization added
Actions #5

Updated by Dominic Cleal about 8 years ago

  • Status changed from New to Duplicate

Thanks for the report, we're going to track this under ticket #10906. This appears to be an issue with orgs/locs, where the existing environment isn't assigned to the org/loc that you're currently using - add it to the current org/loc and it should be OK, or perhaps try using Any Context.

Actions

Also available in: Atom PDF