[QGIS-trac] [Quantum GIS] #1205: No valid projection. Unable to set map units.

Quantum GIS qgis at qgis.org
Tue Aug 5 18:11:19 EDT 2008


#1205: No valid projection. Unable to set map units.
------------------------------------------------+---------------------------
   Reporter:  jcs                               |              Owner:  nobody       
       Type:  bug                               |             Status:  new          
   Priority:  major: does not work as expected  |          Milestone:  Version 1.0.0
  Component:  MapCanvas                         |            Version:  HEAD         
   Keywords:  QgsSpatialRefSys                  |   Platform_version:               
   Platform:  RedHat                            |           Must_fix:  No           
Status_info:  0                                 |  
------------------------------------------------+---------------------------
 A vanilla build of 0.11.0 produces numerous prints of "No valid
 projection. Unable to set map units."

 This is unavoidable and can be seen by following the execution of
 QgsSpatialRefSys::loadFromDb().

 At the top of this function mIsValidFlag is set to false.  This variable
 is only set to true '''after''' a call to setMapUnits().

 But the first thing setMapUnits() does is check mIsValidFlag which in this
 case will always be false and the print will be executed.

 Moving the mIsValidFlag = true before setMapUnits() fixes the "No valid
 projection. Unable to set map units." prints but this may not be what the
 author had in mind.[[BR]]

-- 
Ticket URL: <https://trac.osgeo.org/qgis/ticket/1205>
Quantum GIS <http://qgis.org>
Quantum GIS is an Open Source GIS viewer/editor supporting OGR, PostGIS, and GRASS formats


More information about the QGIS-trac mailing list