Bug 987670 - CLI: Env/org name and Label needs to have same character limit. Creating an env/org name with more that 128 characters throws an incorrect error string.
CLI: Env/org name and Label needs to have same character limit. Creating an e...
Status: CLOSED ERRATA
Product: Subscription Asset Manager
Classification: Red Hat
Component: katello (Show other bugs)
1.3
Unspecified Unspecified
unspecified Severity low
: rc
: 1.3
Assigned To: Bryan Kearney
SAM QE List
:
Depends On:
Blocks: sam13-tracker 995937
  Show dependency treegraph
 
Reported: 2013-07-23 16:43 EDT by Apurva Bhole
Modified: 2013-10-01 07:14 EDT (History)
5 users (show)

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
: 995937 (view as bug list)
Environment:
Last Closed: 2013-10-01 07:14:14 EDT
Type: Bug
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---


Attachments (Terms of Use)

  None (edit)
Description Apurva Bhole 2013-07-23 16:43:40 EDT
Description of problem:
When attempting to create an environment with name longer than 128 characters, the error string thrown is incorrect

Version-Release number of selected component (if applicable):
katello-selinux-1.4.3-1.git.4.99dc194.el6.noarch
katello-qpid-broker-key-pair-1.0-1.noarch
katello-all-1.4.2-1.git.951.091dd45.el6.noarch
signo-katello-0.0.9-1.el6.noarch
katello-glue-pulp-1.4.2-1.git.951.091dd45.el6.noarch
katello-candlepin-cert-key-pair-1.0-1.noarch
katello-cli-1.4.2-1.git.131.cacfdea.el6.noarch
katello-configure-1.4.3-1.git.67.f71e590.el6.noarch
katello-common-1.4.2-1.git.951.091dd45.el6.noarch
katello-glue-candlepin-1.4.2-1.git.951.091dd45.el6.noarch
katello-certs-tools-1.4.2-1.el6.noarch
katello-1.4.2-1.git.951.091dd45.el6.noarch
katello-repos-1.4.2-1.el6.noarch
katello-cli-common-1.4.2-1.git.131.cacfdea.el6.noarch
katello-glue-elasticsearch-1.4.2-1.git.951.091dd45.el6.noarch
katello-qpid-client-key-pair-1.0-1.noarch

How reproducible:
everytime

Steps to Reproduce:
1. org create --name FirstOrg
2. environment create --org "FirstOrg" --name "012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789abcdefghi" --prior "Library"

Actual results:
Validation failed: Label cannot contain more than 128 characters

Expected results:
Validation failed: Name cannot contain more than 128 characters
Comment 1 Apurva Bhole 2013-07-24 15:21:23 EDT
This is also an issue for org name with more than 128 characters. If
Comment 2 sthirugn@redhat.com 2013-07-24 15:29:33 EDT
Also observed in Product and Repository fields.  

The entire affected list is:
1. Organization
2. Environment
3. Product
4. Repository
Comment 3 Og Maciel 2013-07-24 15:34:32 EDT
For environments, I believe what we want is the message to state that *both* name and label for the environment cannot be longer than 128 characters. The same probably applies to the other areas.
Comment 4 Sachin Ghai 2013-07-25 06:45:28 EDT
The same issue I found with content-view definitions.  Earlier the limit for CV definition was 128 characters for both Label and name. Now for 'name' the limit is 255 characters and for label is 128.

Ideally, it should be 128 characters for both name and label.
Comment 5 Bryan Kearney 2013-08-02 14:52:04 EDT
SNAP0 contains these bug fixes. Moving to ON_QA.
Comment 7 Tazim Kolhar 2013-08-13 02:45:41 EDT
VERIFIED :

# rpm -qa | grep katello
katello-selinux-1.4.4-2.el6sat.noarch
katello-candlepin-cert-key-pair-1.0-1.noarch
katello-certs-tools-1.4.2-2.el6sat.noarch
katello-cli-common-1.4.3-5.el6sat.noarch
katello-cli-1.4.3-5.el6sat.noarch
katello-common-1.4.3-6.el6sam_splice.noarch
katello-configure-1.4.4-2.el6sat.noarch
katello-glue-elasticsearch-1.4.3-6.el6sam_splice.noarch
katello-headpin-all-1.4.3-6.el6sam_splice.noarch
katello-glue-candlepin-1.4.3-6.el6sam_splice.noarch
signo-katello-0.0.10-2.el6sat.noarch
katello-headpin-1.4.3-6.el6sam_splice.noarch


Org create with label of 128 characters shows appropriate error :

# headpin -u admin -p **** org create --name "012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789abcdefghi" --label  "012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789abcdefghi"
Validation failed: Label cannot contain more than 128 characters

Org names with 128 characters works correctly :

# headpin -u admin -p **** org create --name "012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789abcdefghi"
Successfully created org [ 012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789abcdefghi ]
Comment 9 errata-xmlrpc 2013-10-01 07:14:14 EDT
Since the problem described in this bug report should be
resolved in a recent advisory, it has been closed with a
resolution of ERRATA.

For information on the advisory, and where to find the updated
files, follow the link below.

If the solution does not work for you, open a new bug report.

http://rhn.redhat.com/errata/RHEA-2013-1390.html

Note You need to log in before you can comment on or make changes to this bug.