433 Commits

Author SHA1 Message Date
Xingyao Wang
1d49ef253b [Runtime] Reduce dependency to speed up CI and reduce image size (#3195)
* reduce dependency for runtime

* try making llama-index an optional dependency that's not installed by default

* do not install llama-index in CI

* do not install llama-index in the app docker as well
2024-07-31 13:55:09 -04:00
Xingyao Wang
bd68249fba [Arch] Test EventStreamRuntime to ensure its feature parity with ServerRuntime (#3157)
* Remove global config from memory

* Remove runtime global config

* Remove from storage

* Remove global config

* Fix event stream tests

* Fix sandbox issue

* Change config

* Removed transferred tests

* Add swe env box

* Fixes on testing

* Fixed some tests

* Merge with stashed changes

* Fix typing

* Fix ipython test

* Revive function

* Make temp_dir fixture

* Remove test to avoid circular import

* fix eventstream filestore for test_runtime

* fix parse arg issue that cause integration test to fail

* support swebench pull from custom namespace

* add back simple tests for runtime

* move multi-line bash tests to test_runtime;
support multi-line bash for esruntime;

* add testcase to handle PS2 prompt

* use bashlex for bash parsing to handle multi-line commands;
add testcases for multi-line commands

* revert ghcr runtime change

* Apply stash

* fix run as other user;
make test async;

* fix test runtime for run as od

* add run-as-devin to all the runtime tests

* handle the case when username is root

* move all run-as-devin tests from sandbox;
only tests a few cases on different user to save time;

* move over multi-line echo related tests to test_runtime

* fix user-specific jupyter by fixing the pypoetry virtualenv folder

* make plugin's init async;
chdir at initialization of jupyter plugin;
move ipy simple testcase to test runtime;

* support agentskills import in
move tests for jupyter pwd tests;
overload `add_env_vars` for EventStreamRuntime to update env var also in Jupyter;
make agentskills read env var lazily, in case env var is updated;

* fix ServerRuntime agentskills issue

* move agnostic image test to test_runtime

* merge runtime tests in CI

* fix enable auto lint as env var

* update warning message

* update warning message

* test for different container images

* change parsing output as debug

* add exception handling for update_pwd_decorator

* fix unit test indentation

* add plugins as default input to Runtime class;
remove init_sandbox_plugins;
implement add_env_var (include jupyter) in the base class;

* fix server runtime auto lint

* Revert "add exception handling for update_pwd_decorator"

This reverts commit 2b668b1506.

* tries to print debugging info for agentskills

* explictly setting uid (try fix permission issue)

* Revert "tries to print debugging info for agentskills"

This reverts commit 8be4c86756.

* set sandbox user id during testing to hopefully fix the permission issue

* add browser tools for server runtime

* try to debug for old pwd

* update debug cmd

* only test agnostic runtime when TEST_RUNTIME is Server

* fix temp dir mkdir

* load TEST_RUNTIME at the beginning

* remove ipython tests

* only log to file when DEBUG

* default logging to project root

* temporarily remove log to file

* fix LLM logger dir

* fix logger

* make set pwd an optional aux action

* fix prev pwd

* fix infinity recursion

* simplify

* do not import the whole od library to avoid logger folder by jupyter

* fix browsing

* increase timeout

* attempt to fix agentskills yet again

* clean up in testcases, since CI maybe run as non-root

* add _cause attribute for event.id

* remove parent

* add a bunch of debugging statement again for CI :(

* fix temp_dir fixture

* change all temp dir to follow pytest's tmp_path_factory

* remove extra bracket

* clean up error printing a bit

* jupyter chdir to self.config.workspace_mount_path_in_sandbox on initialization

* jupyter chdir to self.config.workspace_mount_path_in_sandbox on initialization

* add typing for tmp dir fixture

* clear the directory before running the test to avoid weird CI temp dir

* remove agnostic test case for server runtime

* Revert "remove agnostic test case for server runtime"

This reverts commit 30e2181c3f.

* disable agnostic tests in CI

* fix test

---------

Co-authored-by: Graham Neubig <neubig@gmail.com>
2024-07-31 04:30:59 +08:00
மனோஜ்குமார் பழனிச்சாமி
84a6e90dc2 Chore: Add line breaks in pull_request_template.md (#2988)
* Update pull_request_template.md

* Update pull_request_template.md
2024-07-29 15:10:33 -04:00
Xingyao Wang
1f6e86c932 Fix(test,CI): runtime build tests (#3126)
* fix runtime build test

* get runtime_build test to run in CI

* move test involving docker from `test_ipython` to `test_sandbox`
2024-07-26 22:53:01 +08:00
Xingyao Wang
99f6f8899d fix filename for image tar (#3121) 2024-07-26 02:38:41 +00:00
Xingyao Wang
f28a6db2c6 add missing ext (#3120) 2024-07-26 06:32:14 +08:00
tobitege
22c7bca556 (fix) colima: fix return code handling (followup to #3097) (#3106)
* colima: fix return code handling; added delay before retry; 4 retries

* moved docker context outside of function

* changed delete occurence; added logs output

* removed delete; trying to add more logging

* fix typo

* changed logging to github-style. maybe this finally shows up.

* reverted context; loop now with install+delete and alternating IP

* fix local keyword

* try limactl for creating an instance for IP

* revert IP change attempts

* actually return 0 in start_colima

* moved install out of loop again

* another to avoid duplicate start of colima via limactl

* added --init call for lima.yaml file creation

* dont trust an LLM to give you flags...

* Update run-unit-tests.yml
2024-07-26 03:16:02 +08:00
tobitege
b71dc38855 ghcr-runtime: no unzip, artifact downloads as-is, without extention (#3105) 2024-07-25 14:20:20 +02:00
tobitege
9576916a49 (fix) Runtime yml missing zip handling (fixes #3101) (#3104)
* fix ghcr_push use of image name

* ghcr-runtime: fix artifact download (zip); removed obsolete show of df
2024-07-25 08:53:27 +00:00
tobitege
690290697a fix ghcr_push use of image name (#3101) 2024-07-25 10:53:20 +08:00
tobitege
4862661732 (fix) colima: use a docker context specific to runner; prevent duplicate start (#3097)
* colima: use a docker context specific to runner; prevent duplicate start

* updated use of context (for docker, not colima)

* added --ssh to colima start to use TCP instead of socket

* replace --ssh with random port
2024-07-24 13:59:59 -04:00
Xingyao Wang
405c8a0456 [Arch] Add runtime image build CI & clean up runtime build using jinja2 template (#3055)
* test_runtime_client.py to test _execute_bash()

* runtime_build and runtime tweaks

* fix in docker script

* revert bash changes

* use sandbox_config.update_source_code to control source code update

* add od_version to the sandbox tag

* add doc instruction for update source code

* do not remove whole poetry folder;
add mamba clean

* add missing newlines

* cleanup runtime dockerfile into jinja template

* make prep temp file a separate function;
make that function accessible through cli

* modify `runtime_build.py` so it can generate directory for building docker img

* add dockerfile and sdist of runtime to gitignore since it will be dynamically generated

* add runtime to build

* do not rebuild new image when an `od_runtime` is provided

* use default container_image for testing if possible

* move runtime tests to ghcr runtime workflow

* update docker base dir for runtime

* fix unittest

* fix image name

* fix image name for test case

* rename to make it consistent

---------

Co-authored-by: tobitege <tobitege@gmx.de>
2024-07-24 21:56:12 +08:00
மனோஜ்குமார் பழனிச்சாமி
f3c23e8039 CI: Force stop colima (#3053) 2024-07-22 01:46:57 +08:00
Julian Gums
b5e4cddce3 fix docs links (#3017)
* fix docs link

* Update CONTRIBUTING.md

* Update README.md

* fix docs link

* fix docs link

* Update troubleshooting.md

* fix docs link

* fix docs link

* fix docs link

* fix docs link
2024-07-19 13:57:33 +00:00
Graham Neubig
de74c7a0a1 Convert docs to new URL (#3002) 2024-07-18 17:04:35 +00:00
மனோஜ்குமார் பழனிச்சாமி
f70c5afb6e Update run-unit-tests.yml (#2993) 2024-07-18 13:58:23 +00:00
மனோஜ்குமார் பழனிச்சாமி
2250947919 CI: Stop colima instance if failed to start (#2989)
* CI: Stop colima instance if failed to start

* change to classic for loop
2024-07-18 15:53:44 +02:00
மனோஜ்குமார் பழனிச்சாமி
728131ff1d Fix: Review PR Dogfood (#2916)
* Fix env variables, prompt, and exit

(cherry picked from commit b45bc1638397427ec5e82540c63c4cda0d1e2094)

* fix echo

* Run without docker

to avoid running as root.

---------

Co-authored-by: Boxuan Li <liboxuan@connect.hku.hk>
2024-07-18 11:10:53 +08:00
Xingyao Wang
f80ecec772 [Arch] Add tests for EventStreamRuntime and fix bash parsing (#2933)
* deprecating recall action

* fix integration tests

* fix integration tests

* refractor runtime to use async

* remove search memory

* rename .initialize to .ainit

* draft of runtime image building (separate from img agnostic)

* refractor runtime build into separate file and add unit tests for it

* fix image agnostic tests

* move `split_bash_commands` into a separate util file

* fix bash pexcept parsing for env

* refractor add_env_var from sandbox to runtime;
add test runtime for env var, remove it from sandbox;

* remove unclear comment

* capture broader error

* make `add_env_var` handle multiple export at the same time

* add multi env var test

* fix tests with new config

* make runtime tests a separate ci to avoid full disk

* Update Runtime README with architecture diagram and detailed explanations

* update test

* remove dependency of global config in sandbox test

* fix sandbox typo

* runtime tests does not need ghcr build now

* remove download runtime img

* remove dependency of global config in sandbox test

* fix sandbox typo

* try to free disk before running the tests

* Update opendevin/runtime/client/README.md

Co-authored-by: Yufan Song <33971064+yufansong@users.noreply.github.com>

* Update opendevin/runtime/client/README.md

Co-authored-by: Yufan Song <33971064+yufansong@users.noreply.github.com>

* Update opendevin/runtime/client/README.md

Co-authored-by: Yufan Song <33971064+yufansong@users.noreply.github.com>

* try to reduce code duplication

* Update opendevin/runtime/client/README.md

Co-authored-by: Yufan Song <33971064+yufansong@users.noreply.github.com>

* Update opendevin/runtime/client/README.md

Co-authored-by: Yufan Song <33971064+yufansong@users.noreply.github.com>

* Update opendevin/runtime/client/README.md

Co-authored-by: Yufan Song <33971064+yufansong@users.noreply.github.com>

* Update opendevin/runtime/client/README.md

Co-authored-by: Yufan Song <33971064+yufansong@users.noreply.github.com>

* Update opendevin/runtime/client/README.md

Co-authored-by: Yufan Song <33971064+yufansong@users.noreply.github.com>

* cleanup before setup

* temporarily remove this enable lint test since env var are now handled by runtime

* linter

---------

Co-authored-by: OpenDevin <opendevin@all-hands.dev>
Co-authored-by: Yufan Song <33971064+yufansong@users.noreply.github.com>
2024-07-18 06:10:45 +08:00
மனோஜ்குமார் பழனிச்சாமி
471703bea6 CI: Add retry mechanism (#2915) 2024-07-15 19:30:27 +00:00
மனோஜ்குமார் பழனிச்சாமி
9d7adefe0c chore: Update wordings in pull request template (#2926)
* Update wordings in pull request template

* Update .github/pull_request_template.md
2024-07-15 11:28:05 -04:00
Boxuan Li
2b7c4e5571 Remove legacy dummy action from CI (#2903) 2024-07-13 02:27:13 +08:00
Boxuan Li
c68478f470 Customize LLM config per agent (#2756)
Currently, OpenDevin uses a global singleton LLM config and a global singleton agent config. This PR allows customers to configure an LLM config for each agent. A hypothetically useful scenario is to use a cheaper LLM for repo exploration / code search, and a more powerful LLM to actually do the problem solving (CodeActAgent).

Partially solves #2075 (web GUI improvement is not the goal of this PR)
2024-07-09 22:05:54 -07:00
மனோஜ்குமார் பழனிச்சாமி
85a817304e Check exit code (#2834) 2024-07-07 17:35:22 +02:00
மனோஜ்குமார் பழனிச்சாமி
3a3694ca17 doc: Mention negative feedback feature in bug report. (#2827)
* doc: Mention feedback feature in bug report.

* Update .github/ISSUE_TEMPLATE/bug_template.yml

Co-authored-by: Graham Neubig <neubig@gmail.com>

---------

Co-authored-by: Graham Neubig <neubig@gmail.com>
2024-07-07 06:56:12 +00:00
Leo
9b0ff117ab CI: Support uploading frontend unit test coverage. (#2772)
* CI: Support uploading frontend unit test coverage.

* Add make-i18n before test.

* Update vitest configuration to include only .ts and .tsx files in coverage.

* remove .only in test and fix the failed tests.

* Add text summary.

* Move vite-tsconfig-paths to dev dep. Adjust UTs.

---------

Signed-off-by: ifuryst <ifuryst@gmail.com>
Co-authored-by: sp.wack <83104063+amanape@users.noreply.github.com>
2024-07-06 12:16:30 +08:00
மனோஜ்குமார் பழனிச்சாமி
ed45a9e7b1 delete colima profile (#2807) 2024-07-05 08:55:26 -07:00
மனோஜ்குமார் பழனிச்சாமி
143f38d25a Refactored sandbox config and added fast boot (#2455)
* Refactored sandbox config and added fastboot

* added tests

* fixed tests

* fixed tests

* intimate user about breaking change

* remove default config from eval

* check for lowercase env

* add test

* Revert Migration

* migrate old sandbox configs

* resolve merge conflict

* revert migration 2

* Revert "remove default config from eval"

This reverts commit de57c588db.

* change type to box_type

* fix var name

* linted

* lint

* lint comments

* fix tests

* fix tests

* fix typo

* fix box_type, remove fast_boot

* add tests for sandbox config

* fix test

* update eval docs

* small removal comments

* adapt toml template

* old fields shouldn't be in the app dataclass

* fix old keys in app config

* clean up exec box

---------

Co-authored-by: Engel Nyst <enyst@users.noreply.github.com>
2024-07-05 03:30:21 +00:00
Xingyao Wang
0d3b3ffbf8 [Arch] Removing docker exec box (#2802)
* depracting docker exec box

* remove doc exec from workflow and docs
2024-07-04 23:15:25 +00:00
Leo
869997b941 chore: Add docs for dependabot and add the open pr limit from 5 to 20. (#2784)
Signed-off-by: ifuryst <ifuryst@gmail.com>
2024-07-04 18:07:30 +08:00
மனோஜ்குமார் பழனிச்சாமி
cc8204e5c1 CI: For colima, modify CPU count and memory (#2712)
* CI: For colima, modify CPUcount and memory

* fix arg
2024-07-02 15:44:44 +02:00
Engel Nyst
1975689cd4 remove swe agent (#2708) 2024-07-01 12:27:14 +09:00
Boxuan Li
79a3e81708 ghcr: Fix local built image name in tests (#2686)
* ghcr: Fix local built image name in tests

* Push to registry when tagged

* Fix push and experiment

* Remove debug
2024-06-29 09:53:30 -07:00
tobitege
1117dfebeb feat: update version to 0.6.2. added Action to update pyproject on Release (#2552)
* updated version; added Action to update pyproject version by current tag (if changed)

* higer pyproject version creates a tag now

* Release-only run to write tag to pyproject
2024-06-24 18:34:57 +02:00
மனோஜ்குமார் பழனிச்சாமி
c455a09e43 Remove Colima and lima directory after uninstalling for Mac OS CI (#2598)
* Remove colima dir after uninstall

* Delete lima dir
2024-06-23 08:28:29 +02:00
மனோஜ்குமார் பழனிச்சாமி
6bf1b56f06 Revert "Enable "vz" vm-type for MacOS CI (#2586)" (#2588)
This reverts commit 57b56c0536.
2024-06-22 23:45:14 +08:00
மனோஜ்குமார் பழனிச்சாமி
57b56c0536 Enable "vz" vm-type for MacOS CI (#2586) 2024-06-22 12:30:18 +00:00
மனோஜ்குமார் பழனிச்சாமி
0845d475b8 Fix Mac CI Test (#2569)
* Fix Mac CI Test

* Start colima service

* unlink colima dependency: go

* Check for colima

Co-authored-by: Graham Neubig <neubig@gmail.com>

* fix indent

Co-authored-by: Graham Neubig <neubig@gmail.com>

* Try with uninstall

---------

Co-authored-by: Graham Neubig <neubig@gmail.com>
2024-06-22 02:36:23 +00:00
Boxuan Li
01fa52d062 Enforce linter in tests folder (#2557) 2024-06-20 21:50:34 -07:00
மனோஜ்குமார் பழனிச்சாமி
f3ba2f02d5 Fix Mac OS CI - usernet unable to resolve IP for SSH forwarding (#2556) 2024-06-21 10:02:26 +05:30
Boxuan Li
bfa00932cc Enable test_agnostic_sandbox_jupyter_agentskills_fileop_pwd in CI (#2534)
* Enable test_agnostic_sandbox_jupyter_agentskills_fileop_pwd in CI

* Fix env variable value
2024-06-20 20:39:11 -06:00
மனோஜ்குமார் பழனிச்சாமி
35fc2177d0 Fix Mac CI test (#2544) 2024-06-21 00:56:23 +08:00
மனோஜ்குமார் பழனிச்சாமி
833bb50fb0 Downgrade Mac version in CI/CD Pipeline (#2499)
* downgrade mac version in CI

* Delete run-integration-tests.yml
2024-06-19 22:12:15 -07:00
Boxuan Li
89cae8d6b8 Fix Docker tagging issue with upper case (#2512)
* Fix Docker tagging issue with upper case

* Update containers/build.sh

Co-authored-by: மனோஜ்குமார் பழனிச்சாமி <smartmanoj42857@gmail.com>

* Use tr command which is available on both zsh and bash

* Lower image name

* Lower image name

* Update .github/workflows/ghcr.yml

Co-authored-by: மனோஜ்குமார் பழனிச்சாமி <smartmanoj42857@gmail.com>

* Fix shell syntax

---------

Co-authored-by: மனோஜ்குமார் பழனிச்சாமி <smartmanoj42857@gmail.com>
2024-06-19 00:11:18 -06:00
Boxuan Li
c2fa99b4a1 Split container image build & push (#2456)
* Split container image build & push

* Code cleanup

* Cleanup

* Add back useless docker_build_success step to make CI happy

* Revert "Cleanup"

This reverts commit 2a260791a9.

* Use fresh built sandbox image in integration test

* fix dependency

* DEBUG: only build

* Attempt to fix dependency

* Change dependency

* Combine both jobs

* Fix env

* Remove Mac integration tests as they are too unstable

* Move sandbox tests to ghcr

* Use loaded image
2024-06-19 01:44:51 +08:00
Graham Neubig
798921cec3 Codecov after_n_builds=5 (#2468)
* Codecov after_n_builds=2

* Update to 5
2024-06-17 04:40:12 +08:00
மனோஜ்குமார் பழனிச்சாமி
5e61a10627 Fixed typo in PR template (#2461) 2024-06-16 13:46:06 +00:00
மனோஜ்குமார் பழனிச்சாமி
b5b81d06a1 Added Pull Request Template (#2454) 2024-06-16 05:54:44 -04:00
மனோஜ்குமார் பழனிச்சாமி
003b599dd0 Issues Category Update: Removed Question Type (#2345)
We've removed the "Question" type from the Issues category to streamline our issue-tracking process. This change will help us focus on actionable issues and feature requests. If you have any questions or discussions, please use the Discussions tab. This is better suited for community engagement, sharing knowledge, and getting help from other contributors.
2024-06-09 21:14:56 -04:00
மனோஜ்குமார் பழனிச்சாமி
e0ad289483 Downgraded Python version to 3.12.3 (#2331)
Co-authored-by: Engel Nyst <enyst@users.noreply.github.com>
2024-06-09 11:54:30 +05:30