bugpyFormex - Bugs: bug #46040, gtscheck is not working

 
 

bug #46040: gtscheck is not working

Submitted by:  gianluca de santis <gianlucadesi>
Submitted on:  Wed 23 Sep 2015 02:04:54 PM UTC  
 
Category: CoreSeverity: 4 - Important
Item Group: Functionality errorStatus: Fixed
Privacy: PublicAssigned to: None
Open/Closed: Closed

Add a New Comment(Rich Markup)
   

You are not logged in

Please log in, so followups can be emailed to you.

 

(Jump to the original submission Jump to the original submission)

Wed 23 Sep 2015 03:57:36 PM UTC, comment #6:

Solved! I will close the bug.

gianluca de santis <gianlucadesi>
Project Member
Wed 23 Sep 2015 03:25:34 PM UTC, comment #5:

In commit d0a4a82 I have implemented the last suggestion of
https://savannah.nongnu.org/bugs/?46040#comment4

Benedict Verhegghe <bverheg>
Project Administrator
Wed 23 Sep 2015 03:20:06 PM UTC, comment #4:

That is correct: a 'shell=True' should be added, because input redirection is used in the command (<), which is a shell characteristic.

Alternatively (and more effective and cleaner), we could use the stdin variable to directly specify the stdin for the gtscheck command:

Benedict Verhegghe <bverheg>
Project Administrator
Wed 23 Sep 2015 03:13:05 PM UTC, comment #3:

Indeed, shell should be True in trisurface.py line 2080:
P = utils.system(cmd)
should be replaced by
P = utils.system(cmd, shell=True)

gianluca de santis <gianlucadesi>
Project Member
Wed 23 Sep 2015 03:08:41 PM UTC, comment #2:

Saving the surface 'm' from the example https://savannah.nongnu.org/bugs/download.php?file_id=34963
and using gtscheck from the command line, produces errors like:

Gts-CRITICAL **: gts_segment_new: assertion 'v1 != v2' failed

and finally a segmentation error and exit code 139.

It turns out that there are degenerate elements in the surface (likely generated by the fuse operation).

After adding a removeDegenerate, the gtscheck command runs fine and with -v produces the following info:

and exits with return code 3.

So it looks like the exit codes are not properly transfered through utils.system.

Benedict Verhegghe <bverheg>
Project Administrator
Wed 23 Sep 2015 03:07:24 PM UTC, comment #1:

Apparently, the gtscheck does not work if command is executed with shell=False (default).

You can see in the new attached example.

I suggest to replace in trisurface.py line 2080:
P = utils.system(cmd)
with
P = utils.system(cmd, shell=True)

(file #34965)

gianluca de santis <gianlucadesi>
Project Member
Wed 23 Sep 2015 02:04:54 PM UTC, original submission:

It seems that TriSurface.check() always return status 0. I do not know whether the problem is gtscheck or utils.Process using the gtscheck.I do not find on GITK when the gtscheck has been changed. I have added an example demonstrating the problem.

gianluca de santis <gianlucadesi>
Project Member

 

(Note: upload size limit is set to 16384 kB, after insertion of the required escape characters.)

Attach File(s):
   
   
Comment:
   

Attached Files
file #34965:  verifygtscheck.py added by gianlucadesi (2KiB - text/x-python)

 

Depends on the following items: None found

Items that depend on this one: None found

 

Carbon-Copy List
  • -unavailable- added by bverheg (Posted a comment)
  • -unavailable- added by gianlucadesi (Submitted the item)
  •  

    Do you think this task is very important?
    If so, you can click here to add your encouragement to it.
    This task has 0 encouragements so far.

    Only logged-in users can vote.

     

    Please enter the title of George Orwell's famous dystopian book (it's a date):

     

     

    Follow 5 latest changes.

    Date Changed By Updated Field Previous Value => Replaced By
    Wed 23 Sep 2015 03:57:36 PM UTCgianlucadesiStatusNone=>Fixed
      Open/ClosedOpen=>Closed
    Wed 23 Sep 2015 03:07:24 PM UTCgianlucadesiAttached File-=>Added verifygtscheck.py, #34965
    Wed 23 Sep 2015 03:05:19 PM UTCgianlucadesiAttached File#34963=>Removed
    Wed 23 Sep 2015 02:04:54 PM UTCgianlucadesiAttached File-=>Added verifygtscheck.py, #34963

    Back to the top


    Powered by Savane 3.1-cleanup1