fern-api / fern

Input OpenAPI. Output SDKs and Docs.
https://buildwithfern.com
Apache License 2.0
2.6k stars 139 forks source link

fix(python): all pydantic v2 warnings are now resolved #4611

Closed armandobelardo closed 2 weeks ago

armandobelardo commented 3 weeks ago

This PR also adds in function overrides when leveraging in-house aliases to allow users to leverage construct and model_construct as normal

This PR introduces a number of changes to the UniversalBaseModel class in the pydantic_utilities.py file.

Changes

gitguardian[bot] commented 3 weeks ago

⚠️ GitGuardian has uncovered 1 secret following the scan of your pull request.

Please consider investigating the findings and remediating the incidents. Failure to do so may lead to compromising the associated services or software components.

🔎 Detected hardcoded secret in your pull request
| GitGuardian id | GitGuardian status | Secret | Commit | Filename | | | -------------- | ------------------ | ------------------------------ | ---------------- | --------------- | -------------------- | | [13738502](https://dashboard.gitguardian.com/workspace/324468/incidents/13738502?occurrence=165390876) | Triggered | Generic High Entropy Secret | 74f9319cf2f9f89f87eb46407daa6664e8301572 | generators/java/sdk/versions.yml | [View secret](https://github.com/fern-api/fern/commit/74f9319cf2f9f89f87eb46407daa6664e8301572#diff-74cd5e27f83547bd605f28d8c456ef3ad699b55b1fa9a6ab1213a381c99bc4d1R248) |
🛠 Guidelines to remediate hardcoded secrets
1. Understand the implications of revoking this secret by investigating where it is used in your code. 2. Replace and store your secret safely. [Learn here](https://blog.gitguardian.com/secrets-api-management?utm_source=product&utm_medium=GitHub_checks&utm_campaign=check_run_comment) the best practices. 3. Revoke and [rotate this secret](https://docs.gitguardian.com/secrets-detection/secrets-detection-engine/detectors/generics/generic_high_entropy_secret#revoke-the-secret?utm_source=product&utm_medium=GitHub_checks&utm_campaign=check_run_comment). 4. If possible, [rewrite git history](https://blog.gitguardian.com/rewriting-git-history-cheatsheet?utm_source=product&utm_medium=GitHub_checks&utm_campaign=check_run_comment). Rewriting git history is not a trivial act. You might completely break other contributing developers' workflow and you risk accidentally deleting legitimate data. To avoid such incidents in the future consider - following these [best practices](https://blog.gitguardian.com/secrets-api-management/?utm_source=product&utm_medium=GitHub_checks&utm_campaign=check_run_comment) for managing and storing secrets including API keys and other credentials - install [secret detection on pre-commit](https://docs.gitguardian.com/ggshield-docs/integrations/git-hooks/pre-commit?utm_source=product&utm_medium=GitHub_checks&utm_campaign=check_run_comment) to catch secret before it leaves your machine and ease remediation.

🦉 GitGuardian detects secrets in your source code to help developers and security teams secure the modern development process. You are seeing this because you or someone else with access to this repository has authorized GitGuardian to scan your pull request.