mirror of
https://github.com/NousResearch/atropos.git
synced 2026-04-29 17:35:07 +00:00
Three environment files still imported the old `OpenaiConfig` name, which was renamed to `APIServerConfig`. This causes an ImportError at module load time, making these environments unusable: - environments/sft_loader_server.py - environments/community/ufc_prediction_env/ufc_server.py - environments/community/ufc_prediction_env/ufc_image_env.py Also adds a lightweight import regression test.
22 lines
614 B
Python
22 lines
614 B
Python
"""Regression tests for environment module imports.
|
|
|
|
Ensures every environment module can be imported without errors
|
|
(e.g. no stale references to renamed symbols like OpenaiConfig).
|
|
"""
|
|
|
|
import importlib
|
|
|
|
import pytest
|
|
|
|
|
|
@pytest.mark.parametrize(
|
|
"module_path",
|
|
[
|
|
"environments.sft_loader_server",
|
|
"environments.community.ufc_prediction_env.ufc_server",
|
|
"environments.community.ufc_prediction_env.ufc_image_env",
|
|
],
|
|
)
|
|
def test_environment_module_imports(module_path):
|
|
"""Each environment module should import without ImportError."""
|
|
importlib.import_module(module_path)
|