Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

incorrect path with "patch" when using absolute paths #28763

Open
sigmaSd opened this issue Apr 5, 2025 · 0 comments
Open

incorrect path with "patch" when using absolute paths #28763

sigmaSd opened this issue Apr 5, 2025 · 0 comments
Labels
patch Deno patch feature

Comments

@sigmaSd
Copy link
Contributor

sigmaSd commented Apr 5, 2025

Version: Deno 2.2.6 linux

to reproduce:

  • mkdir patchbug && cd patchbug
  • mkdir a && mkdir b
  • cd a
  • a/deno.json
{
  "name": "@sigmasd/a",
  "exports": "./mod.ts"
}
  • a/mod.ts
export function a() {}
  • cd ../b
  • b/deno.json
{
  "patch": [
    "/home/mrcool/dev/deno/lab/patchbug/a"
  ]
}
  • b/mod.ts
import { a } from "jsr:@sigmasd/a";
  • deno mod.ts # inside b

errors with:

error: Module not found "file:///home/mrcool/dev/deno/lab/patchbug/mod.ts".
    at file:///home/mrcool/dev/deno/lab/patchbug/b/mod.ts:1:19

If I change the absolute path in "patch" to a relative one it works correctly.

@marvinhagemeister marvinhagemeister added the patch Deno patch feature label Apr 5, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
patch Deno patch feature
Projects
None yet
Development

No branches or pull requests

2 participants