mirror of
https://github.com/danny-avila/LibreChat.git
synced 2026-11-17 13:33:45 +00:00
* fix: invalidate the auth user cache after a CLI password reset
The reset CLI wrote the new password and credentialsChangedAt with
User.updateOne, which bypasses the auth user document cache
invalidation the data-schemas user methods perform. With
AUTH_USER_CACHE_MODE=on a cached document without the new stamp could
keep pre-reset access tokens verifying for up to the cache TTL after
the reset. Route the write through updateUser with the shared cache
factory, the same wiring config/delete-user.js uses, so the cached
entries for the user are deleted as part of the reset.
* test: cover CLI password reset token revocation in the mock harness
* test: verify CLI reset evicts the shared Redis auth cache
* fix: preserve pending account expiry during CLI resets
* test: assert pending account verification after CLI reset
(cherry picked from commit 6f903fc9e5)
Original-PR: https://github.com/LibreChat-AI/LibreChat/pull/16257
31 lines
1.2 KiB
TypeScript
31 lines
1.2 KiB
TypeScript
import { defineConfig } from '@playwright/test';
|
|
import mockConfig from './playwright.config.mock';
|
|
|
|
/** Scenarios that exercise Redis-backed streams or shared cache invalidation. */
|
|
export default defineConfig({
|
|
...mockConfig,
|
|
/**
|
|
* Every stream event crosses a real Redis round-trip on this lane, so waits that
|
|
* sit comfortably against the in-memory store run much closer to their budget —
|
|
* pause/resume and rehydrate paths most of all, since they replay a whole job.
|
|
* The suite is serial (`workers: 1`), so this is per-operation latency rather
|
|
* than contention, and it is why this lane reports flaky runs the memory shards
|
|
* never produce. Give it a larger default assertion budget and one more retry.
|
|
*/
|
|
retries: process.env.CI ? 3 : 0,
|
|
expect: { ...mockConfig.expect, timeout: 20_000 },
|
|
testMatch: [
|
|
/completion\.spec\.ts/,
|
|
/deferred-tools-hitl\.spec\.ts/,
|
|
/model-spec-icons\.spec\.ts/,
|
|
/steering\.spec\.ts/,
|
|
/steering-escalation\.spec\.ts/,
|
|
/streaming\.spec\.ts/,
|
|
/subagent-activity\.spec\.ts/,
|
|
/thread-fold\.spec\.ts/,
|
|
/tool-approvals\.spec\.ts/,
|
|
/usage\.spec\.ts/,
|
|
/scenarios\/redis-stream\.spec\.ts/,
|
|
/scenarios\/reset-password\.spec\.ts/,
|
|
],
|
|
});
|