Skip to content

Commit 47d4b65

Browse files
committed
fix: Use from_file_path instead of from_directory_path for element JSON files
This fixes a Windows path handling issue where element JSON files were not being found correctly. The bug was caused by using Url::from_directory_path for file paths instead of Url::from_file_path. Fixes #1 - Windows CI test failures
1 parent 678b962 commit 47d4b65

File tree

2 files changed

+2
-4
lines changed

2 files changed

+2
-4
lines changed

.github/workflows/ci.yml

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -46,6 +46,4 @@ jobs:
4646
uses: actions/upload-artifact@v4
4747
with:
4848
name: dist-${{ matrix.os }}
49-
path: |
50-
dist/index-${{ matrix.os }}.node
51-
dist/index-${{ matrix.os }}.d.ts
49+
path: dist

src/resource_group.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -80,7 +80,7 @@ impl ResourceGroup {
8080
continue;
8181
}
8282

83-
let file_uri = match Url::from_directory_path(entry.path().to_string_lossy().to_string()) {
83+
let file_uri = match Url::from_file_path(entry.path()) {
8484
Ok(url) => url,
8585
Err(_) => continue,
8686
};

0 commit comments

Comments
 (0)