Week #4

Week #4 #

Testing and QA #

  • We implemented automated API tests for the backend using pytest and FastAPI’s TestClient.
  • The tests cover all main endpoints: root, metals list, historical data, and forecast endpoints.
  • Linting is enforced with flake8 to ensure code quality and style consistency.
  • Manual QA was performed for the frontend by opening the site in a browser and verifying all UI features and interactions.

Evidence of test execution #

CI/CD #

  • We used GitHub Actions for continuous integration.
  • The workflow installs dependencies, runs linting (flake8), runs backend tests (pytest), and builds the backend Docker image.
  • The workflow also runs the backend Docker container and checks the /health endpoint to ensure the app starts correctly.

Challenges faced:

  • We encountered a ModuleNotFoundError for main in tests, which was fixed by setting PYTHONPATH=. in the workflow.
  • Docker health checks required a sleep to allow the container to start before testing the endpoint.

Deployment #

Staging #

In our workflow, the staging environment is set up on our local machines using Docker. This allows us to test the application in an environment that closely mimics production, but without any risk to real users or data.

Staging process:

  • The development team runs the application locally using Docker Compose.
  • All services are started with docker compose build command.
  • The application is accessed via localhost.
  • This environment is used for development, integration, and testing before deploying to the production server.

Production #

After successful testing in the local (staging) environment, the application is deployed to a production server on Timeweb Cloud.

Production process:

  • The project repository is cloned to the Timeweb Cloud VDS.
  • Docker and Docker Compose are installed on the server.
  • The same Docker Compose command is used to build and start the services (docker compose build).
  • The application is then accessible via the server’s public IP.

Vibe Check #

This week, we conducted a team health check to discuss our progress, address any roadblocks, and ensure positive team dynamics.

  • Progress: The team is making steady progress on backend, frontend and ml components. We successfully set up local and cloud deployments using Docker and resolved several integration issues.

  • Roadblocks: Some challenges were encountered with Docker networking and frontend-backend communication, but these were collaboratively resolved. No major blockers remain at this time.

  • Team Dynamics: Communication within the team has been open and supportive. Everyone feels comfortable sharing ideas and concerns. We regularly check in during meetings to make sure all voices are heard.

  • Action Items:

    • Continue regular check-ins to maintain transparency.
    • Support any team members who encounter technical or personal challenges.

The team vibe is positive and collaborative. Everyone feels heard and motivated to continue working towards our goals.

Weekly commitments #

Individual contribution of each participant #

Plan for Next Week #

  • Start working on a long-term price prediction.
  • Configure the database to automatically update the dataset.
  • In figma add additional screen resolutions waypoints.
  • Start working on implementation of different screen resolutions in HTML.

Confirmation of the code’s operability #

We confirm that the code in the main branch:

  • [✓] In working condition.
  • [✓] Run via docker-compose (or another alternative described in the README.md).