BrettMayson / HEMTT

Build System for Arma 3
http://hemtt.dev/
GNU General Public License v2.0
115 stars 40 forks source link

`hemtt new` crashes to an IO error #686

Closed Tuupertunut closed 6 months ago

Tuupertunut commented 7 months ago

Tools:

Description:

Running hemtt new to create a new project crashes with an IO Error: No such file or directory (os error 2).

Steps to reproduce:

  1. Go to a directory.
  2. Delete any .hemttout directory there might be.
  3. Run hemtt new and answer the dialog with any answers.
  4. Observe a crash at the end of the dialog.

Logs:

Terminal session:

myusername@dx6-523-005:/tmp$ /cs/group/gurula/arma-tools/hemtt new multiplayer_view_distance
Example: Advanced Banana Environment
Project Name: abc
Example: ABE Team
Author: abc
Example: abe
Prefix: abc
Main Prefix: z
Select a license: Arma Public License Share Alike (APL-SA)
ERROR IO Error: No such file or directory (os error 2)

Syscall trace from strace -t -f -s 64 -e trace=write,%file: trace.txt

Additional context:

The issue seems to come from a call to OpenOptions::open() here: https://github.com/BrettMayson/HEMTT/blob/e5e0d867be32c36afcdb69c233fdb1e560998f4e/bin/src/report.rs#L33-L35

Only the append() option is enabled which means a new file will not be created, but I don't have a ci_annotations.txt file yet.

Also another note: Is the .hemttout directory supposed to be created inside the project directory or outside of it? Now it is created outside.

johnsmm commented 7 months ago

Same issue here as well

C:\Users\Administrator\Desktop\hemtt>hemtt.exe new ofpscore
Example: Advanced Banana Environment
Project Name: ofpscore
Example: ABE Team
Author: ofps
Example: abe
Prefix: ofpscore
Main Prefix: z
Select a license: Unlicense
ERROR IO Error: The system cannot find the file specified. (os error 2)