Skip to content

Conversation

@Danielpeter-99
Copy link
Contributor

@Danielpeter-99 Danielpeter-99 commented May 29, 2025

  • Fixing error when adding new mcp tools
  • Adding more information on docker-compose for images
  • Adding local .env to docker-compose

Summary by Sourcery

Update MCPService import path and enhance docker-compose configuration

Bug Fixes:

  • Correct MCPService import to use the new adk submodule path

Deployment:

  • Enhance docker-compose.yml to comment original image, switch to a local build image, and include a .env file for environment variables

@sourcery-ai
Copy link

sourcery-ai bot commented May 29, 2025

Reviewer's Guide

This PR updates the Docker Compose configuration to use a local build image and include a .env file, and corrects the MCPService import path to the new adk submodule.

Class Diagram: Relocated MCPService Dependency

classDiagram
    class src_utils_mcp_discovery {
        <<Python Module>>
        + _discover_async(config_json) List~Dict~
    }
    class src_services_adk_MCPService {
        <<Python Class>>
        + MCPService()
        # _connect_to_mcp_server(config_json)
    }
    src_utils_mcp_discovery ..> src_services_adk_MCPService : imports and uses
Loading

File-Level Changes

Change Details Files
Enhanced Docker Compose setup with local build image and .env support
  • commented out the remote image pull line
  • switched default image to local build
  • added env_file entry for .env
docker-compose.yml
Refined MCPService import path to align with new ADK module structure
  • removed the original top-level services import
  • introduced import from adk submodule
src/utils/mcp_discovery.py

Tips and commands

Interacting with Sourcery

  • Trigger a new review: Comment @sourcery-ai review on the pull request.
  • Continue discussions: Reply directly to Sourcery's review comments.
  • Generate a GitHub issue from a review comment: Ask Sourcery to create an
    issue from a review comment by replying to it. You can also reply to a
    review comment with @sourcery-ai issue to create an issue from it.
  • Generate a pull request title: Write @sourcery-ai anywhere in the pull
    request title to generate a title at any time. You can also comment
    @sourcery-ai title on the pull request to (re-)generate the title at any time.
  • Generate a pull request summary: Write @sourcery-ai summary anywhere in
    the pull request body to generate a PR summary at any time exactly where you
    want it. You can also comment @sourcery-ai summary on the pull request to
    (re-)generate the summary at any time.
  • Generate reviewer's guide: Comment @sourcery-ai guide on the pull
    request to (re-)generate the reviewer's guide at any time.
  • Resolve all Sourcery comments: Comment @sourcery-ai resolve on the
    pull request to resolve all Sourcery comments. Useful if you've already
    addressed all the comments and don't want to see them anymore.
  • Dismiss all Sourcery reviews: Comment @sourcery-ai dismiss on the pull
    request to dismiss all existing Sourcery reviews. Especially useful if you
    want to start fresh with a new review - don't forget to comment
    @sourcery-ai review to trigger a new review!

Customizing Your Experience

Access your dashboard to:

  • Enable or disable review features such as the Sourcery-generated pull request
    summary, the reviewer's guide, and others.
  • Change the review language.
  • Add, remove or edit custom review instructions.
  • Adjust other review settings.

Getting Help

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 @Danielpeter-99 - I've reviewed your changes and they look great!

Here's what I looked at during the review
  • 🟡 General issues: 2 issues found
  • 🟢 Security: all looks good
  • 🟢 Testing: all looks good
  • 🟢 Documentation: all looks good

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 and I'll use the feedback to improve your reviews.

services:
api:
image: evoapicloud/evo-ai:latest
# image: evoapicloud/evo-ai:latest Use this image to pull from the repo
Copy link

Choose a reason for hiding this comment

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

suggestion: Consider using a separate override file instead of commenting out production image

Using docker-compose.override.yml for environment-specific images keeps the main file clean and prevents outdated commented code.

Suggested implementation:

    image: evoapicloud/evo-ai:latest # Use this image to pull from the repo

Create a new file named docker-compose.override.yml with the following content to use the local image for development:

services:
  api:
    image: evoai-api:latest # Use this image for local builds

This way, the main docker-compose.yml always uses the production image, and local development can override it cleanly.

api:
image: evoapicloud/evo-ai:latest
# image: evoapicloud/evo-ai:latest Use this image to pull from the repo
image: evoai-api:latest # Use this image for local builds
Copy link

Choose a reason for hiding this comment

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

suggestion: Avoid using ‘latest’ tag for local builds to prevent confusion with remote images

Using the same 'latest' tag for both local and remote images can cause Docker to pull the wrong image. Use a unique tag like 'local' or 'dev' for local builds.

Suggested change
image: evoai-api:latest # Use this image for local builds
image: evoai-api:local # Use this image for local builds

@DavidsonGomes DavidsonGomes changed the base branch from main to develop May 31, 2025 14:30
@DavidsonGomes DavidsonGomes merged commit 6f1d274 into EvolutionAPI:develop Jun 2, 2025
2 of 3 checks passed
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.

2 participants