open() built in's doc does not say what the buffering default of -1 means
Nadie ha tomado este issue todavía.
- Lenguaje dominante
- Python
- Estrellas
- 77.2k
- Forks
- 36k
- Merge medio
- 1 d 9 h
- PR fusionados (30 d)
- 558
Descripción
On this page https://docs.python.org/3.10/library/functions.html#open the signature of the function is shown as:
open(file, mode='r', buffering=- 1, encoding=None, errors=None, newline=None, closefd=True, opener=None)
Notice the spurious space between the - and the 1.
But more importantly, the explanation of bufferings meaning is:
buffering is an optional integer used to set the buffering policy. Pass 0 to switch buffering off (only allowed in binary mode), 1 to select line buffering (only usable in text mode), and an integer > 1 to indicate the size in bytes of a fixed-size chunk buffer.
In other words, it does not explain what the -1 default means. I assume it means "use the default buffering size for the given mode"; but it really ought to say.
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.
Línea de trabajo
Comienza con la página de documentación de open() en docs.python.org/3.10/library/functions.html#open e inspecciona la firma y la descripción del parámetro buffering. Se considera completado cuando se elimine el espacio espurio en -1 y se documente qué significa el valor predeterminado de buffering.
Escrito por el modelo de indexación a partir del texto del issue.
Evaluación
- Stack tecnológico
- python
- Área
- documentation
- Tipo de issue
- Documentación
- Dificultad
- 1/5
- Tiempo estimado
- Menos de una hora
- Estado de actividad
- Estancado
- Claridad
- Bien especificado
- Aptitud para principiantes
- 45/100