Skip to content

SyntaxError: Unexpected token T in JSON at position 0 WHile building the website #47554

@AnasAitzouinet

Description

@AnasAitzouinet

Verify canary release

  • I verified that the issue exists in the latest Next.js canary release

Provide environment information

Hi , im trying to build my website and i get this error, i tried a lot of thing but nothing were helpful :

Which area(s) of Next.js are affected? (leave empty if unsure)

No response

Link to the code that reproduces this issue

https://github.com/AnasAitzouinet/my-eco

To Reproduce

info - Collecting page data .SyntaxError: Unexpected token T in JSON at position 0
at JSON.parse ()
at parseJSONFromBytes (node:internal/deps/undici/undici:6498:19)
at successSteps (node:internal/deps/undici/undici:6472:27)
at node:internal/deps/undici/undici:1145:60
at node:internal/process/task_queues:140:7
at AsyncResource.runInAsyncScope (node:async_hooks:204:9)
at AsyncResource.runMicrotask (node:internal/process/task_queues:137:8)
at process.processTicksAndRejections (node:internal/process/task_queues:95:5)

Build error occurred
Error: Failed to collect page data for /Product/[id]
at C:\Users\anasa\OneDrive\Documents\Git\Garboz\my-eco\node_modules\next\dist\build\utils.js:1055:15
at process.processTicksAndRejections (node:internal/process/task_queues:95:5) {
type: 'Error'

Describe the Bug

im just tryin the website by next build and i get this error even thought i did alot of fixes but nothing worked

Expected Behavior

trying to build it

Which browser are you using? (if relevant)

No response

How are you deploying your application? (if relevant)

No response

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions