weiqingy commented on code in PR #831:
URL: https://github.com/apache/flink-agents/pull/831#discussion_r3393174813


##########
python/flink_agents/integrations/chat_models/tests/test_ollama_chat_model.py:
##########
@@ -37,16 +34,8 @@
 pytestmark = pytest.mark.integration
 
 test_model = os.environ.get("OLLAMA_CHAT_MODEL", "qwen3:1.7b")
-current_dir = Path(__file__).parent
 
 try:
-    # only auto setup ollama in ci with python 3.10 to reduce ci cost.
-    if "3.10" in sys.version:
-        subprocess.run(
-            ["bash", f"{current_dir}/start_ollama_server.sh", test_model],
-            timeout=300,
-            check=True,
-        )

Review Comment:
   Good catch -`tools/start_ollama_server.sh` only installs the server; it 
doesn't pull models, so after dropping the inline block these tests would skip 
on a missing model in CI rather than actually run.
   
   Switched both files to `client = pull_model(test_model)` from 
`e2e_tests/test_utils.py` — the same helper the e2e integration tests already 
use. It pulls the model and returns the client (or `None`), so the existing 
`skipif(client is None)` guard is unchanged. Also dropped the now-unused `from 
ollama import Client`.
   
   Verified locally: the embedding test now runs instead of skipping. Fixed in 
3b8d9e1.
   



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to