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

[MNT] Replace Live Server Calls with Mocks in Unit Tests

Abierto
#1,649 25 comentarios 1 reacción 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
35/100
Tipo de issue
Refactorización
Claridad
Bastante claro
Estado de actividad
Estancado
Stack tecnológico
python
Área
testing-qa

Línea de trabajo

Start by inspecting the listed test files for the production_server and test_server markers, then read openml._api_calls._send_request and its requests.Session usage. Replace the remote calls with mocks or patches in a focused test-file subtask, and run the affected pytest tests to confirm they pass without contacting the live server.

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

Descripción

Good First Issue maintenance & CI testing

Several tests currently rely on direct connections to the live server (production/test), which can cause race conditions, server overload, and sporadic failures (see https://github.com/openml/openml-python/issues/1586). To ensure these remain true unit tests, they should use mocks/patches instead of the remote server.

Steps:

  1. Identify tests using the remote server, e.g., marked with "production_server" or "test_server".
  2. Mock or patch requests.Session in tests relying on openml._api_calls._send_request. Alternatively, higher-level mocking can be used to simplify implementation.

Affected test files (can be separate sub-tasks/PRs):

Lenguaje dominante
Python
Estrellas
361
Forks
296
Métricas de merge de PR
Sin PR fusionados en 30 d

Guía de contribución

Abrir la 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 openml/openml-python

Todos los issues de openml/openml-python

Issues similares

Más issues de Python

Recibe los nuevos issues en tu correo

Un resumen breve de issues de GitHub para principiantes.