File tree Expand file tree Collapse file tree 2 files changed +10
-1
lines changed Expand file tree Collapse file tree 2 files changed +10
-1
lines changed Original file line number Diff line number Diff line change 12
12
13
13
## master
14
14
15
+ #### :bug : Bug fix
16
+
17
+ - Protect against trying to read non-existant ` .compiler.log ` . https://github.com/rescript-lang/rescript-vscode/pull/1116
18
+
15
19
## 1.64.0
16
20
17
21
#### :rocket : New Feature
Original file line number Diff line number Diff line change @@ -99,7 +99,12 @@ let sendUpdatedDiagnostics = async () => {
99
99
for ( const [ projectRootPath , projectFile ] of projectsFiles ) {
100
100
let { filesWithDiagnostics } = projectFile ;
101
101
let compilerLogPath = path . join ( projectRootPath , c . compilerLogPartialPath ) ;
102
- let content = fs . readFileSync ( compilerLogPath , { encoding : "utf-8" } ) ;
102
+ let content = "" ;
103
+ try {
104
+ content = fs . readFileSync ( compilerLogPath , { encoding : "utf-8" } ) ;
105
+ } catch ( e ) {
106
+ console . error ( `Error reading compiler log file ${ compilerLogPath } : ${ e } ` ) ;
107
+ }
103
108
let {
104
109
done,
105
110
result : filesAndErrors ,
You can’t perform that action at this time.
0 commit comments