mirror of
https://github.com/shumaiOne/shumai.git
synced 2026-11-26 02:38:23 +00:00
fix(webui): strip styles and preserve multiline text on paste in chat input (#371)
* fix(webui): strip styles and preserve multiline text on paste in chat input * fix(db): remove custom log wait strategy in test global setup to prevent postgres startup race condition
This commit is contained in:
@@ -1,7 +1,6 @@
|
||||
import { PostgreSqlContainer } from '@testcontainers/postgresql'
|
||||
import { exec } from 'node:child_process'
|
||||
import { promisify } from 'node:util'
|
||||
import { Wait } from 'testcontainers'
|
||||
|
||||
const execAsync = promisify(exec)
|
||||
|
||||
@@ -9,13 +8,7 @@ let dbContainer: import('@testcontainers/postgresql').StartedPostgreSqlContainer
|
||||
|
||||
export async function globalTestSetup() {
|
||||
console.log('Starting Testcontainers for global setup...')
|
||||
dbContainer = await new PostgreSqlContainer('pgvector/pgvector:pg18')
|
||||
.withWaitStrategy(
|
||||
// casting to any due to testcontainers wait strategy type mismatch
|
||||
// eslint-disable-next-line @typescript-eslint/no-explicit-any
|
||||
Wait.forLogMessage('database system is ready to accept connections', 1) as any,
|
||||
)
|
||||
.start()
|
||||
dbContainer = await new PostgreSqlContainer('pgvector/pgvector:pg18').start()
|
||||
|
||||
const databaseUrl = dbContainer.getConnectionUri()
|
||||
console.log('Database started at:', databaseUrl)
|
||||
|
||||
Reference in New Issue
Block a user