Skip to content
GitLab
  • Menu
Projects Groups Snippets
  • /
  • Help
    • Help
    • Support
    • Community forum
    • Submit feedback
    • Contribute to GitLab
  • Sign in
  • P PyFstat
  • Project information
    • Project information
    • Activity
    • Labels
    • Members
  • Repository
    • Repository
    • Files
    • Commits
    • Branches
    • Tags
    • Contributors
    • Graph
    • Compare
  • Issues 0
    • Issues 0
    • List
    • Boards
    • Service Desk
    • Milestones
  • Merge requests 0
    • Merge requests 0
  • Deployments
    • Deployments
    • Releases
  • Monitor
    • Monitor
    • Incidents
  • Analytics
    • Analytics
    • Value stream
    • Repository
  • Wiki
    • Wiki
  • Activity
  • Graph
  • Create a new issue
  • Commits
  • Issue Boards
Collapse sidebar
  • Gregory Ashton
  • PyFstat
  • Issues
  • #13
Closed
Open
Created Aug 31, 2018 by Reinhard Prix@ReinhardPrixMaintainer

Potentially dangerous (on clusters) temp-file naming policy in Writer.predict_Fstat()

In debugging some confusing behavior/problems of pyFstat on a cluster, I noticed that the method predict_fstat() of the class Writer, in make_sfts.py:257 uses the 'label' argument to construct the filename for the temporary internal file ('temporyFile') in the user's home-dir they launched the jobs from. This is potentially confusing/dangerous, as it's not documented (I believe) and as there's also the argument 'outdir', which is more obvious to be required to be unique on cluster runs. What can happen here is that someone uses the same label for all jobs of a cluster run, gives every job a unique 'outdir', and still jobs will fall over themselves when all trying to read-read-delete the same temporary file in predict_fstat().

As as fix I would simply suggest to place that temporary file inside the 'outdir' as well, then there should be no problems.

To upload designs, you'll need to enable LFS and have an admin enable hashed storage. More information
Assignee
Assign to
Time tracking