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

Fix 'Missing required attribute "expire"' on users.createSession() #8308

Merged
merged 2 commits into from
Jun 25, 2024

Conversation

stnguyen90
Copy link
Contributor

@stnguyen90 stnguyen90 commented Jun 21, 2024

What does this PR do?

Fix expire error when creating user session

Before this, the Create session API call would throw:

Invalid document structure: Missing required attribute "expire"

This is because the expire attribute is required, but it was omitted
from the document. This PR ensures the expire attribute is set when
creating the session document.

Fixes #8280

Update session secret to be longer

The create session endpoint created a 6 character secret which is too
short. This changes the secret to be 256 characters which is in line
with the secret for account.createEmailPasswordSession().

Test Plan

Added a test case

Related PRs and Issues

Parent PR:

Checklist

  • Have you read the Contributing Guidelines on issues?
  • If the PR includes a change to an API's metadata (desc, label, params, etc.), does it also include updated API specs and example docs?

Before this, the Create session API call would throw:

> Invalid document structure: Missing required attribute "expire"

This is because the `expire` attribute is required, but it was omitted
from the document. This PR ensures the `expire` attribute is set when
creating the session document.
The create session endpoint created a 6 character secret which is too
short. This changes the secret to be 256 characters which is in line
with the secret for `account.createEmailPasswordSession()`.
@stnguyen90 stnguyen90 force-pushed the fix-8280-expire-error-when-creating-session branch from 7a68034 to 13027fa Compare June 24, 2024 23:21
@stnguyen90 stnguyen90 changed the base branch from 1.5.x to fix-flaky-function-test June 24, 2024 23:37
@stnguyen90 stnguyen90 marked this pull request as ready for review June 24, 2024 23:41
Base automatically changed from fix-flaky-function-test to 1.5.x June 25, 2024 01:35
@abnegate abnegate merged commit 4ad987e into 1.5.x Jun 25, 2024
23 checks passed
@abnegate abnegate deleted the fix-8280-expire-error-when-creating-session branch June 25, 2024 01:43
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.

🐛 Bug Report: Invalid document structure: Missing required attribute "expire" on users.createSession()
3 participants