ColtenOuO opened a new pull request, #71841:
URL: https://github.com/apache/airflow/pull/71841

   ## Summary
   
   `LangChainHook` and `LlamaIndexHook` are two of the four selectable 
connection types in the `common.ai` provider, but neither implemented 
`test_connection()`.
   
   Clicking "Test" on a connection of either type in the UI always returned:
   > Hook LangChainHook doesn't implement or inherit test_connection method
   
   <img width="1925" height="906" alt="image" 
src="https://github.com/user-attachments/assets/d3ff1d23-4597-4b4b-8466-13e4ff41dae0";
 />
   
   
   `PydanticAIHook` and `MCPHook` — the other two connection types in this 
provider already implement it, resolving the model/config without making a real 
API call. 
   
   ### Changes
   
   This PR adds the same pattern to the two missing hooks:
   
   - `LangChainHook.test_connection()` resolves the chat model via 
`get_chat_model()`.
   - `LlamaIndexHook.test_connection()` resolves the LLM via `get_llm()`.
   
   ---
   
   ##### Was generative AI tooling used to co-author this PR?
   
   - [X] Yes — Claude Code (Sonnet 5) for writting test.


-- 
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