Hacktoberfest 2026: los issues que los mantenedores marcaron para octubre, abiertos y aptos para principiantes. Explorar issues de Hacktoberfest

Allow using a heuristic with the `doesitcache` tool

Abierto
#118 4 comentarios 0 reacciones 0 asignados Ver en GitHub

Nadie ha tomado este issue todavía.

Evaluación

Dificultad
4/5
Tiempo estimado
3-5 días
Aptitud para principiantes
30/100
Tipo de issue
Nueva funcionalidad
Claridad
Bastante claro
Estado de actividad
Estancado
Stack tecnológico
python
Área
cli

Línea de trabajo

Comienza localizando el punto de entrada de CLI de doesitcache y las clases base de las heurísticas. Revisa cómo se descubren y se instancian las heurísticas y, a continuación, implementa los modos solicitados de listado, de heurística con nombre y de ruta de Python con opciones predeterminadas; el trabajo incluye documentar las nuevas opciones y su comportamiento.

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

Descripción

Often times CacheControl be confusing b/c something seems like it should be cached, but it is not. There is typically a good explanation for this and work around that comes in the form of heuristics. It would be helpful for the doesitcache tool to accept a heuristic.

Specificially:

  1. doesitcache --list-heuristics - list the available heuristics and print the docstring of the classes
  2. doesitcache --heuristic $NAME - Apply an heuristic. There might be options that need to be passed in, which seems to go above and beyond at the moment. Just making sure heuristics have defaults should be enough
  3. doesitcache --heuristic $PATH - Use the file to load a python object as the heuristic. The algorithm would be to import it and see what classes are instances of the heuristic base class, choosing the first one to apply.

Docs!

Thanks to @sigmavirus24 for the suggestion!

Lenguaje dominante
Python
Estrellas
505
Forks
153
Merge medio
5 d 6 h
PR fusionados (30 d)
5

Preparar el entorno

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 psf/cachecontrol

Todos los issues de psf/cachecontrol

Issues similares

Más issues de Python

Recibe los nuevos issues en tu correo

Un resumen breve de issues de GitHub para principiantes.