Skip to content

Fix deprecation warning from importlib.resources.read_text #543

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged

Conversation

albertvillanova
Copy link
Member

@albertvillanova albertvillanova commented Feb 7, 2025

Fix deprecation warning from importlib.resources.read_text:

huggingface/smolagents/src/smolagents/agents.py:784: DeprecationWarning: read_text is deprecated. Use files() instead. Refer to https://importlib-resources.readthedocs.io/en/latest/using.html#migrating-from-legacy for migration advice.
    importlib.resources.read_text("smolagents.prompts", "code_agent.yaml")

@albertvillanova albertvillanova changed the title Fix deprecation warning from importlib.resources Fix deprecation warning from importlib.resources.read_text Feb 7, 2025
@albertvillanova albertvillanova merged commit ff73f53 into huggingface:main Feb 7, 2025
3 checks passed
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.

2 participants