-
Notifications
You must be signed in to change notification settings - Fork 27k
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
Production serverless build importing Firestore fails while including 'google/protobuf/api.proto' #11860
Comments
My understanding of this issue is that It looks like this has caused a variety of issues. What I don't understand is why it works in |
I can confirm that tweaking grpc by no longer requiring the |
Please remove ZEIT Now no longer uses the We created the new |
Awesome, thanks @Timer! I'd initially had Probably not a mainstream use case, but I'd cast my vote for adding |
@Timer P.S. is the fact that Zeit NOW is modifying |
That docs section captures it:
Maybe it's not clear that this means editing I'm not 100% sold on having users to enable
Also, to be exceptionally clear: custom servers and |
Oh, also: setting the serverless target locally used to be more important because serverless would disable your ability to use |
It is, and that's how I understood it to work back in I'd be fine with Right now, it seems like those docs are missing. https://zeit.co/docs/configuration#project/builds clearly shows that builders like But it's confusing that the Next.js build step preset claims to only effect the build command, output directory, and development command: But from what you've said, it also adjusts |
Thanks for this excellent feedback. We'll take it into account and rework the docs around this. Regarding your questions above, deployments to ZEIT Now still use our builders (via zero config). Meaning This is the code that forces the target: This is the code that wraps the build output for ZEIT Now: |
Awesome, y'all continue to be the best. |
I am also facing the same issue. The only difference is I am not using ZEIT Now for hosting and deployments. I use the serverless-next.js pkg since I need to deploy my NextJS project to AWS. So I can't remove the I am using the same version of NextJS and Firebase version as mentioned above. Thanks. |
@GuillaumeBecker unfortunately, this is a fundamental problem with typical serverless deployments (single file bundle) and ultimately why we moved away from the pattern for ZEIT Now. There's no easy solution, but you can try to get |
@Timer thx for the quick response. I will try to see with |
Correct, |
Just create a discussion about that here: Would be nice to have it on the docs |
This issue has been automatically locked due to no recent activity. If you are running into a similar issue, please create a new issue with the steps to reproduce. Thank you. |
Bug report
Describe the bug
When using
import "firebase/firestore"
on a page withtarget: "serverless"
innext.config.js
,next build
fails with the following error:To Reproduce
npm install
npm run build
Expected behavior
The production build should succeed. It used to work in
next@8.1.0
.System information
Additional context
target: "serverless"
fromnext.config.js
next build
succeeds in the Zeit NOW environment. I see NOW is also using Nodev12.15.0
, so scratching my head as to what's differentSeems like this is something that Next tried to get working in the past:
The text was updated successfully, but these errors were encountered: