Opened 10 years ago

Last modified 4 years ago

#966 new defect

wx attribute table manger fails on wingrass with >188 dbf tables

Reported by: hamish Owned by: grass-dev@…
Priority: normal Milestone: 6.4.6
Component: wxGUI Version: svn-releasebranch64
Keywords: wingrass Cc:
CPU: x86-32 Platform: MSWindows XP

Description

Hi,

as reported to the -users ML:

http://n2.nabble.com/Bug-or-my-fault-td4609390.html

On latest nightly builds of 6.4.0svn WinGrass if you have a mapset with >188 dbf tables you get an error when you try to edit in the attribute table gui.

I can reproduce this on Windows XP (spaces in both $GISBASE and $GISDBASE) but not on Linux (no spaces in path names). But I get an error, no infinite loop.

  • create a new mapset called eg test255
  • at the msys prompt create a bunch of maps:
    for i in `seq 350` ; do
      v.random out=test_$i column=rand_01 zmax=1
    done
    
  • test with v.db.select test_262
  • add map to Layer Manager, query it, no problem.
  • right click on map name in layer manager, edit attributes.
  • attribute manager opens
  • right click on an entry, edit it, and click Submit.
  • you get a popup error window:
    __Error in command execution db.execute__
    
    Execution failed: 'db.execute input=c:\docume~1\hamish\locals~1\temp\tmprnzmdi driver=dbf
    database=C:\Documents and Settings\Hamish\grassdata/spearfish60/user255/dbf/'
    
    Details:
    Error:
    
    [Ok]
    

and in the layer manager Output tab:

Traceback ...
  File "c:\Program
Files\GRASS-64-SVN\etc\wxpython\gui_modules\dbm.py", line
1425, in OnDataItemEdit

self.ApplyCommands()
  File "...\dbm.py", line 1783, in ApplyCommands

gcmd.Command(cmd)
  File "...\gcmd.py", line 356, in __init__

_("Error: ") + self.GetError()))
gui_modules.gcmd
.
CmdError

If I run db.execute directly from the msys prompt it works ok:

echo "UPDATE test_285 SET rand_01=0.999 WHERE cat=12" | db.execute
v.db.select test_285

Hamish

Change History (4)

comment:1 Changed 9 years ago by hellik

Milestone: 6.4.06.4.2

comment:2 Changed 7 years ago by hamish

needs to be retested with a modern build

comment:3 Changed 7 years ago by hamish

retested with the latest 6.5svn nightly snapshot and whatever the heck the trouble was here seems to be fixed now.

In testing notice a couple other little bugletts.

  • even though the column is double precision the attribute manager displays the value as single precision %f. Submitting a double precision number there gets rounded to single precision.
  • in the cursor query tool on the main map display the vector layer doesn't have to be in 'Start editing' mode to change the value of what's selected, or a tick box in the query result window which comes up. Raw data is sacred and should be read-only unless the user specifically asked for it not to be. (with d.what.vect you had to use the -e flag to make it editable)

Hamish

comment:4 Changed 4 years ago by neteler

Milestone: 6.4.26.4.6
Note: See TracTickets for help on using tickets.