Skip to content

fix: rename stale OpenaiConfig references to APIServerConfig#446

Open
skyc1e wants to merge 2 commits intoNousResearch:mainfrom
skyc1e:fix/rename-openaiconfig-to-apiserverconfig
Open

fix: rename stale OpenaiConfig references to APIServerConfig#446
skyc1e wants to merge 2 commits intoNousResearch:mainfrom
skyc1e:fix/rename-openaiconfig-to-apiserverconfig

Conversation

@skyc1e
Copy link
Copy Markdown

@skyc1e skyc1e commented Apr 13, 2026

Summary

Three environment files still import OpenaiConfig from atroposlib.envs.base, but that class 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

All occurrences (imports, type annotations, constructor calls) have been updated to APIServerConfig. No behavioral change — APIServerConfig accepts the same fields (model_name, base_url, api_key, num_requests_for_eval).

Test plan

  • Added atroposlib/tests/test_env_imports.py — parametrized import regression test covering all three fixed modules
  • Repo-wide grep confirms zero remaining OpenaiConfig references
  • Verified APIServerConfig is re-exported from base.py (line 47)

skyc1e and others added 2 commits April 14, 2026 00:20
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.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant