Bug 619083
| Summary: | cannot push rhel4 package, TypeError: expecting numeric data | |||
|---|---|---|---|---|
| Product: | [Community] Spacewalk | Reporter: | Petr Sklenar <psklenar> | |
| Component: | Server | Assignee: | Jan Pazdziora (Red Hat) <jpazdziora> | |
| Status: | CLOSED CURRENTRELEASE | QA Contact: | Red Hat Satellite QA List <satqe-list> | |
| Severity: | medium | Docs Contact: | ||
| Priority: | high | |||
| Version: | 1.1 | CC: | jpazdziora | |
| Target Milestone: | --- | Keywords: | Reopened | |
| Target Release: | --- | |||
| Hardware: | All | |||
| OS: | Linux | |||
| Whiteboard: | ||||
| Fixed In Version: | spacewalk-backend-1.3.35-1 | Doc Type: | Bug Fix | |
| Doc Text: | Story Points: | --- | ||
| Clone Of: | ||||
| : | 665775 (view as bug list) | Environment: | ||
| Last Closed: | 2011-02-08 08:41:06 UTC | Type: | --- | |
| Regression: | --- | Mount Type: | --- | |
| Documentation: | --- | CRM: | ||
| Verified Versions: | Category: | --- | ||
| oVirt Team: | --- | RHEL 7.3 requirements from Atomic Host: | ||
| Cloudforms Team: | --- | Target Upstream Version: | ||
| Embargoed: | ||||
| Bug Depends On: | ||||
| Bug Blocks: | 653453 | |||
|
Description
Petr Sklenar
2010-07-28 14:21:30 UTC
[root@xen96 ~]# cat /etc/fedora-release Fedora release 13 (Goddard) [root@xen96 ~]# rpm -q rhnpush spacewalk-backend spacewalk-schema rhnpush-5.5.4-1.fc13.noarch spacewalk-backend-1.2.1-1.fc13.noarch spacewalk-schema-1.1.30-1.fc13.noarch [root@xen96 ~]# rhnpush -v --server=localhost --username=admin --pass XXX --channel bug523146-1619 zsh-4.2.0-4.EL.4.5.i386.rpm Connecting to http://localhost/APP Package zsh-4.2.0-4.EL.4.5.i386.rpm Not Found on RHN Server -- Uploading Uploading package zsh-4.2.0-4.EL.4.5.i386.rpm Using POST request And package is avaiable in webUI. I've bumped up the debug and the difference between RHEL 5 and Fedora 13 (both i386) is that on RHEL 5 (python 2.4), verifyflags for that zsh rpm are -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, -1, -1, -1, -1, -1, ... while on Fedora 13 (python 2.6, should that be the main difference), the values are 4294967295L, 4294967295L, 4294967295L, 4294967295L, 4294967295L, 42 94967295L, 4294967295L, 4294967295L, 4294967295L, 4294967295L, 4294967295L, 4294967295L, 4294967295L, 4294967295L, 4294967295L, 4294967295L, 4294967295L, 429496 7295L, 4294967295L, 4294967295L, 4294967295L, 4294967295L, 4294967295L, 4294967295L, 4294967295L, 4294967295L, 4294967295L, 4294967295L, 4294967295L, 4294967295 L, 4294967295L, 4294967295L, 4294967295L, 4294967295L, 4294967295L, 4294967295L, 4294967295L, 4294967295L, 4294967295L, 4294967295L, 4294967295L, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4294967295L, 4294967295L, 4294967295L, 4294967295L, ... Also, when I've forced the chunk_size to be 1 in _executemany in driver_cx_Oracle.py, the thing passes on Fedora 13.
When I've changed it to 2, it fails in the situation when one dictionary has 4294967295L while the next one has (string) '0':
Exception: expecting numeric data [{'username': 'root', 'lang': None, 'file_mode': '33261', 'capability_id': '306', 'file_siz
e': '22684', 'rdev': '0', 'verifyflags': 4294967295L, 'groupname': 'root', 'package_id': '3', 'flags': '0', 'mtime': '2006-10-03 16:25:37', 'checksum_id': '508'
, 'device': '2305', 'inode': '5030967', 'linkto': None}, {'username': 'root', 'lang': None, 'file_mode': '16877', 'capability_id': '338', 'file_size': '4096', '
rdev': '0', 'verifyflags': '0', 'groupname': 'root', 'package_id': '3', 'flags': '0', 'mtime': '2006-10-03 16:25:37', 'checksum_id': None, 'device': '2305', 'in
ode': '5031689', 'linkto': None}]
[Sun Dec 26 16:27:32 2010] [error]
When I turn off the stringification of [types.IntType, types.FloatType] in adjust_type in sql_base.py, the rhnpush passes on Fedora 13. By the way, on my Satellite 5.4 (RHEL 5 obviously), the following select returns mostly negative values:
SQL> select VERIFYFLAGS, count(*) from rhnpackagefile group by VERIFYFLAGS ;
VERIFYFLAGS COUNT(*)
----------- ----------
-40 93987
-116 55068
-100 84
-36 66689
-60 13
-1 17756599
3 186
-256 34
0 995705
-33 10644826
-104 134
-5 600
12 rows selected.
SQL>
That probably is not correct, is it?
I've filed Satellite bug 665775 to track investigation of the existing negative values in our databases. Aligning under space13. Taking. Fixed in Spacewalk master, 77efefcf49a269db0870a4ec4b49368c77eea6a3. We try not to stringify the numerical values and we shall see how it works on RHEL and Fedora, on Oracle and PostgreSQL. The reason for this change is that the drivers (cx_Oracle, psycopg2) should handle the types just fine, or convert them. Tagged and built as spacewalk-backend-1.3.35-1. Moving ON_QA ... This bug has been fixed in Spacewalk 1.3. |