[GRASS-dev] [GRASS GIS] #1704: GRASS 7 cli startup enters into write protected/not owned mapset

GRASS GIS trac at osgeo.org
Thu Aug 23 16:01:46 PDT 2012


#1704: GRASS 7 cli startup enters into write protected/not owned mapset
---------------------+------------------------------------------------------
 Reporter:  neteler  |       Owner:  grass-dev@…              
     Type:  defect   |      Status:  new                      
 Priority:  normal   |   Milestone:  7.0.0                    
Component:  Startup  |     Version:  svn-trunk                
 Keywords:           |    Platform:  Linux                    
      Cpu:  x86-64   |  
---------------------+------------------------------------------------------

Comment(by glynn):

 Replying to [ticket:1704 neteler]:
 > When starting GRASS 7 via command line it lets the user
 > enter a mapset not belonging to him/her:

 This isn't specific to 7.0. In 6.x, the ownership check is in
 etc/set_data, which is only used for interactive startup.

 > The wxGUI startup greys out not owned mapsets properly while
 > the CLI startup is missing this check.

 Something like the following in non_interactive() should work, provided
 that g.mapset will work at that point in the startup:
 {{{
 if mapset not in grass.read_command('g.mapset', flags='l').strip().split()
     fatal(_("<%s> is not a valid mapset") % mapset)
 }}}

-- 
Ticket URL: <http://trac.osgeo.org/grass/ticket/1704#comment:2>
GRASS GIS <http://grass.osgeo.org>



More information about the grass-dev mailing list