Record-search pagination tip recommends --offset even when --json rejects it

Abierto Apto para principiantes
#2,940 0 comentarios 0 reacciones 0 asignados Ver en GitHub

Los mantenedores suelen responder en 1 día

Nadie ha tomado este issue todavía.

Evaluación

Dificultad
2/5
Tiempo estimado
1-3 horas
Aptitud para principiantes
75/100
Tipo de issue
Error
Claridad
Bien especificado
Estado de actividad
Activo
Stack tecnológico
go
Área
cli

Línea de trabajo

Lee shortcuts/base/record_export.go en torno al consejo compartido sobre la paginación y luego revisa shortcuts/base/record_query.go en torno a la validación de JSON y de la paginación. Armoniza las instrucciones para continuar en el modo de flags y en el modo de cuerpo JSON; el trabajo estará terminado cuando el consejo indique a quienes usan JSON que incluyan el siguiente offset en el cuerpo de la solicitud y deje de sugerir un flag --offset contradictorio.

Escrito por el modelo de indexación a partir del texto del issue.

Descripción

bug

Hullo folks,

I'm doing some research for Tessl Code Review and we ran it against your repo. It flagged a potential issue, and I figured it made sense to share it with you:

The shared record-analysis tip tells callers to continue with --offset set to next_offset when has_more is true. +record-search includes this tip, including when the request uses --json.

For example, a caller starts with:

lark-cli base +record-search --base-token <base> --table-id <table> \
  --json '{"keyword":"Alice","search_fields":["Name"],"limit":2}'

If the response has more results, following the tip by adding --offset 2 conflicts with --json. The validator rejects explicitly supplied pagination flags; offset is in that exclusive set.

Expected: distinguish flag-mode continuation from JSON-body continuation. For the latter, put "offset":2 inside the JSON body. The validation hint already explains this, but the earlier pagination instruction sends the caller into the error.

This is a help-text/validation inconsistency established from current source, not a live Lark API test. Checked commit: c5fbf1a52df77d5cb9cac2b1501770b2fb9af7d2.

Full transparency: I work at Tessl, and we've spotted that using Tessl Code Review - using repository-level context and specific review lenses that improve over time through feedback. That’s how this finding surfaced.

We’re just getting started and want to offer the tool free to open-source projects. If this is useful, happy to give you access.

Baptiste

Lenguaje dominante
Go
Estrellas
18.2k
Forks
1.4k
Merge medio
20 h 34 min
PR fusionados (30 d)
17

Preparar el entorno

  • Sin Dockerfile ni archivo de Docker Compose
  • Tiene una plantilla de pull request
  • Sin guía de contribución

Primeros pasos

  1. Lee el issue completo y luego la guía de contribución del proyecto.
  2. Comenta en el issue que vas a ocuparte — evita que dos personas hagan lo mismo.
  3. Haz un fork del repositorio y trabaja en una rama.
  4. Abre un pull request que haga referencia al número del issue.

Más de larksuite/cli

Todos los issues de larksuite/cli

Issues similares

Más issues de Go

Recibe los nuevos issues en tu correo

Un resumen breve de issues de GitHub para principiantes.