- Wrap fileHandle.close() in try-catch to prevent masking original errors
- Log close errors without throwing to preserve error context
Co-authored-by: whyour <22700758+whyour@users.noreply.github.com>
- Use finally block to ensure file handle is closed even on error
- Extract error messages properly using instanceof Error check
- Improve error message formatting for better debugging
Co-authored-by: whyour <22700758+whyour@users.noreply.github.com>
- Configure HTTP server timeouts (requestTimeout: 5min, headersTimeout: 2min, keepAliveTimeout: 65s)
- Add better error logging in PUT /scripts endpoint
- Improve writeFileWithLock error handling with descriptive messages and proper cleanup
- Ensure lock is always released even on error
Co-authored-by: whyour <22700758+whyour@users.noreply.github.com>