Skip to content

Adding local dev script for running backend & frontend locally #2753

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

Closed
wants to merge 2 commits into from

Conversation

YarivHashaiComet
Copy link
Contributor

Adding script to run opik in development mode.
Running docker containers
Build and running backend locally
Build and running frontend locally

./scripts/dev-local.sh

@YarivHashaiComet YarivHashaiComet marked this pull request as ready for review July 17, 2025 07:22
@YarivHashaiComet YarivHashaiComet requested review from a team as code owners July 17, 2025 07:22
Copy link
Contributor

github-actions bot commented Jul 17, 2025

Python Backend Tests Results

37 tests   35 ✅  2m 33s ⏱️
 1 suites   2 💤
 1 files     0 ❌

Results for commit ab4d3ba.

♻️ This comment has been updated with latest results.

Copy link
Contributor

github-actions bot commented Jul 17, 2025

Backend Tests Results

  187 files  ±0    187 suites  ±0   20m 52s ⏱️ -53s
4 374 tests +3  4 370 ✅ +2  3 💤 ±0  1 ❌ +1 
4 370 runs   - 1  4 366 ✅  - 2  3 💤 ±0  1 ❌ +1 

For more details on these failures, see this check.

Results for commit ab4d3ba. ± Comparison against base commit 86fd6a2.

This pull request removes 1 and adds 4 tests. Note that renamed tests count towards both.
com.comet.opik.api.resources.v1.priv.DatasetsResourceTest$UpdateDataset ‑ updateDataset
com.comet.opik.api.resources.v1.priv.DatasetsResourceTest$UpdateDataset ‑ updateDataset(DatasetUpdate)[1]
com.comet.opik.api.resources.v1.priv.DatasetsResourceTest$UpdateDataset ‑ updateDataset(DatasetUpdate)[2]
com.comet.opik.api.resources.v1.priv.DatasetsResourceTest$UpdateDataset ‑ updateDataset(DatasetUpdate)[3]
com.comet.opik.api.resources.v1.priv.PromptResourceTest$UpdatePrompt ‑ when__promptUpdateIsValid__thenReturnSuccess(Function)[5]

♻️ This comment has been updated with latest results.

Copy link
Collaborator

@andrescrz andrescrz left a comment

Choose a reason for hiding this comment

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

I'll give a deeper review in a few minutes, but we shouldn't move forward with this like it is as it has fundamental problems in the approach and can cause maintainability issues.

However, the general idea is positive, so in that deeper release I'll give you indications and the context to accomplish this in the right direction.

We also scoped one backlog story with more information on how to accomplish this. I'll find the link and provide it to you.

…ide with docker containers for local development
…ide with docker containers for local development
Copy link
Collaborator

@andrescrz andrescrz left a comment

Choose a reason for hiding this comment

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

I give better guidelines to accomplish what you want to achieve here. See OPIK-1095 in our backlog for further details on the docker groups approach.

Copy link
Collaborator

Choose a reason for hiding this comment

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

For all these permissions changes, you should just add execution permissions for the user and leave the others like they are. This should be good for local users and for development, without impacting enterprise customers. If you take a look at Dockerfiles, generally we just run +ux or even 700. Let's prevent security reports here.

Copy link
Collaborator

Choose a reason for hiding this comment

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

This file has a lot of overlap with the CONTRIBUTING.md one. You should consolidate and also get input from product team about how to structure it. This is important for discoverability from external contributors and the community.

This is not a strong blocker on my end, but there's been some historical context about how we structure our .md files. Although being honest, we haven't been completely strict about this and indeed there's some existing overlap and duplication already.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

removing this file

Copy link
Collaborator

Choose a reason for hiding this comment

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

Same about this file, lots of overlap with the new QUICKSTART.md in this PR and also with the pre-existing .md files.

Copy link
Collaborator

Choose a reason for hiding this comment

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

This file has a lot of overlap with the existing opik.sh etc. files. Diverging from them creates multiple issues:

  • Windows users and contributors is not supported, but it should, like opik.ps1 files.
  • Community won't know exactly if using the existing scripts or this one.
  • Increases maintainability, as we need to support both (and also windows flavours).

In general, this should be accomplished with docker groups instead. If you tweak the docker-compose file to add groups (opik, be, fe, infra etc.) you'd just need to update the opik.sh and opik.ps1 files to pass flags on the ones to activate, without further changes.

See OPIK-1095 in our backlog for further details.

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