File tree Expand file tree Collapse file tree 1 file changed +11
-2
lines changed Expand file tree Collapse file tree 1 file changed +11
-2
lines changed Original file line number Diff line number Diff line change @@ -42,7 +42,11 @@ impl DenoCompileCodeCache {
42
42
// attempt to deserialize the cache data
43
43
match deserialize ( & file_path, cache_key) {
44
44
Ok ( data) => {
45
- log:: debug!( "Loaded {} code cache entries" , data. len( ) ) ;
45
+ log:: debug!(
46
+ "Loaded {} code cache entries from {}" ,
47
+ data. len( ) ,
48
+ file_path. display( )
49
+ ) ;
46
50
Self {
47
51
strategy : CodeCacheStrategy :: SubsequentRun (
48
52
SubsequentRunCodeCacheStrategy {
@@ -53,7 +57,11 @@ impl DenoCompileCodeCache {
53
57
}
54
58
}
55
59
Err ( err) => {
56
- log:: debug!( "Failed to deserialize code cache: {:#}" , err) ;
60
+ log:: debug!(
61
+ "Failed to deserialize code cache from {}: {:#}" ,
62
+ file_path. display( ) ,
63
+ err
64
+ ) ;
57
65
Self {
58
66
strategy : CodeCacheStrategy :: FirstRun ( FirstRunCodeCacheStrategy {
59
67
cache_key,
@@ -186,6 +194,7 @@ impl FirstRunCodeCacheStrategy {
186
194
Ok ( ( ) ) => {
187
195
if let Err ( err) = std:: fs:: rename ( & temp_file, & self . file_path ) {
188
196
log:: debug!( "Failed to rename code cache: {}" , err) ;
197
+ let _ = std:: fs:: remove_file ( & temp_file) ;
189
198
} else {
190
199
log:: debug!( "Serialized {} code cache entries" , count) ;
191
200
}
You can’t perform that action at this time.
0 commit comments