leptonai / search_with_lepton

Building a quick conversation-based search demo with Lepton AI.
https://search.lepton.run
Apache License 2.0
7.86k stars 1.01k forks source link

it occur wrong when use npm run build, show useSearchParams() should be wrapped in a suspense boundary at page "/search" #78

Open BarryYin opened 6 months ago

BarryYin commented 6 months ago

info - Need to disable some ESLint rules? Learn more here: https://nextjs.org/docs/basic-features/eslint#disabling-rules ✓ Linting and checking validity of types
✓ Collecting page data
Generating static pages (6/7) [= ] ⨯ useSearchParams() should be wrapped in a suspense boundary at page "/search". Read more: https://nextjs.org/docs/messages/missing-suspense-with-csr-bailout at o (/Users/mac/Documents/GitHub/search_with_lepton/web/.next/server/chunks/347.js:1:10715) at s (/Users/mac/Documents/GitHub/search_with_lepton/web/.next/server/chunks/347.js:1:21665) at lm (/Users/mac/Documents/GitHub/search_with_lepton/web/.next/server/app/search/page.js:16:922) at nj (/Users/mac/Documents/GitHub/search_with_lepton/web/node_modules/next/dist/compiled/next-server/app-page.runtime.prod.js:12:46251) at nM (/Users/mac/Documents/GitHub/search_with_lepton/web/node_modules/next/dist/compiled/next-server/app-page.runtime.prod.js:12:47571) at nN (/Users/mac/Documents/GitHub/search_with_lepton/web/node_modules/next/dist/compiled/next-server/app-page.runtime.prod.js:12:64546) at nI (/Users/mac/Documents/GitHub/search_with_lepton/web/node_modules/next/dist/compiled/next-server/app-page.runtime.prod.js:12:47010) at nM (/Users/mac/Documents/GitHub/search_with_lepton/web/node_modules/next/dist/compiled/next-server/app-page.runtime.prod.js:12:47717) at nM (/Users/mac/Documents/GitHub/search_with_lepton/web/node_modules/next/dist/compiled/next-server/app-page.runtime.prod.js:12:61546) at nN (/Users/mac/Documents/GitHub/search_with_lepton/web/node_modules/next/dist/compiled/next-server/app-page.runtime.prod.js:12:64546)

Error occurred prerendering page "/search". Read more: https://nextjs.org/docs/messages/prerender-error

✓ Generating static pages (7/7)

Export encountered errors on following paths: /search/page: /search

comi-zhang commented 3 weeks ago

I meet the same error,what is the reason?

comi-zhang commented 3 weeks ago

Have you solved the problem,I am curious about the your method