Skip to content
Merged
Show file tree
Hide file tree
Changes from 3 commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
9 changes: 0 additions & 9 deletions .devcontainer/Dockerfile

This file was deleted.

43 changes: 0 additions & 43 deletions .devcontainer/devcontainer.json

This file was deleted.

6 changes: 6 additions & 0 deletions .fernignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
# Specify files that shouldn't be modified by Fern
.gitignore
.vscode/

src/browser_use/client.py
src/browser_use/wrapper/
117 changes: 28 additions & 89 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
@@ -1,98 +1,37 @@
name: CI
on:
push:
branches-ignore:
- 'generated'
- 'codegen/**'
- 'integrated/**'
- 'stl-preview-head/**'
- 'stl-preview-base/**'
pull_request:
branches-ignore:
- 'stl-preview-head/**'
- 'stl-preview-base/**'
name: ci

on: [push]
jobs:
lint:
timeout-minutes: 10
name: lint
runs-on: ${{ github.repository == 'stainless-sdks/browser-use-python' && 'depot-ubuntu-24.04' || 'ubuntu-latest' }}
if: github.event_name == 'push' || github.event.pull_request.head.repo.fork
compile:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4

- name: Install Rye
run: |
curl -sSf https://rye.astral.sh/get | bash
echo "$HOME/.rye/shims" >> $GITHUB_PATH
env:
RYE_VERSION: '0.44.0'
RYE_INSTALL_OPTION: '--yes'

- name: Install dependencies
run: rye sync --all-features

- name: Run lints
run: ./scripts/lint

build:
if: github.event_name == 'push' || github.event.pull_request.head.repo.fork
timeout-minutes: 10
name: build
permissions:
contents: read
id-token: write
runs-on: depot-ubuntu-24.04
steps:
- uses: actions/checkout@v4

- name: Install Rye
- name: Checkout repo
uses: actions/checkout@v4
- name: Set up python
uses: actions/setup-python@v4
with:
python-version: 3.8
- name: Bootstrap poetry
run: |
curl -sSf https://rye.astral.sh/get | bash
echo "$HOME/.rye/shims" >> $GITHUB_PATH
env:
RYE_VERSION: '0.44.0'
RYE_INSTALL_OPTION: '--yes'

curl -sSL https://install.python-poetry.org | python - -y --version 1.5.1
- name: Install dependencies
run: rye sync --all-features

- name: Run build
run: rye build

- name: Get GitHub OIDC Token
if: github.repository == 'stainless-sdks/browser-use-python'
id: github-oidc
uses: actions/github-script@v6
with:
script: core.setOutput('github_token', await core.getIDToken());

- name: Upload tarball
if: github.repository == 'stainless-sdks/browser-use-python'
env:
URL: https://pkg.stainless.com/s
AUTH: ${{ steps.github-oidc.outputs.github_token }}
SHA: ${{ github.sha }}
run: ./scripts/utils/upload-artifact.sh

run: poetry install
- name: Compile
run: poetry run mypy .
test:

Check warning

Code scanning / CodeQL

Workflow does not contain permissions Medium

Actions job or workflow does not limit the permissions of the GITHUB_TOKEN. Consider setting an explicit permissions block, using the following as a minimal starting point: {contents: read}
timeout-minutes: 10
name: test
runs-on: ${{ github.repository == 'stainless-sdks/browser-use-python' && 'depot-ubuntu-24.04' || 'ubuntu-latest' }}
if: github.event_name == 'push' || github.event.pull_request.head.repo.fork
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4

- name: Install Rye
- name: Checkout repo
uses: actions/checkout@v4
- name: Set up python
uses: actions/setup-python@v4
with:
python-version: 3.8
- name: Bootstrap poetry
run: |
curl -sSf https://rye.astral.sh/get | bash
echo "$HOME/.rye/shims" >> $GITHUB_PATH
env:
RYE_VERSION: '0.44.0'
RYE_INSTALL_OPTION: '--yes'

- name: Bootstrap
run: ./scripts/bootstrap
curl -sSL https://install.python-poetry.org | python - -y --version 1.5.1
- name: Install dependencies
run: poetry install

- name: Run tests
run: ./scripts/test
- name: Test
run: poetry run pytest -rP .
Comment on lines +22 to +37

Check warning

Code scanning / CodeQL

Workflow does not contain permissions Medium

Actions job or workflow does not limit the permissions of the GITHUB_TOKEN. Consider setting an explicit permissions block, using the following as a minimal starting point: {contents: read}

Copilot Autofix

AI 29 days ago

To fix the problem, explicitly specify the minimal required permissions for the workflow or for each job by adding a permissions block. For these jobs, contents: read is sufficient, as none of the actions require write access to the repository or other resource types. The most concise and maintainable method is to add a top-level permissions block immediately after the name and before on, which will apply the permission restriction to all jobs unless overridden.
Edit .github/workflows/ci.yml to insert:

permissions:
  contents: read

after the name: ci line and before on: [push]. No other code or dependencies are needed.

Suggested changeset 1
.github/workflows/ci.yml

Autofix patch

Autofix patch
Run the following command in your local git repository to apply this patch
cat << 'EOF' | git apply
diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml
--- a/.github/workflows/ci.yml
+++ b/.github/workflows/ci.yml
@@ -1,4 +1,6 @@
 name: ci
+permissions:
+  contents: read
 
 on: [push]
 jobs:
EOF
@@ -1,4 +1,6 @@
name: ci
permissions:
contents: read

on: [push]
jobs:
Copilot is powered by AI and may make mistakes. Always verify output.
31 changes: 0 additions & 31 deletions .github/workflows/publish-pypi.yml

This file was deleted.

21 changes: 0 additions & 21 deletions .github/workflows/release-doctor.yml

This file was deleted.

23 changes: 8 additions & 15 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,15 +1,8 @@
.prism.log
_dev

__pycache__
.mypy_cache

dist

.venv
.idea

.env
.envrc
codegen.log
Brewfile.lock.json
.mypy_cache/
.ruff_cache/
__pycache__/
dist/
poetry.toml

.env*
!.env.example
1 change: 0 additions & 1 deletion .python-version

This file was deleted.

3 changes: 0 additions & 3 deletions .release-please-manifest.json

This file was deleted.

4 changes: 0 additions & 4 deletions .stats.yml

This file was deleted.

6 changes: 5 additions & 1 deletion .vscode/settings.json
Original file line number Diff line number Diff line change
@@ -1,3 +1,7 @@
{
"python.analysis.importFormat": "relative",
"python.analysis.importFormat": "relative",
"editor.codeActionsOnSave": {
"source.organizeImports": "always",
"source.fixAll.ruff": "always"
}
}
2 changes: 0 additions & 2 deletions Brewfile

This file was deleted.

68 changes: 0 additions & 68 deletions CHANGELOG.md

This file was deleted.

Loading
Loading