Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Self hosted vercel instance gives maxDuration warning #1416

Closed
1 task done
rickstaa opened this issue Oct 24, 2021 · 12 comments · Fixed by #1418
Closed
1 task done

Self hosted vercel instance gives maxDuration warning #1416

rickstaa opened this issue Oct 24, 2021 · 12 comments · Fixed by #1418

Comments

@rickstaa
Copy link
Collaborator

rickstaa commented Oct 24, 2021

Describe the bug

When I try to deploy the master branch on my self-hosted vercel instance (i.e. https://github.com/anuraghazra/github-readme-stats#deploy-on-your-own-vercel-instance) I get the following error:

The value for maxDuration must be between 1 second and 10 seconds, in order to increase this limit upgrade your plan: https://vercel.com/pricing

I did some debugging and this error has been present since 81b6593.

Expected behaviour

This error should not be present.

TODO

  • We should document why this is happening.
@anuraghazra
Copy link
Owner

Open the vercel.json file and change the maxDuration to 10.

It's not a bug, it was intentionally reduced to 30s because by default on PRO plan it sets to 1min which is too high and was causing too much memory usage. but for non-pro users the duration can only be <10s thus 30s fails.

@anuraghazra
Copy link
Owner

There were two other users having the same confusion around this issue.

Maybe we should document that, after forking the repo for self-hosting they should change the duration to 10

@rickstaa
Copy link
Collaborator Author

@anuraghazra I think that is a good idea. I reopened the issue. Can you like the related issues?

@rickstaa rickstaa reopened this Oct 24, 2021
@anuraghazra
Copy link
Owner

#1383
#1393

@rickstaa
Copy link
Collaborator Author

@anuraghazra Do you want me to update the documentation or are you doing it yourself? In the meantime allow me to create a commit that people can cherry-pick. I think it is nice to add this to the documentation.

rickstaa added a commit to rickstaa/github-readme-stats that referenced this issue Oct 24, 2021
This commit decreases the vercel 'maxDuration' parameter to `10` such
that users with the free vercel plan can also deploy the
'github-readme-stats' repository. See anuraghazra#1416 for more information.
@rickstaa
Copy link
Collaborator Author

People can cherry-pick 8af4544 to fix this issue.

@rickstaa
Copy link
Collaborator Author

@anuraghazra Ah, maybe you can create this commit on a new branch then remove the branch. In the current form, people have to use my fork. If that is too much work we can just document the behaviour.

@anuraghazra
Copy link
Owner

@anuraghazra Ah, maybe you can create this commit on a new branch then remove the branch. In the current form, people have to use my fork. If that is too much work we can just document the behaviour.

No there's no need to use your fork, it will create a two level dependency (on my fork -> your fork -> user's fork). We can just document the behaviour and also improve the error msg to exactly say what users have to do to fix the issue.

@anuraghazra
Copy link
Owner

The value for maxDuration must be between

@rickstaa does the error msg shows up on the rendered card itself or in a custom vercel error page?

@rickstaa
Copy link
Collaborator Author

rickstaa commented Oct 25, 2021

@anuraghazra There were two places where the error showed up. In the vercel deployment log and as a GitHub notification since I use the github vercel app. The card itself is not displayed since the deployment fails. I temporarily broke my fork again to show the behaviour:

image

You can view this here.

@anuraghazra
Copy link
Owner

Oh yeah then we cannot show a custom msg, I thought the error was shown in the rendered card itself that way we could parse and replace the string. but not with this then.

I've added docs only.

@rickstaa
Copy link
Collaborator Author

rickstaa commented Oct 25, 2021

@anuraghazra Thanks for your pull request! I think it is clear now.

jedediahfanuel added a commit to jedediahfanuel/github-readme-stats that referenced this issue Jan 6, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants