@@ -562,7 +629,7 @@ Yelp/detect-secrets
-
+
diff --git a/search/search_index.json b/search/search_index.json
index 985501e..3bb0606 100644
--- a/search/search_index.json
+++ b/search/search_index.json
@@ -1 +1 @@
-{"config":{"lang":["en"],"separator":"[\\s\\-]+","pipeline":["stopWordFilter"]},"docs":[{"location":"","title":"Data science project template","text":"Template for a data science projects with software development tools
Documentation: https://joserzapata.github.io/data-science-project-template/
Source Code: https://github.com/JoseRZapata/data-science-project-template
Table of Contents
Data science project template Creating a New Project Linking an Existing Project :card_file_box: Project structure Features and Tools Project Standardization and Automation Developer Workflow Automation Conditionally Rendered Python Package or Project Boilerplate Maintainability Type Checking and Data Validation :white_check_mark: Testing/Coverage :rotating_light: Linting :construction_worker: CI/CD Security :lock_with_ink_pen: Static Application Security Testing (SAST) Accessibility Project Documentation :card_file_box: Templates References "},{"location":"#creating-a-new-project","title":"Creating a New Project","text":""},{"location":"#recommendations","title":"Recommendations","text":"It is highly recommended to use a python version manager like Pyenv and this project is set to use Poetry to manage the dependencies and the environment.
Install Pyenv Install Poetry Via Cruft - recommended:
install cruftpip install --user cruft # Install `cruft` on your path for easy access\n
create projectcruft create https://github.com/JoseRZapata/data-science-project-template\n
Via Cookiecutter:
install cookiecutterpip install --user cookiecutter # Install `cookiecutter` on your path for easy access\n
create projectcookiecutter gh:JoseRZapata/data-science-project-template\n
Note: Cookiecutter uses gh:
as short-hand for https://github.com/
"},{"location":"#linking-an-existing-project","title":"Linking an Existing Project","text":"If the project was originally installed via Cookiecutter, you must first use Cruft to link the project with the original template:
cruft link https://github.com/JoseRZapata/data-science-project-template\n
Then/else:
cruft update\n
"},{"location":"#project-structure","title":"Project structure","text":"Folder structure for data science projects why?
.\n\u251c\u2500\u2500 codecov.yml # configuration for codecov\n\u251c\u2500\u2500 .code_quality\n\u2502\u00a0\u00a0 \u251c\u2500\u2500 bandit.yaml # bandit configuration\n\u2502\u00a0\u00a0 \u251c\u2500\u2500 mypy.ini # mypy configuration\n\u2502\u00a0\u00a0 \u2514\u2500\u2500 ruff.toml # ruff configuration\n\u251c\u2500\u2500 data\n\u2502\u00a0\u00a0 \u251c\u2500\u2500 01_raw # raw immutable data\n\u2502\u00a0\u00a0 \u251c\u2500\u2500 02_intermediate # typed data\n\u2502\u00a0\u00a0 \u251c\u2500\u2500 03_primary # domain model data\n\u2502\u00a0\u00a0 \u251c\u2500\u2500 04_feature # model features\n\u2502\u00a0\u00a0 \u251c\u2500\u2500 05_model_input # often called 'master tables'\n\u2502\u00a0\u00a0 \u251c\u2500\u2500 06_models # serialized models\n\u2502\u00a0\u00a0 \u251c\u2500\u2500 07_model_output # data generated by model runs\n\u2502\u00a0\u00a0 \u251c\u2500\u2500 08_reporting # reports, results, etc\n\u2502\u00a0\u00a0 \u2514\u2500\u2500 README.md # description of the data structure\n\u251c\u2500\u2500 docs # documentation for your project\n\u251c\u2500\u2500 .editorconfig # editor configuration\n\u251c\u2500\u2500 .github # github configuration\n\u2502\u00a0\u00a0 \u251c\u2500\u2500 actions\n\u2502\u00a0\u00a0 \u2502\u00a0\u00a0 \u2514\u2500\u2500 python-poetry-env\n\u2502\u00a0\u00a0 \u2502\u00a0\u00a0 \u2514\u2500\u2500 action.yml # github action to setup python environment\n\u2502\u00a0\u00a0 \u251c\u2500\u2500 pull_request_template.md # template for pull requests\n\u2502\u00a0\u00a0 \u2514\u2500\u2500 workflows\n\u2502\u00a0\u00a0 \u251c\u2500\u2500 dependencies.yml # github action to update dependencies\n\u2502\u00a0\u00a0 \u251c\u2500\u2500 pre-commit_autoupdate.yml # github action update pre-commit hooks\n\u2502\u00a0\u00a0 \u2514\u2500\u2500 test.yml\n\u251c\u2500\u2500 .gitignore # files to ignore in git\n\u251c\u2500\u2500 Makefile # useful commands to setup environment,\n\u251c\u2500\u2500 models # store final models\n\u251c\u2500\u2500 notebooks\n\u2502\u00a0\u00a0 \u251c\u2500\u2500 1-data # notebooks for data extraction and cleaning\n\u2502\u00a0\u00a0 \u251c\u2500\u2500 2-exploration # notebooks for data exploration\n\u2502\u00a0\u00a0 \u251c\u2500\u2500 3-analysis # notebooks for data analysis\n\u2502\u00a0\u00a0 \u251c\u2500\u2500 4-feat_eng # notebooks for feature engineering\n\u2502\u00a0\u00a0 \u251c\u2500\u2500 5-models # notebooks for model training\n\u2502\u00a0\u00a0 \u251c\u2500\u2500 6-evaluation # notebooks for model evaluation\n\u2502\u00a0\u00a0 \u251c\u2500\u2500 7-deploy # notebooks for model deployment\n\u2502\u00a0\u00a0 \u251c\u2500\u2500 notebook_template.ipynb # template for notebooks\n\u2502\u00a0\u00a0 \u2514\u2500\u2500 README.md # information about the notebooks\n\u251c\u2500\u2500 .pre-commit-config.yaml # configuration for pre-commit hooks\n\u251c\u2500\u2500 pyproject.toml # dependencies for poetry\n\u251c\u2500\u2500 README.md # description of your project\n\u251c\u2500\u2500 src # source code for use in this project\n\u251c\u2500\u2500 tests # test code for your project\n\u2514\u2500\u2500 .vscode # vscode configuration\n \u251c\u2500\u2500 extensions.json # list of recommended extensions\n \u2514\u2500\u2500 settings.json # vscode settings\n
"},{"location":"#features-and-tools","title":"Features and Tools","text":""},{"location":"#project-standardization-and-automation","title":"Project Standardization and Automation","text":""},{"location":"#developer-workflow-automation","title":"Developer Workflow Automation","text":" Python packaging, dependency management and environment management with Poetry - why?
Project workflow orchestration with Make as an interface shim Self-documenting Makefile; just type make
on the command line to display auto-generated documentation on available targets: Automated Cookiecutter template synchronization with Cruft - why?
Code quality tooling automation and management with pre-commit Continuous integration and deployment with GitHub Actions Project configuration files with Hydra - why?
"},{"location":"#conditionally-rendered-python-package-or-project-boilerplate","title":"Conditionally Rendered Python Package or Project Boilerplate","text":" Optional: Jupyter support "},{"location":"#maintainability","title":"Maintainability","text":""},{"location":"#type-checking-and-data-validation","title":"Type Checking and Data Validation","text":" Static type-checking with Mypy "},{"location":"#testingcoverage","title":"Testing/Coverage","text":" Testing with Pytest Doctests with xdoctest Code coverage with Coverage.py Coverage reporting with Codecov "},{"location":"#linting","title":"Linting","text":" Code quality: Ruff A blazing-fast (10x-100x faster) replacement for ~~Pylint~~, ~~Flake8~~ (including major plugins) and more linters under a single, common interface ShellCheck Code formatting: Ruff
A blazing-fast (10x-100x faster) replacement for ~~Black~~, ~~isort~~, ~~pyupgrade~~ and more formaters under a single, common interface General file formatting:
end-of-file-fixer
pretty-format-json
(trim) trailing-whitespace
check-yaml
Unsanitary commits: Secrets with detect-secrets
Large files with check-added-large-files
Invalid Python files with check-ast
"},{"location":"#cicd","title":"CI/CD","text":" Dependency updates with Dependabot Automated Dependabot PR merging with the Dependabot Auto Merge GitHub Action "},{"location":"#security","title":"Security","text":""},{"location":"#static-application-security-testing-sast","title":"Static Application Security Testing (SAST)","text":" Code vulnerabilities with Bandit "},{"location":"#accessibility","title":"Accessibility","text":""},{"location":"#project-documentation","title":"Project Documentation","text":" Documentation building with MkDocs - Tutorial Powered by mkdocs-material Rich automatic documentation from type annotations and docstrings (NumPy, Google, etc.) with mkdocstrings "},{"location":"#templates","title":"Templates","text":" Pull Request template Notebook template "},{"location":"#references","title":"References","text":" https://drivendata.github.io/cookiecutter-data-science/ https://github.com/crmne/cookiecutter-modern-datascience https://github.com/khuyentran1401/data-science-template https://github.com/woltapp/wolt-python-package-cookiecutter https://khuyentran1401.github.io/reproducible-data-science/structure_project/introduction.html https://github.com/TeoZosa/cookiecutter-cruft-poetry-tox-pre-commit-ci-cd https://github.com/kedro-org/kedro-starters "},{"location":"pre-commit/","title":"Pre-commit configuration","text":"this project uses pre-commit to run checks on every commit.
Configuration file: .pre-commit-config.yaml
"},{"location":"pre-commit/#pre-commitpre-commit-hooks","title":"pre-commit/pre-commit-hooks","text":"This repository contains some out-of-the-box hooks provided by the pre-commit project.
trailing-whitespace
: This hook trims trailing whitespace. end-of-file-fixer
: This hook ensures that a file is either empty, or ends with one newline. check-yaml
: This hook checks yaml files for parseable syntax. check-case-conflict
: This hook checks for files with names that would conflict on a case-insensitive filesystem like MacOS HFS+ or Windows FAT. debug-statements
: This hook checks for Python debug statements. detect-private-key
: This hook checks for the addition of private keys. check-merge-conflict
: This hook checks for files that contain merge conflict strings. check-ast
: This hook checks Python source files for syntactically valid ast. check-added-large-files
: This hook prevents adding large files. The max size is configurable. "},{"location":"pre-commit/#astral-shruff-pre-commit","title":"astral-sh/ruff-pre-commit","text":"This repository contains hooks for the Ruff programming language.
ruff
: This hook runs the Ruff linter with the --fix
option to automatically fix issues and a custom configuration file. ruff-format
: This hook runs the Ruff formatter. "},{"location":"pre-commit/#pre-commitmirrors-mypy","title":"pre-commit/mirrors-mypy","text":"This repository contains a mirror of mypy for pre-commit.
mypy
: This hook runs mypy, a static type checker for Python, with a custom configuration file. "},{"location":"pre-commit/#pycqabandit","title":"PyCQA/bandit","text":"This repository contains Bandit, a tool designed to find common security issues in Python code.
bandit
: This hook runs Bandit with a custom configuration file. "},{"location":"pre-commit/#yelpdetect-secrets","title":"Yelp/detect-secrets","text":"This repository contains a tool to detect secrets in the code base. yelp detect-secrets
detect-secrets
: This hook runs detect-secrets, a tool to detect secrets in the code base. detect-secrets-jupyter
: This hook runs detect-secrets specifically for Jupyter notebooks. "},{"location":"vscode/","title":"VSCode configuration settings","text":"The following are some common settings that can be configured in Visual Studio Code to improve the Python development experience.
https://github.com/JoseRZapata/data-science-project-template/.vscode/settings.json
{\n \"[python]\": {\n\n \"editor.codeActionsOnSave\": {\n \"source.fixAll.ruff\": \"explicit\",\n \"source.organizeImports.ruff\": \"explicit\",\n },\n \"editor.formatOnSave\": true,\n \"editor.rulers\": [\n 100\n ]\n },\n \"files.exclude\": {\n \"**/__pycache__\": true\n },\n \"python.languageServer\": \"Pylance\",\n \"editor.formatOnPaste\": true,\n \"notebook.lineNumbers\": \"on\",\n \"editor.inlineSuggest.enabled\": true,\n \"editor.formatOnType\": true,\n \"git.autofetch\": true,\n \"editor.defaultFormatter\": \"charliermarsh.ruff\",\n \"python.terminal.activateEnvInCurrentTerminal\": true,\n}\n
[python]
: This section applies settings specifically for Python files.
\"editor.codeActionsOnSave\"
: Specifies actions to be performed when a Python file is saved.
\"source.fixAll.ruff\"
: \"explicit\": The Ruff auto-fix feature is set to explicit mode, meaning it will only fix issues when explicitly told to do so. \"source.organizeImports.ruff\": \"explicit\"
: The Ruff import organization feature is set to explicit mode, meaning it will only organize imports when explicitly told to do so. \"editor.formatOnSave\": true
: This setting enables automatic code formatting when a Python file is saved. \"editor.rulers\": [100]
: This setting adds a vertical ruler at the 100th character in the editor for Python files to guide line length. \"files.exclude\": {\"**/__pycache__\": true}
: This setting hides all pycache directories in the file explorer.
\"python.languageServer\": \"Pylance\"
: This setting specifies Pylance as the language server for Python. A language server provides features like auto-completion and syntax highlighting.
\"editor.formatOnPaste\": true
: This setting enables automatic code formatting when you paste code into the editor.
\"notebook.lineNumbers\": \"on\"
: This setting enables line numbers in Jupyter notebooks.
\"editor.inlineSuggest.enabled\": true
: This setting enables inline suggestions, which show suggested completions as you type.
\"editor.formatOnType\": true
: This setting enables automatic code formatting as you type.
\"git.autofetch\": true
: This setting enables automatic fetching of Git data.
\"editor.defaultFormatter\": \"charliermarsh.ruff\"
: This setting specifies Ruff as the default formatter for code in the editor.
\"python.terminal.activateEnvInCurrentTerminal\": true
: This setting enables automatic activation of the Python environment in the current terminal.
"}]}
\ No newline at end of file
+{"config":{"lang":["en"],"separator":"[\\s\\-]+","pipeline":["stopWordFilter"]},"docs":[{"location":"","title":"Data science project template","text":"Template for a data science projects with software development tools
Documentation: https://joserzapata.github.io/data-science-project-template/
Source Code: https://github.com/JoseRZapata/data-science-project-template
Table of Contents
Data science project template \ud83d\uddc3\ufe0f Creating a New Project \ud83d\udd17 Linking an Existing Project \ud83d\uddc3\ufe0f Project structure \u2728 Features and Tools \ud83d\ude80 Project Standardization and Automation \ud83d\udd28 Developer Workflow Automation \ud83c\udf31 Conditionally Rendered Python Package or Project Boilerplate \ud83d\udd27 Maintainability \ud83c\udff7\ufe0f Type Checking and Data Validation \u2705 Testing/Coverage \ud83d\udea8 Linting \ud83d\udc77 CI/CD \ud83d\udd12 Security \ud83d\udd0f Static Application Security Testing (SAST) \ud83d\udccb Accessibility \ud83d\udcdd Project Documentation \ud83d\uddc3\ufe0f Templates References "},{"location":"#creating-a-new-project","title":"\ud83d\uddc3\ufe0f Creating a New Project","text":""},{"location":"#recommendations","title":"Recommendations","text":"It is highly recommended to use a python version manager like Pyenv and this project is set to use Poetry to manage the dependencies and the environment.
Install Pyenv Install Poetry Via Cruft - recommended:
install cruftpip install --user cruft # Install `cruft` on your path for easy access\n
create projectcruft create https://github.com/JoseRZapata/data-science-project-template\n
Via Cookiecutter:
install cookiecutterpip install --user cookiecutter # Install `cookiecutter` on your path for easy access\n
create projectcookiecutter gh:JoseRZapata/data-science-project-template\n
Note: Cookiecutter uses gh:
as short-hand for https://github.com/
"},{"location":"#linking-an-existing-project","title":"\ud83d\udd17 Linking an Existing Project","text":"If the project was originally installed via Cookiecutter, you must first use Cruft to link the project with the original template:
cruft link https://github.com/JoseRZapata/data-science-project-template\n
Then/else:
cruft update\n
"},{"location":"#project-structure","title":"\ud83d\uddc3\ufe0f Project structure","text":"Folder structure for data science projects why?
.\n\u251c\u2500\u2500 codecov.yml # configuration for codecov\n\u251c\u2500\u2500 .code_quality\n\u2502\u00a0\u00a0 \u251c\u2500\u2500 bandit.yaml # bandit configuration\n\u2502\u00a0\u00a0 \u251c\u2500\u2500 mypy.ini # mypy configuration\n\u2502\u00a0\u00a0 \u2514\u2500\u2500 ruff.toml # ruff configuration\n\u251c\u2500\u2500 data\n\u2502\u00a0\u00a0 \u251c\u2500\u2500 01_raw # raw immutable data\n\u2502\u00a0\u00a0 \u251c\u2500\u2500 02_intermediate # typed data\n\u2502\u00a0\u00a0 \u251c\u2500\u2500 03_primary # domain model data\n\u2502\u00a0\u00a0 \u251c\u2500\u2500 04_feature # model features\n\u2502\u00a0\u00a0 \u251c\u2500\u2500 05_model_input # often called 'master tables'\n\u2502\u00a0\u00a0 \u251c\u2500\u2500 06_models # serialized models\n\u2502\u00a0\u00a0 \u251c\u2500\u2500 07_model_output # data generated by model runs\n\u2502\u00a0\u00a0 \u251c\u2500\u2500 08_reporting # reports, results, etc\n\u2502\u00a0\u00a0 \u2514\u2500\u2500 README.md # description of the data structure\n\u251c\u2500\u2500 docs # documentation for your project\n\u251c\u2500\u2500 .editorconfig # editor configuration\n\u251c\u2500\u2500 .github # github configuration\n\u2502\u00a0\u00a0 \u251c\u2500\u2500 actions\n\u2502\u00a0\u00a0 \u2502\u00a0\u00a0 \u2514\u2500\u2500 python-poetry-env\n\u2502\u00a0\u00a0 \u2502\u00a0\u00a0 \u2514\u2500\u2500 action.yml # github action to setup python environment\n\u2502\u00a0\u00a0 \u251c\u2500\u2500 dependabot.md # github action to update dependencies\n\u2502\u00a0\u00a0 \u251c\u2500\u2500 pull_request_template.md # template for pull requests\n\u2502\u00a0\u00a0 \u2514\u2500\u2500 workflows\n\u2502\u00a0\u00a0 \u251c\u2500\u2500 docs.yml # github action to build documentation (mkdocs)\n\u2502\u00a0\u00a0 \u251c\u2500\u2500 pre-commit_autoupdate.yml # github action update pre-commit hooks\n\u2502\u00a0\u00a0 \u2514\u2500\u2500 test.yml\n\u251c\u2500\u2500 .gitignore # files to ignore in git\n\u251c\u2500\u2500 Makefile # useful commands to setup environment,\n\u251c\u2500\u2500 models # store final models\n\u251c\u2500\u2500 notebooks\n\u2502\u00a0\u00a0 \u251c\u2500\u2500 1-data # notebooks for data extraction and cleaning\n\u2502\u00a0\u00a0 \u251c\u2500\u2500 2-exploration # notebooks for data exploration\n\u2502\u00a0\u00a0 \u251c\u2500\u2500 3-analysis # notebooks for data analysis\n\u2502\u00a0\u00a0 \u251c\u2500\u2500 4-feat_eng # notebooks for feature engineering\n\u2502\u00a0\u00a0 \u251c\u2500\u2500 5-models # notebooks for model training\n\u2502\u00a0\u00a0 \u251c\u2500\u2500 6-evaluation # notebooks for model evaluation\n\u2502\u00a0\u00a0 \u251c\u2500\u2500 7-deploy # notebooks for model deployment\n\u2502\u00a0\u00a0 \u251c\u2500\u2500 notebook_template.ipynb # template for notebooks\n\u2502\u00a0\u00a0 \u2514\u2500\u2500 README.md # information about the notebooks\n\u251c\u2500\u2500 .pre-commit-config.yaml # configuration for pre-commit hooks\n\u251c\u2500\u2500 pyproject.toml # dependencies for poetry\n\u251c\u2500\u2500 README.md # description of your project\n\u251c\u2500\u2500 src # source code for use in this project\n\u251c\u2500\u2500 tests # test code for your project\n\u2514\u2500\u2500 .vscode # vscode configuration\n \u251c\u2500\u2500 extensions.json # list of recommended extensions\n \u2514\u2500\u2500 settings.json # vscode settings\n
"},{"location":"#features-and-tools","title":"\u2728 Features and Tools","text":""},{"location":"#project-standardization-and-automation","title":"\ud83d\ude80 Project Standardization and Automation","text":""},{"location":"#developer-workflow-automation","title":"\ud83d\udd28 Developer Workflow Automation","text":" Python packaging, dependency management and environment management with Poetry - why?
Project workflow orchestration with Make as an interface shim Self-documenting Makefile; just type make
on the command line to display auto-generated documentation on available targets: Automated Cookiecutter template synchronization with Cruft - why?
Code quality tooling automation and management with pre-commit Continuous integration and deployment with GitHub Actions Project configuration files with Hydra - why?
"},{"location":"#conditionally-rendered-python-package-or-project-boilerplate","title":"\ud83c\udf31 Conditionally Rendered Python Package or Project Boilerplate","text":" Optional: Jupyter support "},{"location":"#maintainability","title":"\ud83d\udd27 Maintainability","text":""},{"location":"#type-checking-and-data-validation","title":"\ud83c\udff7\ufe0f Type Checking and Data Validation","text":" Static type-checking with Mypy "},{"location":"#testingcoverage","title":"\u2705 Testing/Coverage","text":" Testing with Pytest Doctests with xdoctest Code coverage with Coverage.py Coverage reporting with Codecov "},{"location":"#linting","title":"\ud83d\udea8 Linting","text":" Code quality: Ruff A blazing-fast (10x-100x faster) replacement for ~~Pylint~~, ~~Flake8~~ (including major plugins) and more linters under a single, common interface ShellCheck Code formatting: Ruff
A blazing-fast (10x-100x faster) replacement for ~~Black~~, ~~isort~~, ~~pyupgrade~~ and more formaters under a single, common interface General file formatting:
end-of-file-fixer
pretty-format-json
(trim) trailing-whitespace
check-yaml
Unsanitary commits: Secrets with detect-secrets
Large files with check-added-large-files
Invalid Python files with check-ast
"},{"location":"#cicd","title":"\ud83d\udc77 CI/CD","text":" Dependency updates with Dependabot Automated Dependabot PR merging with the Dependabot Auto Merge GitHub Action "},{"location":"#security","title":"\ud83d\udd12 Security","text":""},{"location":"#static-application-security-testing-sast","title":"\ud83d\udd0f Static Application Security Testing (SAST)","text":" Code vulnerabilities with Bandit "},{"location":"#accessibility","title":"\ud83d\udccb Accessibility","text":""},{"location":"#project-documentation","title":"\ud83d\udcdd Project Documentation","text":" Documentation building with MkDocs - Tutorial Powered by mkdocs-material Rich automatic documentation from type annotations and docstrings (NumPy, Google, etc.) with mkdocstrings "},{"location":"#templates","title":"\ud83d\uddc3\ufe0f Templates","text":" Pull Request template Notebook template "},{"location":"#references","title":"References","text":" https://drivendata.github.io/cookiecutter-data-science/ https://github.com/crmne/cookiecutter-modern-datascience https://github.com/khuyentran1401/data-science-template https://github.com/woltapp/wolt-python-package-cookiecutter https://khuyentran1401.github.io/reproducible-data-science/structure_project/introduction.html https://github.com/TeoZosa/cookiecutter-cruft-poetry-tox-pre-commit-ci-cd https://github.com/kedro-org/kedro-starters "},{"location":"pre-commit/","title":"Pre-commit configuration","text":"this project uses pre-commit to run checks on every commit.
Configuration file: .pre-commit-config.yaml
"},{"location":"pre-commit/#pre-commitpre-commit-hooks","title":"pre-commit/pre-commit-hooks","text":"This repository contains some out-of-the-box hooks provided by the pre-commit project.
trailing-whitespace
: This hook trims trailing whitespace. end-of-file-fixer
: This hook ensures that a file is either empty, or ends with one newline. check-yaml
: This hook checks yaml files for parseable syntax. check-case-conflict
: This hook checks for files with names that would conflict on a case-insensitive filesystem like MacOS HFS+ or Windows FAT. debug-statements
: This hook checks for Python debug statements. detect-private-key
: This hook checks for the addition of private keys. check-merge-conflict
: This hook checks for files that contain merge conflict strings. check-ast
: This hook checks Python source files for syntactically valid ast. check-added-large-files
: This hook prevents adding large files. The max size is configurable. "},{"location":"pre-commit/#astral-shruff-pre-commit","title":"astral-sh/ruff-pre-commit","text":"This repository contains hooks for the Ruff programming language.
ruff
: This hook runs the Ruff linter with the --fix
option to automatically fix issues and a custom configuration file. ruff-format
: This hook runs the Ruff formatter. "},{"location":"pre-commit/#pre-commitmirrors-mypy","title":"pre-commit/mirrors-mypy","text":"This repository contains a mirror of mypy for pre-commit.
mypy
: This hook runs mypy, a static type checker for Python, with a custom configuration file. "},{"location":"pre-commit/#pycqabandit","title":"PyCQA/bandit","text":"This repository contains Bandit, a tool designed to find common security issues in Python code.
bandit
: This hook runs Bandit with a custom configuration file. "},{"location":"pre-commit/#yelpdetect-secrets","title":"Yelp/detect-secrets","text":"This repository contains a tool to detect secrets in the code base. yelp detect-secrets
detect-secrets
: This hook runs detect-secrets, a tool to detect secrets in the code base. detect-secrets-jupyter
: This hook runs detect-secrets specifically for Jupyter notebooks. "},{"location":"vscode/","title":"VSCode configuration settings","text":"The following are some common settings that can be configured in Visual Studio Code to improve the Python development experience.
https://github.com/JoseRZapata/data-science-project-template/.vscode/settings.json
{\n \"[python]\": {\n\n \"editor.codeActionsOnSave\": {\n \"source.fixAll.ruff\": \"explicit\",\n \"source.organizeImports.ruff\": \"explicit\",\n },\n \"editor.formatOnSave\": true,\n \"editor.rulers\": [\n 100\n ]\n },\n \"files.exclude\": {\n \"**/__pycache__\": true\n },\n \"python.languageServer\": \"Pylance\",\n \"editor.formatOnPaste\": true,\n \"notebook.lineNumbers\": \"on\",\n \"editor.inlineSuggest.enabled\": true,\n \"editor.formatOnType\": true,\n \"git.autofetch\": true,\n \"editor.defaultFormatter\": \"charliermarsh.ruff\",\n \"python.terminal.activateEnvInCurrentTerminal\": true,\n}\n
[python]
: This section applies settings specifically for Python files.
\"editor.codeActionsOnSave\"
: Specifies actions to be performed when a Python file is saved.
\"source.fixAll.ruff\"
: \"explicit\": The Ruff auto-fix feature is set to explicit mode, meaning it will only fix issues when explicitly told to do so. \"source.organizeImports.ruff\": \"explicit\"
: The Ruff import organization feature is set to explicit mode, meaning it will only organize imports when explicitly told to do so. \"editor.formatOnSave\": true
: This setting enables automatic code formatting when a Python file is saved. \"editor.rulers\": [100]
: This setting adds a vertical ruler at the 100th character in the editor for Python files to guide line length. \"files.exclude\": {\"**/__pycache__\": true}
: This setting hides all pycache directories in the file explorer.
\"python.languageServer\": \"Pylance\"
: This setting specifies Pylance as the language server for Python. A language server provides features like auto-completion and syntax highlighting.
\"editor.formatOnPaste\": true
: This setting enables automatic code formatting when you paste code into the editor.
\"notebook.lineNumbers\": \"on\"
: This setting enables line numbers in Jupyter notebooks.
\"editor.inlineSuggest.enabled\": true
: This setting enables inline suggestions, which show suggested completions as you type.
\"editor.formatOnType\": true
: This setting enables automatic code formatting as you type.
\"git.autofetch\": true
: This setting enables automatic fetching of Git data.
\"editor.defaultFormatter\": \"charliermarsh.ruff\"
: This setting specifies Ruff as the default formatter for code in the editor.
\"python.terminal.activateEnvInCurrentTerminal\": true
: This setting enables automatic activation of the Python environment in the current terminal.
"},{"location":"github_actions/gh_action_pre-commit-autoupdate/","title":"GitHub Action:Pre-commit auto-update","text":"This GitHub Action file configures a workflow named \"Pre-commit auto-update\". This workflow is responsible for automatically updating the pre-commit hooks in your repository.
pre-commit_autoupdate.yml
"},{"location":"github_actions/gh_action_pre-commit-autoupdate/#workflow-details","title":"Workflow Details","text":""},{"location":"github_actions/gh_action_pre-commit-autoupdate/#job-pre-commit-update-details","title":"Job \"pre-commit-update\" Details","text":"runs-on
: This job runs on the latest version of Ubuntu.
steps
: Defines the steps to be followed in this job.
Checkout
: This step uses the actions/checkout@v3 action to get a copy of the repository.
Update pre-commit hooks
: This step uses the brokenpip3/action-pre-commit-update
action to update the pre-commit hooks. This action requires a GitHub token to function, which is passed through github-token: ${{ secrets.PAT }}
. PAT is a secret stored in the repository settings that contains a personal access token with repository scope.
In summary, this workflow takes care of keeping the pre-commit hooks in the repository up-to-date, running automatically every Monday and also allowing manual execution whenever necessary.
"}]}
\ No newline at end of file
diff --git a/sitemap.xml.gz b/sitemap.xml.gz
index 2ecf745..c2924b0 100644
Binary files a/sitemap.xml.gz and b/sitemap.xml.gz differ
diff --git a/vscode/index.html b/vscode/index.html
index b3b6c33..8a7cc51 100644
--- a/vscode/index.html
+++ b/vscode/index.html
@@ -9,7 +9,7 @@
-
+
@@ -286,6 +286,73 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ Github Actions
+
+
+
+
+
+
+
+
+
+ Github Actions
+
+
+
+
+
+
+
+
+
+
+
+
@@ -461,7 +528,7 @@ VSCode configuration settings
-
+