Skip to content

AutoGPT is the vision of accessible AI for everyone, to use and to build on. Our mission is to provide the tools, so that you can focus on what matters.

feat(pre-commit): Detect secrets (#8507)

Swiftyedaa938f99cb
diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml
index 7bf2e6771a..d67aba9edc 100644
--- a/.pre-commit-config.yaml
+++ b/.pre-commit-config.yaml
@@ -9,6 +9,15 @@ repos:
- id: check-merge-conflict
- id: check-symlinks
- id: debug-statements
+
+ - repo: https://github.com/Yelp/detect-secrets
+ rev: v1.5.0
+ hooks:
+ - id: detect-secrets
+ name: Detect secrets
+ description: Detects high entropy strings that are likely to be passwords.
+ files: ^autogpt_platform/
+ stages: [push]
- repo: local
# isort needs the context of which packages are installed to function, so we
@@ -42,7 +51,7 @@ repos:
hooks:
- id: black
name: Lint (Black)
- language_version: python3.10
+ language_version: python3.12
- repo: https://github.com/PyCQA/flake8
rev: 7.0.0
diff --git a/autogpt_platform/backend/backend/usecases/block_autogen.py b/autogpt_platform/backend/backend/usecases/block_autogen.py
index 9f5ae43528..90977f3c2b 100644
--- a/autogpt_platform/backend/backend/usecases/block_autogen.py
+++ b/autogpt_platform/backend/backend/usecases/block_autogen.py
@@ -124,7 +124,7 @@ and it should be enclosed within this block format:
Here are a couple of sample of the Block class implementation:
-{"--------------\n".join([sample_block_codes[v] for v in sample_block_modules])}
+{"--------------".join([sample_block_codes[v] for v in sample_block_modules])}
""",
},
)