You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Describe the bug
On CLI 1.123.3 (at least), deploying functions fails. Reverting back to 1.119.1 works. We have not tried intermediary versions.
To Reproduce
Steps to reproduce the behavior:
Run supabase functions deploy my_function --project-ref $PROJECT
Get error:
Error: failed to load 'file:///home/deno/modules/3ca66d1b34d0b8876071c82bf7b01713844dc25fc70c7bc0de4faefd13fe8919': Expected a JavaScript or TypeScript module, but identified a Unknown module. Importing these types of modules is currently not supported.
Specifier: file:///home/deno/modules/3ca66d1b34d0b8876071c82bf7b01713844dc25fc70c7bc0de4faefd13fe8919
@bombillazo What's the file structure in your supabase/functions directory? Is there a file by the name3ca66d1b34d0b8876071c82bf7b01713844dc25fc70c7bc0de4faefd13fe8919?
Activity
laktek commentedon Dec 12, 2023
@bombillazo What's the file structure in your
supabase/functionsdirectory? Is there a file by the name3ca66d1b34d0b8876071c82bf7b01713844dc25fc70c7bc0de4faefd13fe8919?sweatybridge commentedon Dec 12, 2023
It's probably a problem with the way we resolve import maps for absolute file paths. Here's a reproducible example:
Given the following
import_map.jsonImporting
shared/index.tsworks but notshared_abs. We can probably fix it by adding the original file extension to the resolved path.