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

rerunning rsconnect_deploy deploys new API #96

Open
gsingh91 opened this issue Jul 24, 2022 · 3 comments
Open

rerunning rsconnect_deploy deploys new API #96

gsingh91 opened this issue Jul 24, 2022 · 3 comments

Comments

@gsingh91
Copy link
Contributor

Describe the bug
using rsconnect_deploy to redeploy an existing API on Connect, it deploys a new API. I did not specify the new argument either

To Reproduce
Use can use the jupyter notebook published here.

Expected behavior
Redeploying an existing API should overwrite the existing content.

@isabelizimm
Copy link
Contributor

Ah, the new argument has a default of "True," so you can choose to turn that off by setting it equal to False. If you think it is strongly expected to be False, I can either update it or remove the default altogether. 👍

@juliasilge
Copy link
Member

Is this the argument default?

new: bool = False,

Or am I missing something?

@isabelizimm
Copy link
Contributor

You are correct! I originally had thought there was something else going wrong. Upon further review, it looks like rsconnect.deploy_python_fastapi will think that every deployment is "new." When a model is sent to connect with deploy_rsconnect, it is deployed from a temporary directory where an app.py file is created from a pinned model. This temporary directory holds the manifest JSON file that would normally be used to determine if the deployment was "new" or not. An escape hatch out of this not-actually-new behavior that currently exists is to supply an app_id, which will force-overwrite the existing content.

I'll have to peek into rsconnect to see what validating newness looks like 👀

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

No branches or pull requests

3 participants