Minor cleanups

Abierto
#28 0 comentarios 0 reacciones 0 asignados Ver en GitHub

Nadie ha tomado este issue todavía.

Evaluación

Dificultad
3/5
Tiempo estimado
1-2 días
Aptitud para principiantes
67/100
Tipo de issue
Error
Claridad
Bien especificado
Estado de actividad
Activo
Stack tecnológico
go
Área
backend

Línea de trabajo

Start with converter.go, tt_test.go:405, and converter_test.go:30; compare each listed issue with the surrounding code and tests. Then review the README and CHANGELOG v1.1.0 entries, and check the exported StringToTTConvFactory methods. Done means each listed cleanup is addressed, including the documentation inconsistencies and test assertion/name issues.

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

Descripción

code health

Reproduction snippets assume:

fac := tupleconv.MakeStringToTTConvFactory()
  • StringToBinaryConverter is missing from the interface checks (converter.go:22-38).
  • The comment says replaceSeparators, the function is replaceCharacters (converter.go:81). It also makes one pass per character; a strings.Replacer built once in the constructor would do one.
  • The datetime parameter of DatetimeToStringConverter.Convert shadows the datetime package (converter.go:356).
  • tt_test.go:405: assert.NoError(t, err) checks the outer err left over from uuid.Parse, so it checks nothing.
  • converter_test.go:30: subtest names are built with fmt.Sprintln, so they end with a newline.
  • README "String to any/scalar" doesn't mention array and map for any (and lists interval for scalar, see #13). The Mapper example mixes tabs and spaces.
  • CHANGELOG v1.1.0 says "The release allows to parse any to slices and arrays", while its Fixed section says "GetAnyConverter: don't parse any to slices and arrays".
  • The exported methods of StringToTTConvFactory have no doc comments.
Lenguaje dominante
Go
Estrellas
1
Forks
0
Merge medio
1 h 43 min
PR fusionados (30 d)
2

Preparar el entorno

Este proyecto no incluye contenedor de desarrollo, Dockerfile ni guía de contribución, así que la configuración corre por tu cuenta: empieza por su README y consulta nuestra guía para la primera contribución para los pasos generales.

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 tarantool/go-tupleconv

Todos los issues de tarantool/go-tupleconv

Issues similares

Más issues de Go

Recibe los nuevos issues en tu correo

Un resumen breve de issues de GitHub para principiantes.