Bug 970463 - Adding custom info value (length > 255 characters) for system failed
Summary: Adding custom info value (length > 255 characters) for system failed
Keywords:
Status: CLOSED DUPLICATE of bug 951228
Alias: None
Product: Red Hat Satellite
Classification: Red Hat
Component: Content Management
Version: Nightly
Hardware: x86_64
OS: Linux
unspecified
low
Target Milestone: Unspecified
Assignee: Adam Price
QA Contact: Katello QA List
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2013-06-04 05:37 UTC by Tazim Kolhar
Modified: 2016-04-26 00:55 UTC (History)
6 users (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2013-06-12 20:54:23 UTC
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)

Description Tazim Kolhar 2013-06-04 05:37:26 UTC
Description of problem:
Adding custom info value (length > 255 characters) for system failed  

Version-Release number of selected component (if applicable):
# rpm -qa | grep katello
katello-cli-common-1.4.2-6.el6sat.noarch
katello-glue-elasticsearch-1.4.2-8.el6sat.noarch
signo-katello-0.0.15-1.el6sat.noarch
katello-candlepin-cert-key-pair-1.0-1.noarch
katello-certs-tools-1.4.2-2.el6sat.noarch
katello-configure-1.4.3-12.el6sat.noarch
katello-common-1.4.2-8.el6sat.noarch
katello-headpin-1.4.2-8.el6sat.noarch
katello-glue-candlepin-1.4.2-8.el6sat.noarch
katello-headpin-all-1.4.2-8.el6sat.noarch
katello-cli-1.4.2-6.el6sat.noarch
katello-selinux-1.4.3-3.el6sat.noarch


How reproducible:
# yum install -y katello-headpin-all
# katello-configure --user-pass=****

Steps to Reproduce:
1. headpin --username "admin" --password **** system custom_info add --name "sys-CustomInfo-1370299136" --org "org-sys-1370299136" --keyname "desc-256Chars1370299545" --value "0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789abcdef"
Stdout:
Stderr:
PGError: ERROR: value too long for type character varying(255)
: INSERT INTO "custom_info" ("created_at", "informable_id", "informable_type", "keyname", "updated_at", "value") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id"
ExitCode: 244



Actual results:
The cli command failed

Expected results:
The command throws proper error

Additional info:

Please, refer 
- http://hudson.rhq.lab.eng.bos.redhat.com:8080/hudson/job/official-headpin-cli/127/ReportNG_Report/

Comment 1 Garik Khachikyan 2013-06-04 13:32:20 UTC
also: please try to catch the error in a level higher than PG is.

Comment 3 Adam Price 2013-06-12 19:45:57 UTC
https://github.com/Katello/katello/pull/2363

Comment 6 Adam Price 2013-06-12 20:54:23 UTC

*** This bug has been marked as a duplicate of bug 951228 ***


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