1. Summary:
I’m working with Frappe version 15.69.2 and recently installed the package langchain-google-genai~=2.1.4
. During the installation, I encountered a dependency conflict related to the google-auth
package.
2. Error:
Here’s the error I received during installation:
ERROR: pip's dependency resolver does not currently take into account all the packages that are installed. This behaviour is the source of the following dependency conflicts.
google-api-python-client 2.2.0 requires google-auth<2dev,>=1.16.0, but you have google-auth 2.40.2 which is incompatible.
frappe 15.69.2 requires google-auth~=1.29.0, but you have google-auth 2.40.2 which is incompatible.
3. Root Cause:
The issue stems from the fact that both frappe
and google-api-python-client
have strict dependencies on older versions of google-auth
. However, the langchain-google-genai
package requires or pulls in a newer version (2.40.2
) of google-auth
, leading to a version mismatch.
4. Asking Help and Suggestions:
Despite the version conflict warning, my app is installed successfully and the APIs from langchain-google-genai
are working fine. For my use case, I specifically need the newer version of google-auth
.
I’m aware this might risk breaking other parts of the system, especially since Frappe or ERPNext or their dependencies may rely on older versions of google-auth
. Based on my research, the newer google-auth
versions seem to maintain backward compatibility — but I might be missing something.
Could someone with more experience in this area help clarify:
- Is it safe to continue using the newer
google-auth
version with Frappe 15? - Are there known issues or risks involved with this version upgrade?
- Any workarounds or best practices for managing such dependency conflicts in a Frappe environment?
- I need some insights for the version-14 as well?
Thanks in advance for your insights!