#8677: race condition creating dirs during Sage build on RH 5.4
-----------------------------+----------------------------------------------
   Reporter:  GeorgSWeber    |       Owner:  GeorgSWeber 
       Type:  defect         |      Status:  needs_review
   Priority:  blocker        |   Milestone:  sage-4.6    
  Component:  build          |    Keywords:              
     Author:  William Stein  |    Upstream:  N/A         
   Reviewer:                 |      Merged:              
Work_issues:                 |  
-----------------------------+----------------------------------------------

Comment(by vbraun):

 A correctly working NFSv3 shouldn't need the `async` options to achieve
 fast writes, but maybe some older servers/clients are being used? With
 `async`, data will be corrupted if the server crashes, but thats probably
 acceptable on a build system.

 I take issue with the patch, however. The current race seems to be
 {{{
     if not os.path.exists(path):
         # another process can create path here
         os.makedirs(path)
         # error!
 }}}
 The correct fix would be to replace the whole if clause with
 {{{
     try:
         os.makedirs(path)
     except OSError:
         pass
 }}}
 But the patch mixes up both. It still contains the original race and then
 hacks around it to trap the error.

-- 
Ticket URL: <http://trac.sagemath.org/sage_trac/ticket/8677#comment:7>
Sage <http://www.sagemath.org>
Sage: Creating a Viable Open Source Alternative to Magma, Maple, Mathematica, 
and MATLAB

-- 
You received this message because you are subscribed to the Google Groups 
"sage-trac" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to 
[email protected].
For more options, visit this group at 
http://groups.google.com/group/sage-trac?hl=en.

Reply via email to