Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Feature/add GitHub actions #9

Merged
merged 11 commits into from
Aug 29, 2024
Merged

Feature/add GitHub actions #9

merged 11 commits into from
Aug 29, 2024

Conversation

mihamieat
Copy link
Owner

@mihamieat mihamieat commented Aug 29, 2024

Summary by Sourcery

Add GitHub Actions for CI/CD, including workflows for code quality, building, testing, and deployment. Update the README with badges and additional instructions for Docker and unit testing. Upgrade the Black formatter version in the pre-commit configuration.

New Features:

  • Introduce GitHub Actions for continuous integration and deployment, including workflows for code quality checks, building, testing, and deploying the application.

Enhancements:

  • Update the pre-commit configuration to use a newer version of the Black code formatter.
  • Improve the README with additional instructions for Docker and unit testing.

CI:

  • Add a CI workflow to run code quality checks, build the application, and execute tests across multiple MongoDB versions.

Deployment:

  • Add a CD workflow to build and push Docker images to Docker Hub upon changes to the master branch.

Documentation:

  • Enhance the README with badges for code coverage and CI status, and provide detailed instructions for running unit tests.

Copy link

sourcery-ai bot commented Aug 29, 2024

Reviewer's Guide by Sourcery

This pull request adds GitHub Actions for CI/CD, updates the README with badges, modifies the unit test setup, and makes some minor changes to the codebase. The main focus is on implementing automated workflows for code quality checks, building, testing, and deployment.

File-Level Changes

Change Details Files
Implement GitHub Actions for CI/CD
  • Add CI workflow for code quality checks, building, and testing
  • Add CD workflow for deploying to Docker Hub
  • Configure test matrix for multiple MongoDB versions
  • Implement code coverage reporting with Codecov
.github/workflows/ci.yml
.github/workflows/deploy.yml
Update README and project configuration
  • Add CI and code coverage badges to README
  • Update project overview and Docker instructions
  • Add unit test instructions using Docker
  • Update pre-commit configuration
README.md
.pre-commit-config.yaml
Modify unit test setup and execution
  • Update unittest.sh script to use poetry and generate XML coverage report
  • Remove MongoDB credentials from docker-compose.test.yaml
  • Update database connection string in test environment
unittest.sh
docker-compose.test.yaml
src/gpac_api/app/db/database.py
Minor code improvements
  • Reformat NotifCreateSchema in notif.py
  • Update Black version in pre-commit config
src/gpac_api/app/schemas/notif.py
.pre-commit-config.yaml

Tips
  • Trigger a new Sourcery review by commenting @sourcery-ai review on the pull request.
  • Continue your discussion with Sourcery by replying directly to review comments.
  • You can change your review settings at any time by accessing your dashboard:
    • Enable or disable the Sourcery-generated pull request summary or reviewer's guide;
    • Change the review language;
  • You can always contact us if you have any questions or feedback.

Copy link

@sourcery-ai sourcery-ai bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hey @mihamieat - I've reviewed your changes and found some issues that need to be addressed.

Blocking issues:

  • Hardcoded token found in README badge URL. (link)

Overall Comments:

  • Please review the removal of MongoDB credentials in docker-compose.test.yaml. Ensure this change doesn't introduce any security vulnerabilities or break the test environment setup.
  • Great job on implementing CI/CD and test coverage reporting. Consider reviewing the deployment workflow to ensure it includes all necessary steps for a secure and complete deployment process.
Here's what I looked at during the review
  • 🟢 General issues: all looks good
  • 🔴 Security: 1 blocking issue, 1 other issue
  • 🟢 Testing: all looks good
  • 🟢 Complexity: all looks good
  • 🟡 Documentation: 3 issues found

Sourcery is free for open source - if you like our reviews please consider sharing them ✨
Help me be more useful! Please click 👍 or 👎 on each comment to tell me if it was helpful.

src/gpac_api/app/db/database.py Show resolved Hide resolved
README.md Outdated Show resolved Hide resolved
README.md Outdated Show resolved Hide resolved
README.md Outdated Show resolved Hide resolved
README.md Show resolved Hide resolved
@mihamieat mihamieat force-pushed the feature/add-github-actions branch from 469af5f to 126620a Compare August 29, 2024 21:46
@mihamieat mihamieat force-pushed the feature/add-github-actions branch from 126620a to d95b96f Compare August 29, 2024 21:48
@mihamieat
Copy link
Owner Author

Closes #3

@mihamieat mihamieat merged commit 1a1e6d9 into develop Aug 29, 2024
5 checks passed
@mihamieat mihamieat deleted the feature/add-github-actions branch August 29, 2024 21:55
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant