Skip to content

fix(cli): prevent session cookie from being wiped #1074

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

Merged
merged 1 commit into from
May 13, 2025

Conversation

stnguyen90
Copy link
Contributor

What does this PR do?

Prior to this change, the CLI would replace the cookies in the config if the server returned any cookies, even when not authenticating.

This change makes it so we check for the Appwrite session cookie and only save that cookie if it's found in the response.

Test Plan

This was happening when I was using the CLI against a codespaces instance I had. So, I manually tweaked the code and then successfully connected to the codespace without losing the session:

image

Related PRs and Issues

None

Have you read the Contributing Guidelines on issues?

Yes

Prior to this change, the CLI would replace the cookies in the config if the server returned any cookies, even when not authenticating.

This change makes it so we check for the Appwrite session cookie and only save that cookie if it's found in the response.
@stnguyen90 stnguyen90 merged commit 30c86f5 into master May 13, 2025
37 checks passed
@stnguyen90 stnguyen90 deleted the fix-cli-prevent-session-cookie-wipe branch May 13, 2025 22:47
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 this pull request may close these issues.

2 participants