fix: revert Suspense layout wrappers causing E2E hydration errors
Revert layout.tsx, _layout-creator.tsx, manage/layout.tsx, _theme.tsx, _creator.tsx, mantine.tsx, and login/page.tsx to origin/dev — the Suspense provider splits caused "EditMode is required", stream close, and React #419 errors. Also remove cacheComponents/cacheHandlers from next.config.ts (incompatible with auth/i18n/dynamic rendering) and fix Boolean() truthy bug in Redis connection.
This commit is contained in:
10 files changed
+221
-321
No files matched your search
@@ -4,11 +4,19 @@ import { createRedisClient } from "@homarr/core/infrastructure/redis";
|
||||
let dataClient: RedisClient | undefined;
|
||||
let subscriberClient: RedisClient | undefined;
|
||||
|
||||
const isRedisExplicitlyDisabled = () => process.env.CI === "true" || process.env.CI === "1" || process.env.DISABLE_REDIS_LOGS === "true" || process.env.DISABLE_REDIS_LOGS === "1";
|
||||
const isRedisExplicitlyDisabled = () =>
|
||||
process.env.CI === "true" ||
|
||||
process.env.CI === "1" ||
|
||||
process.env.DISABLE_REDIS_LOGS === "true" ||
|
||||
process.env.DISABLE_REDIS_LOGS === "1";
|
||||
|
||||
/**
|
||||
* In-process pub/sub fallback for single-instance deployments when Redis is unavailable.
|
||||
* Never used when REDIS_IS_EXTERNAL=true (multi-instance requires real Redis).
|
||||
* In-process pub/sub fallback for single-instance deployments, opted into via
|
||||
* CI/DISABLE_REDIS_LOGS. This is a static, env-driven switch — it does not detect
|
||||
* Redis unreachability at runtime; an unreachable Redis outside those flags still
|
||||
* attempts a real connection (with ioredis's default retry/backoff), it does not
|
||||
* fall back automatically. Never used when REDIS_IS_EXTERNAL=true (multi-instance
|
||||
* requires real Redis).
|
||||
*/
|
||||
export const usesMemoryFallback = (): boolean =>
|
||||
process.env.REDIS_IS_EXTERNAL !== "true" && isRedisExplicitlyDisabled();
|
||||
|
||||
Reference in new issue
Block a user