Opened 2 years ago

Closed 2 years ago

#2580 closed defect (fixed)

wcst_import wrong error cannot create resume file

Reported by: Dimitar Misev Owned by: Bang Pham Huu
Priority: critical Milestone: 10.0
Component: wcst_import Version: 9.8
Keywords: Cc:
Complexity: Medium

Description

Cannot create resume file '/home/eouser/workdir_import/s2-l2a/ingredients/2018/11/01/S2_L2A_32633_B03_10m.resume.json'.
Hint: make sure the folder containing the resume file is writeable for the user running wcst_import.sh.

The directory is writable fine, and I think the problem is that this resume file already existed.

Change History (2)

comment:1 by Bang Pham Huu, 2 years ago

The file doesn't exist actually

ls /home/eouser/workdir_import/s2-l2a/ingredients/2018/11/01/S2_L2A_32633_B03_10m.resume.json
ls: cannot access '/home/eouser/workdir_import/s2-l2a/ingredients/2018/11/01/S2_L2A_32633_B03_10m.resume.json': No such file or directory

It hasn't had any problem to overwrite an existing .resume.json in wcst_import for years.

I think the issue exists somewhere in the json.dump()

      try:
                file = open(resume_file_path, "w")
                json.dump(Resumer.__IMPORTED_DATA_DICT[self.coverage_id], file)
                file.close()
            except Exception as e:
                log.error("Cannot create resume file '{}'. \n"

And the error messages need to add the caught exception to explain why it failed.

comment:2 by Bang Pham Huu, 2 years ago

Resolution: fixed
Status: assignedclosed
Note: See TracTickets for help on using tickets.