View Issue Details Jump to Notes ] Issue History ] Print ]
IDProjectCategoryView StatusDate SubmittedLast Update
0011737CDash(No Category)public2011-01-20 18:452011-12-22 16:36
ReporterPeter Colberg 
Assigned ToJulien Jomier 
PrioritynormalSeveritymajorReproducibilityalways
StatusresolvedResolutionfixed 
PlatformLinux (x86)OSDebian GNU/LinuxOS Versionsqueeze
Product Version 
Target VersionFixed in Version2.0 
Summary0011737: CDash submission fails due to wrong parsing of geolocation info
DescriptionOn some hosts, submission of test reports reproducibly fails, leaving these errors in the CDash log:

[2011-01-20T17:31:12][ERROR][pid=2391](Site Insert): SQL error: ERROR: value too long for type character varying(10)
[2011-01-20T17:31:12][ERROR][pid=2391](GetIdFromName): SQL error: ERROR: value too long for type character varying(10)
[2011-01-20T17:31:12][ERROR][pid=2391](Build:UpdateTestNumbers): SQL error: ERROR: value too long for type character varying(10)
[2011-01-20T17:31:12][ERROR][pid=2391](Build::ComputeTestTiming): BuildId is not set

Upon closer inspection, this error seems to be caused by erroneous parsing in
function get_geolocation. For a particular client host, api.hostip.info returns
the following data (IP blanked):

Country: GERMANY (DE)
City: Munich

Latitude: 48.1333
Longitude: 11.5833
IP: ***.***.***.***

The location data is translated into this SQL command:

INSERT INTO site (name,ip,latitude,longitude)
                  VALUES ('hostname','***.***.***.***','48.1333','11.5833
IP: ***.***.***.***
'

As seen above, the longitude field also includes the IP address.
This is fixed by limiting the substr range to the end of the "Longitude:" line.
Steps To Reproduce1. Create pristine build tree of project using CMake.
2. Run "ctest -D Experimental" in build tree.
3. Submission fails if (public) host IP is known to api.host.info with latitude/longitude.
Additional InformationCDash 1.8.2, PHP 5.3.3, PostgresQL 8.4.5
TagsNo tags attached.
Attached Filespatch file icon cdash_fix_geo_location_longitude.patch [^] (491 bytes) 2011-01-20 18:45 [Show Content]

- Relationships Relation Graph ] Dependency Graph ]

-  Notes
(0028052)
Julien Jomier (manager)
2011-12-22 16:36

Thanks for the report and the patch!

- Issue History
Date Modified Username Field Change
2011-01-20 18:45 Peter Colberg New Issue
2011-01-20 18:45 Peter Colberg File Added: cdash_fix_geo_location_longitude.patch
2011-12-22 16:35 Julien Jomier Assigned To => Julien Jomier
2011-12-22 16:35 Julien Jomier Status new => assigned
2011-12-22 16:36 Julien Jomier Note Added: 0028052
2011-12-22 16:36 Julien Jomier Status assigned => resolved
2011-12-22 16:36 Julien Jomier Fixed in Version => 2.0
2011-12-22 16:36 Julien Jomier Resolution open => fixed


Copyright © 2000 - 2018 MantisBT Team
Powered by Mantis Bugtracker