From 83970c1b6ad542d8382a3778ff81b8aac2c2036d Mon Sep 17 00:00:00 2001 From: Nano Taboada Date: Tue, 8 Apr 2025 16:40:11 -0300 Subject: [PATCH 1/2] chore: move images to assets folder --- README.md | 6 ++---- .../images/python-samples-fastapi-restful-docs.png | Bin .../images/python-samples-fastapi-restful.svg | 0 3 files changed, 2 insertions(+), 4 deletions(-) rename python-samples-fastapi-restful-docs.png => assets/images/python-samples-fastapi-restful-docs.png (100%) rename python-samples-fastapi-restful.svg => assets/images/python-samples-fastapi-restful.svg (100%) diff --git a/README.md b/README.md index 331db21..202888a 100644 --- a/README.md +++ b/README.md @@ -9,8 +9,6 @@ [![CodeFactor](https://www.codefactor.io/repository/github/nanotaboada/python-samples-fastapi-restful/badge)](https://www.codefactor.io/repository/github/nanotaboada/python-samples-fastapi-restful) [![codebeat badge](https://codebeat.co/badges/4c4f7c08-3b35-4b57-a875-bf2043efe515)](https://codebeat.co/projects/github-com-nanotaboada-python-samples-fastapi-restful-master) - - ## Manifesto > "Nobody should start to undertake a large project. You start with a small _trivial_ project, and you should never expect it to get large. If you do, you'll just overdesign and generally think it is more important than it likely is at that stage. Or worse, you might be scared away by the sheer size of the work you envision. So start small, and think about the details. Don't think about some big picture and fancy design. If it doesn't solve some fairly immediate need, it's almost certainly over-designed. And don't expect people to jump in and help you. That's not how these things work. You need to get something half-way _useful_ first, and then others will say "hey, that _almost_ works for me", and they'll get involved in the project." — Linus Torvalds @@ -23,7 +21,7 @@ Proof of Concept for a RESTful API made with [Python 3](https://www.python.org/) The following is a simplified dependency diagram of modules and main libraries: -![Dependency Diagram](python-samples-fastapi-restful.svg) +![Dependency Diagram](assets/images/python-samples-fastapi-restful.svg) ## Install @@ -45,7 +43,7 @@ uvicorn main:app --reload --port 9000 http://localhost:9000/docs ``` -![API Documentation](python-samples-fastapi-restful-docs.png) +![API Documentation](assets/images/python-samples-fastapi-restful-docs.png) ## Credits diff --git a/python-samples-fastapi-restful-docs.png b/assets/images/python-samples-fastapi-restful-docs.png similarity index 100% rename from python-samples-fastapi-restful-docs.png rename to assets/images/python-samples-fastapi-restful-docs.png diff --git a/python-samples-fastapi-restful.svg b/assets/images/python-samples-fastapi-restful.svg similarity index 100% rename from python-samples-fastapi-restful.svg rename to assets/images/python-samples-fastapi-restful.svg From a7f66aeb338afb150d76c8f1287901c7cbb0805e Mon Sep 17 00:00:00 2001 From: Nano Taboada Date: Tue, 8 Apr 2025 16:42:03 -0300 Subject: [PATCH 2/2] chore(ci): adjust Codecov and Codacy settings --- .codacy.yml | 14 +++++++---- codecov.yml | 67 +++++++++++++++++++++++++++++++++++++++++------------ 2 files changed, 61 insertions(+), 20 deletions(-) diff --git a/.codacy.yml b/.codacy.yml index d60d30f..4875560 100644 --- a/.codacy.yml +++ b/.codacy.yml @@ -1,13 +1,17 @@ # https://docs.codacy.com/repositories-configure/codacy-configuration-file/ exclude_paths: - - ".github" - - ".vscode" - - "LICENSE" - - "README.md" + - "assets/**/*" - "data/**/*" - "models/**/*" + - "postman_collections/**/*" - "schemas/**/*" - "tests/**/*" - - "postman_collections/**/*" + - "**/*.yml" + - "**/*.json" + - "**/*.txt" + - "**/__pycache__/" + - "**/*.pyc" + - "LICENSE" - "main.py" + - "README.md" diff --git a/codecov.yml b/codecov.yml index db5f5e4..ef0b027 100644 --- a/codecov.yml +++ b/codecov.yml @@ -1,22 +1,59 @@ # https://docs.codecov.com/docs/codecov-yaml -ignore: - - "data" - - "models" - - "schemas" - - "tests" - - "postman_collections" - - "main.py" - coverage: status: project: - routes: - paths: - - "routes" - services: - paths: - - "services" + default: + target: 80% + threshold: 10% + if_not_found: success + if_ci_failed: error + patch: default: - informational: true + target: 80% + threshold: 10% + +flags: + unit: + paths: + - "services/" + - "routes/" + carryforward: true + +component_management: + default_rules: + statuses: + - type: project + target: auto + branches: + - "!main" + + individual_components: + - component_id: services + name: Services + paths: + - "services/" + - component_id: routes + name: Routes + paths: + - "routes/" + +comment: + layout: "header, diff, flags, components" + +ignore: + - "assets/**/*" + - "data/**/*" + - "models/**/*" + - "postman_collections/**/*" + - "schemas/**/*" + - "tests/**/*" + - "**/*.yml" + - "**/*.json" + - "**/*.txt" + - "**/__pycache__/" + - "**/*.pyc" + - "LICENSE" + - "main.py" + - "README.md"