afero
afero copied to clipboard
Set working directory for FS
Is it possible? If not, should it ?
Agreed, since this security update (https://groups.google.com/g/golang-announce/c/L_3rmdT0BMU/m/yZDrXjIiBQAJ), there is a need to set the root dir:
The behavior of os.DirFS("") has changed. Previously, an empty root was treated equivalently to "/", so os.DirFS("").Open("tmp") would open the path "/tmp". This now returns an error.
Otherwise I get an error when trying to open file: stat tmp/errors_dk1.csv.zip: os: DirFS with empty root