Skip to content

Unable to get @sveltejs/adapter-auto to detect Deno #14371

@JosefSaltz

Description

@JosefSaltz

Describe the bug

I'm running Deno 2.4.5 for my project that has a deno.lock file present. I have @sveltejs/adapter-auto dependency pinned to ^6.1.0 as per the latest release notes to utilize #14163. Running vite build related tasks yields: Could not detect a supported production environment. See https://svelte.dev/docs/kit/adapters to learn how to configure your app to run on the platform of your choosing

Reproduction

  1. Create a new directory for a svelte kit project
  2. Run deno run npm:sv create
  3. Allow required permissions
  4. Sveltekit minimal option
  5. Yes, using Typescript syntax option
  6. Allow required permissions
  7. Add nothing to project
  8. Run deno outdated -ui to update all dependencies to latest (ensure we use 6.1.0)
  9. Ensure a deno.lock file is present
  10. deno task build should yield:

Using @sveltejs/adapter-auto
Could not detect a supported production environment. See https://svelte.dev/docs/kit/adapters to learn how to configure your app to run on the platform of your choosing

Logs

josef@jSysD  ~/projects/reproduction-deno  deno task build
Task build vite build
▲ [WARNING] Cannot find base config file "./.svelte-kit/tsconfig.json" [tsconfig.json]

    tsconfig.json:2:12:
      2 │   "extends": "./.svelte-kit/tsconfig.json",
        ╵              ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

vite v7.1.4 building SSR bundle for production...
✓ 190 modules transformed.
vite v7.1.4 building for production...
✓ 143 modules transformed.
.svelte-kit/output/client/_app/version.json                        0.03 kB │ gzip:  0.05 kB
.svelte-kit/output/client/.vite/manifest.json                      2.74 kB │ gzip:  0.55 kB
.svelte-kit/output/client/_app/immutable/chunks/B_zhfS5Q.js        0.03 kB │ gzip:  0.05 kB
.svelte-kit/output/client/_app/immutable/chunks/DsnmJJEf.js        0.07 kB │ gzip:  0.08 kB
.svelte-kit/output/client/_app/immutable/entry/start.iLCRZqQB.js   0.08 kB │ gzip:  0.09 kB
.svelte-kit/output/client/_app/immutable/nodes/2.Bc5uTrdH.js       0.32 kB │ gzip:  0.24 kB
.svelte-kit/output/client/_app/immutable/chunks/CqHW6ZLX.js        0.74 kB │ gzip:  0.47 kB
.svelte-kit/output/client/_app/immutable/nodes/1.Biv2SF0f.js       1.01 kB │ gzip:  0.59 kB
.svelte-kit/output/client/_app/immutable/nodes/0.B-sTQ74C.js       2.73 kB │ gzip:  1.19 kB
.svelte-kit/output/client/_app/immutable/chunks/j99YIqQk.js        3.78 kB │ gzip:  2.01 kB
.svelte-kit/output/client/_app/immutable/entry/app.D14PAJbh.js     7.30 kB │ gzip:  3.47 kB
.svelte-kit/output/client/_app/immutable/chunks/DNHTCZ5S.js       20.35 kB │ gzip:  8.19 kB
.svelte-kit/output/client/_app/immutable/chunks/BSTMg8TK.js       31.91 kB │ gzip: 12.62 kB
✓ built in 249ms
.svelte-kit/output/server/.vite/manifest.json                  2.96 kB
.svelte-kit/output/server/chunks/false.js                      0.05 kB
.svelte-kit/output/server/entries/pages/_page.svelte.js        0.22 kB
.svelte-kit/output/server/internal.js                          0.33 kB
.svelte-kit/output/server/chunks/escaping.js                   0.53 kB
.svelte-kit/output/server/chunks/environment.js                0.58 kB
.svelte-kit/output/server/chunks/utils.js                      1.15 kB
.svelte-kit/output/server/chunks/equality.js                   1.23 kB
.svelte-kit/output/server/entries/fallbacks/error.svelte.js    1.34 kB
.svelte-kit/output/server/entries/pages/_layout.svelte.js      2.88 kB
.svelte-kit/output/server/chunks/index.js                      5.15 kB
.svelte-kit/output/server/chunks/exports.js                    6.87 kB
.svelte-kit/output/server/remote-entry.js                     11.33 kB
.svelte-kit/output/server/chunks/shared.js                    16.46 kB
.svelte-kit/output/server/chunks/internal.js                  59.29 kB
.svelte-kit/output/server/index.js                           140.63 kB
✓ built in 946ms

Run npm run preview to preview your production build locally.

> Using @sveltejs/adapter-auto
  Could not detect a supported production environment. See https://svelte.dev/docs/kit/adapters to learn how to configure your app to run on the platform of your choosing
  ✔ done

System Info

FWIW this is WSL2 running on Windows 11 Pro  

System:
    OS: Linux 5.15 Ubuntu 24.04.3 LTS 24.04.3 LTS (Noble Numbat)
    CPU: (32) x64 13th Gen Intel(R) Core(TM) i9-13900K
    Memory: 4.36 GB / 15.62 GB
    Container: Yes
    Shell: 5.9 - /usr/bin/zsh
  Binaries:
    Node: 22.18.0 - ~/.nvm/versions/node/v22.18.0/bin/node
    npm: 10.9.3 - ~/.nvm/versions/node/v22.18.0/bin/npm
    pnpm: 10.14.0 - ~/.local/share/pnpm/pnpm
  npmPackages:
    @sveltejs/adapter-auto: ^6.1.0 => 6.1.0
    @sveltejs/kit: ^2.37.0 => 2.37.0
    @sveltejs/vite-plugin-svelte: ^6.1.4 => 6.1.4
    svelte: ^5.38.6 => 5.38.6
    vite: ^7.1.4 => 7.1.4

Severity

serious, but I can work around it

Additional Information

Trying to debug the get_adapter function in the package but can't get my console.log() calls to show in the runtime log even when running Vite with the debug log -d option. I can look further into this if there's any advice so I can see my logs.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions