79427925

Date: 2025-02-10 18:07:42
Score: 2
Natty:
Report link

You can't use .set() on a collection reference, only on a document reference. You could use .add(), this also automatically generates an ID for the document. Source: StackOverflow

The 504 error you're getting would suggest that your request to Firestore timed out. This could be due to several reasons. If the test document is large it could be too much data, although since you seem to only upload one file I doubt that's the case, but there's some info about it here.

Since you say you've updated the firebase service account roles I assume you've checked the permission, if not, try that. Otherwise it may be a connection issue, make sure your network is stable. You could also try to add some retries.

This issue was also posted on GitHub, although here they do mention MacOS.

If none of this helps I'd find out at which line in your try statement the error is thrown.

Reasons:
  • Blacklisted phrase (1): StackOverflow
  • Long answer (-0.5):
  • No code block (0.5):
  • Low reputation (1):
Posted by: Jesper