Skip to content
This repository has been archived by the owner on Jan 11, 2023. It is now read-only.

Export failed with big data #714

Closed
arttemiuss43 opened this issue May 25, 2019 · 2 comments
Closed

Export failed with big data #714

arttemiuss43 opened this issue May 25, 2019 · 2 comments

Comments

@arttemiuss43
Copy link

When I export site with more than ~650 pages I have the following error:

UnhandledPromiseRejectionWarning: Error: Timed out waiting for http://localhost:3000/blog/title-656

After about 40 such errors command fails with exit code 1.

Is Sapper able to export a big site?

@bwbroersma
Copy link
Contributor

bwbroersma commented Jun 3, 2019

After some issues #604 (#641 #690 #698) stuff should work.

I've a project Allmanak with Sapper 0.27.1 which daily builds 22.000+ pages and does some post processing plus some nginx mapping and redirecting based on fixed identifiers.
So https://www.allmanak.nl/1/Old_name will redirect to https://www.allmanak.nl/1/Algemene_Rekenkamer/ which wouldn't be possible with just directories.

Depending on your backend, you can tweak:
--concurrent (default 8) and
--timeout (default 5000 ms)

sapper/src/cli.ts

Lines 193 to 198 in d7e2662

prog.command('export [dest]')
.describe('Export your app as static files (if possible)')
.option('--build', '(Re)build app before exporting', true)
.option('--basepath', 'Specify a base path')
.option('--concurrent', 'Concurrent requests', 8)
.option('--timeout', 'Milliseconds to wait for a page (--no-timeout to disable)', 5000)

@Conduitry
Copy link
Member

As noted, there have been a number of recent fixes in this area. Please re-open if you are still having problems with the latest version.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants