-
Notifications
You must be signed in to change notification settings - Fork 59
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #8 from ServiceNow/pre-release
v0.2.0
- Loading branch information
Showing
55 changed files
with
2,236 additions
and
603 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,188 @@ | ||
name: Unit tests | ||
|
||
on: | ||
push: | ||
branches: | ||
- main | ||
pull_request: | ||
|
||
jobs: | ||
|
||
code-format: | ||
runs-on: ubuntu-latest | ||
|
||
defaults: | ||
run: | ||
shell: bash -l {0} | ||
|
||
steps: | ||
|
||
- name: Checkout Repository | ||
uses: actions/checkout@v4 | ||
|
||
- name: Set up Python | ||
uses: actions/setup-python@v5 | ||
with: | ||
python-version: '3.10' | ||
cache: 'pip' # caching pip dependencies | ||
|
||
- name: Pip install | ||
run: pip install black[jupyter]==24.2.0 blacken-docs | ||
|
||
- name: Code Formatting | ||
run: black . --check | ||
|
||
browsergym-core: | ||
runs-on: ubuntu-latest | ||
|
||
defaults: | ||
run: | ||
shell: bash -l {0} | ||
|
||
steps: | ||
|
||
- name: Checkout Repository | ||
uses: actions/checkout@v4 | ||
|
||
- name: Set up Python | ||
uses: actions/setup-python@v5 | ||
with: | ||
python-version: '3.10' | ||
cache: 'pip' # caching pip dependencies | ||
|
||
- name: Pip install | ||
working-directory: ./dev | ||
run: pip install -r requirements.txt | ||
|
||
- name: Pip list | ||
run: pip list | ||
|
||
- name: Install Playwright | ||
run: playwright install --with-deps | ||
|
||
- name: Run browsergym-core Unit Tests | ||
run: pytest -n 1 --durations=10 -m 'not pricy' -v core/tests | ||
|
||
browsergym-miniwob: | ||
runs-on: ubuntu-latest | ||
|
||
defaults: | ||
run: | ||
shell: bash -l {0} | ||
|
||
steps: | ||
|
||
- name: Checkout Repository | ||
uses: actions/checkout@v4 | ||
|
||
- name: Set up Python | ||
uses: actions/setup-python@v5 | ||
with: | ||
python-version: '3.10' | ||
cache: 'pip' # caching pip dependencies | ||
|
||
- name: Pip install | ||
working-directory: ./dev | ||
run: pip install -r requirements.txt | ||
|
||
- name: Pip list | ||
run: pip list | ||
|
||
- name: Install Playwright | ||
run: playwright install --with-deps | ||
|
||
- name: Fetch MiniWob | ||
uses: actions/checkout@v4 | ||
with: | ||
repository: "Farama-Foundation/miniwob-plusplus" | ||
ref: "7fd85d71a4b60325c6585396ec4f48377d049838" | ||
path: "miniwob-plusplus" | ||
|
||
- name: Serve MiniWob | ||
uses: Eun/http-server-action@v1 | ||
with: | ||
directory: "${{ github.workspace }}/miniwob-plusplus/miniwob/html" | ||
port: 8080 | ||
|
||
- name: Run browsergym-miniwob Unit Tests | ||
env: | ||
MINIWOB_URL: "http://localhost:8080/miniwob/" | ||
run: pytest -n 5 --durations=10 -m 'not pricy' -v miniwob/tests | ||
|
||
browsergym-webarena-fast: | ||
runs-on: ubuntu-latest | ||
|
||
defaults: | ||
run: | ||
shell: bash -l {0} | ||
|
||
steps: | ||
- name: Checkout Repository | ||
uses: actions/checkout@v4 | ||
|
||
- name: Set up Python | ||
uses: actions/setup-python@v5 | ||
with: | ||
python-version: '3.10' | ||
cache: 'pip' # caching pip dependencies | ||
|
||
- name: Pip install | ||
working-directory: ./dev | ||
run: pip install -r requirements.txt | ||
|
||
- name: Pip list | ||
run: pip list | ||
|
||
- name: Install Playwright | ||
run: playwright install --with-deps | ||
|
||
- name: Run browsergym-webarena not slow Unit Tests | ||
env: | ||
SHOPPING: "http://ec2-3-131-244-37.us-east-2.compute.amazonaws.com:7770/" | ||
SHOPPING_ADMIN: "http://ec2-3-131-244-37.us-east-2.compute.amazonaws.com:7780/admin" | ||
REDDIT: "http://ec2-3-131-244-37.us-east-2.compute.amazonaws.com:9999" | ||
GITLAB: "http://ec2-3-131-244-37.us-east-2.compute.amazonaws.com:8023" | ||
WIKIPEDIA: "http://ec2-3-131-244-37.us-east-2.compute.amazonaws.com:8888/wikipedia_en_all_maxi_2022-05/A/User:The_other_Kiwix_guy/Landing" | ||
MAP: "http://ec2-3-131-244-37.us-east-2.compute.amazonaws.com:3000" | ||
HOMEPAGE: "PASS:4399" | ||
WEBARENA_PATH: "${{ github.workspace }}/webarena/" | ||
run: pytest -n 5 --durations=10 -m 'not slow and not pricy' --slowmo 1000 -v webarena/tests | ||
|
||
browsergym-webarena-slow: | ||
runs-on: ubuntu-latest | ||
|
||
defaults: | ||
run: | ||
shell: bash -l {0} | ||
|
||
steps: | ||
- name: Checkout Repository | ||
uses: actions/checkout@v4 | ||
|
||
- name: Set up Python | ||
uses: actions/setup-python@v5 | ||
with: | ||
python-version: '3.10' | ||
cache: 'pip' # caching pip dependencies | ||
|
||
- name: Pip install | ||
working-directory: ./dev | ||
run: pip install -r requirements.txt | ||
|
||
- name: Pip list | ||
run: pip list | ||
|
||
- name: Install Playwright | ||
run: playwright install --with-deps | ||
|
||
- name: Run browsergym-webarena slow Unit Tests | ||
env: | ||
SHOPPING: "http://ec2-3-131-244-37.us-east-2.compute.amazonaws.com:7770/" | ||
SHOPPING_ADMIN: "http://ec2-3-131-244-37.us-east-2.compute.amazonaws.com:7780/admin" | ||
REDDIT: "http://ec2-3-131-244-37.us-east-2.compute.amazonaws.com:9999" | ||
GITLAB: "http://ec2-3-131-244-37.us-east-2.compute.amazonaws.com:8023" | ||
WIKIPEDIA: "http://ec2-3-131-244-37.us-east-2.compute.amazonaws.com:8888/wikipedia_en_all_maxi_2022-05/A/User:The_other_Kiwix_guy/Landing" | ||
MAP: "http://ec2-3-131-244-37.us-east-2.compute.amazonaws.com:3000" | ||
HOMEPAGE: "PASS:4399" | ||
WEBARENA_PATH: "${{ github.workspace }}/webarena/" | ||
run: pytest -n 5 --durations=10 -m 'slow and not pricy' --slowmo 1000 -v webarena/tests |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1 +1,3 @@ | ||
.DS_store | ||
.DS_store | ||
__pycache__/ | ||
*.py[cod] |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,44 @@ | ||
fail_fast: false | ||
|
||
default_language_version: | ||
python: python3 | ||
|
||
repos: | ||
- repo: https://github.com/pre-commit/pre-commit-hooks | ||
rev: v4.2.0 | ||
hooks: | ||
- id: trailing-whitespace | ||
exclude: ^(.*)\.md$ | ||
- id: end-of-file-fixer | ||
- id: check-yaml | ||
exclude: ^(.circleci/recipe|recipe) # conda build recipes are templated | ||
- id: check-added-large-files | ||
- repo: https://github.com/pocc/pre-commit-hooks | ||
rev: v1.1.1 | ||
hooks: | ||
- id: clang-format | ||
args: [--style=file, -i] | ||
- id: clang-tidy | ||
args: [--fix, --fix-errors] | ||
- repo: https://github.com/psf/black | ||
rev: 24.2.0 | ||
hooks: | ||
- id: black | ||
args: [--config=./pyproject.toml] | ||
- repo: https://github.com/asottile/blacken-docs | ||
rev: v1.12.1 | ||
hooks: | ||
- id: blacken-docs | ||
args: [ '--line-length', '100' ] | ||
additional_dependencies: [black] | ||
- repo: https://github.com/Lucas-C/pre-commit-hooks | ||
rev: v1.5.5 | ||
hooks: | ||
- id: forbid-crlf | ||
- id: remove-crlf | ||
# Black does not clear tabs in docstrings | ||
- id: forbid-tabs | ||
files: '.*\.py$' | ||
- id: remove-tabs | ||
files: '.*\.py$' | ||
args: [ '--whitespaces-count', '4' ] |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,4 @@ | ||
__version__ = "0.1.0rc7" | ||
__version__ = "0.2.0" | ||
|
||
import playwright.sync_api | ||
|
||
|
Empty file.
Oops, something went wrong.