-
Notifications
You must be signed in to change notification settings - Fork 202
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
Fix schedule function deployment #1305
Fix schedule function deployment #1305
Conversation
colerogers
commented
Nov 8, 2022
•
edited
Loading
edited
- Fixes schedule function deployment by always returning a retryConfig from init schedule trigger
- Fixes a bug in task queues where some properties of retryConfig and rateLimits were not resettable if the user supplied any options
- Fixes a bug in testLab where the reset-able endpoint options weren't being added in
src/v1/function-builder.ts
Outdated
@@ -274,7 +274,7 @@ export function region( | |||
* | |||
* Value must not be null. | |||
*/ | |||
export function runWith(runtimeOptions: RuntimeOptions): FunctionBuilder { | |||
export function runWith(runtimeOptions: DeploymentOptions): FunctionBuilder { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
hmm this would mean things like region
would also be suggested in runWith
which shouldn't be.
I wonder I made the mistake of setting preserveExternalChanges
Deployment Option instead of Runtime Option. It doesn't sound right that preserveExternalChanges
is a runtime option, but then that's the only way I can abuse runWith
tag 😢
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Hmm yeah I figured this was a bug since I couldn't figure out a way to use preserveExternalChanges
without making this change. Also, the v1 docs show preserveExternalChanges
in the runtime options section - https://firebase.google.com/docs/functions/manage-functions#set_runtime_options
Should we just dump preserveExternalChanges
into RuntimeOptions
instead? That way we wouldn't have to fix any docs, but might not be the cleanest looking...
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
let's dump it in RuntimeOptions. I think runWith is already a dumping of options.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
lgtm - would consider moving the preserveExternalChanges option to runtime options instead.