A New signup description with line breaks can pass the form, then be refused as too long
Los mantenedores suelen responder en 1 día
Evaluación
- Dificultad
- 2/5
- Tiempo estimado
- 1-3 horas
- Aptitud para principiantes
- 85/100
- Tipo de issue
- Error
- Claridad
- Bien especificado
- Estado de actividad
- Activo
- Stack tecnológico
- next.js, react, typescript
- Área
- full-stack
Línea de trabajo
Lee createSignupAction y SignupCreateInputSchema para ver el flujo de datos. Añade un helper junto a la acción que reemplace \r\n con \n en la descripción antes de createSignup, y fíjalo con una prueba unitaria. Ejecuta pnpm lint && pnpm typecheck && pnpm knip && pnpm test; hecho cuando una presentación de 1,996 letras y 4 saltos se guarda con saltos \n y todas las comprobaciones pasan.
Escrito por el modelo de indexación a partir del texto del issue.
Descripción
What happens
The description box on the New signup form (src/app/app/(chrome)/signups/new/page.tsx) has maxLength 2,000. The browser counts each line break as 1 character. When the form is sent, each line break becomes \r\n, which is 2 characters. createSignupAction passes the text on as it arrives, and SignupCreateInputSchema refuses anything over DESCRIPTION_MAX_LENGTH (2,000).
So a description near the limit with a few paragraph breaks passes in the browser, then the server refuses it with zod's own "String must contain at most 2000 character(s)". The form then comes back empty (#721).
Checked in Chromium: a textarea holding 1,996 letters and 4 line breaks reports a length of 2,000 and is valid. Sent with new FormData(form), the way a server action sends it, the server receives 2,004 characters with 4 \r\n.
Fix, in outline
- In
createSignupAction, turn\r\ninto\nin the description before callingcreateSignup. The browser and the server then count the same way. - Put that in a small helper next to the action, so a unit test can pin it.
Watch for
- The Build tab already saves
\n. It sends the textarea's value as JSON, so this makes both paths store the same thing. - Leave the schema alone. Don't change
DESCRIPTION_MAX_LENGTHorSignupCreateInputSchema. The API, the MCP tools and Magic Compose don't go through this form. - #721 changes the same action. Whichever lands second has a small merge.
Done when
- A description of 1,996 letters and 4 line breaks, sent as the browser sends it (
\r\n), creates the signup, and the saved description has 4\nbreaks. - A test pins that.
pnpm lint && pnpm typecheck && pnpm knip && pnpm testpass.
From the owner's review of #706. Checked against main at 2d4fdfe by reading createSignupAction and SignupCreateInputSchema, and in Chromium as above. Session: https://claude.ai/code/session_016YZ9SUMiUBccns5PMgoNS1
- Lenguaje dominante
- TypeScript
- Estrellas
- 19
- Forks
- 4
- Merge medio
- 22 h 45 min
- PR fusionados (30 d)
- 193
Preparar el entorno
- Incluye un Dockerfile o un archivo de Docker Compose
- Sin plantilla de pull request
- Leer la guía de contribución
Primeros pasos
- Lee el issue completo y luego la guía de contribución del proyecto.
- Comenta en el issue que vas a ocuparte — evita que dos personas hagan lo mismo.
- Haz un fork del repositorio y trabaja en una rama.
- Abre un pull request que haga referencia al número del issue.
Más de richshaw/OpenSignup
-
bug pipeline:ready pipeline:ux
Dificultad 1/5 Menos de una hora Aptitud para principiantes 85/100
richshaw/OpenSignup#749 ·
Los mantenedores suelen responder en 1 día
-
enhancement good first issue pipeline:ready
Dificultad 2/5 1-3 horas Aptitud para principiantes 75/100
richshaw/OpenSignup#742 ·
Los mantenedores suelen responder en 1 día
-
enhancement pipeline:proposed pipeline:ux
Dificultad 2/5 1-3 horas Aptitud para principiantes 72/100
richshaw/OpenSignup#654 ·
Los mantenedores suelen responder en 1 día
-
good first issue
Dificultad 2/5 1-3 horas Aptitud para principiantes 62/100
richshaw/OpenSignup#260 ·
Los mantenedores suelen responder en 1 día
-
Magic Compose's reading screen quotes the description in a blue box that no other screen usesAbiertoenhancement pipeline:ready pipeline:ux
Dificultad 3/5 1-2 días Aptitud para principiantes 75/100
richshaw/OpenSignup#751 · 1 comentario ·
Los mantenedores suelen responder en 1 día
Todos los issues de richshaw/OpenSignup
Issues similares
-
Dificultad 2/5 1-3 horas Aptitud para principiantes 75/100
code-yeongyu/senpi#5262 ·
Los mantenedores suelen responder en 1 día
-
community first-timers-only good first issue hacktoberfest help wanted low hanging fruit up-for-grabs
Dificultad 1/5 Menos de una hora Aptitud para principiantes 90/100
lingdojo/kana-dojo#33420 · 1 comentario · 5 reacciones ·
Los mantenedores suelen responder en 1 día
-
[BUG] inspect_schema matches named container case-insensitively without preferring exact matchPosiblemente ocupada @Maaz2212 la tomó hoy. Abiertobug
Dificultad 2/5 1-3 horas Aptitud para principiantes 88/100
libredb/libredb-studio#2128 · 1 comentario ·
Los mantenedores suelen responder en 1 día
-
Dificultad 2/5 1-3 horas Aptitud para principiantes 82/100
Yeachan-Heo/gajae-code#7474 · 1 comentario ·
Los mantenedores suelen responder en 1 día
-
status: needs triage
Dificultad 2/5 1-3 horas Aptitud para principiantes 85/100
mastra-ai/mastra#29108 · 1 comentario ·
Los mantenedores suelen responder en 1 día