Skip to content
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

Fix build PR doc workflow #1269

Closed
wants to merge 4 commits into from
Closed
Show file tree
Hide file tree
Changes from all 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
14 changes: 14 additions & 0 deletions .github/workflows/build_pr_documentation.yml
Original file line number Diff line number Diff line change
@@ -1,15 +1,27 @@
name: Build PR documentation

# WARNING: As this workflow supports the pull_request_target event, please exercise extra care when editing it.

on:
pull_request:
branches: [ main ]
# pull_request_target:
# branches: [ main ]
# types: [ opened, synchronize, reopened, labeled ]

concurrency:
group: ${{ github.workflow }}-${{ github.head_ref || github.run_id }}
cancel-in-progress: true

jobs:
authorize:
if: (github.event.action == 'labeled' && github.event.label.name == 'build-pr-doc') || github.event_name != 'pull_request_target' || (! github.event.pull_request.head.repo.fork)
runs-on: ubuntu-latest
steps:
- run: true

build_documentation:
needs: authorize
runs-on: ubuntu-latest
env:
COMMIT_SHA: ${{ github.event.pull_request.head.sha }}
Expand All @@ -27,6 +39,7 @@ jobs:
with:
repository: 'huggingface/optimum'
path: optimum
ref: ${{ github.event.pull_request.merge_commit_sha }}

- uses: actions/checkout@v2
with:
Expand Down Expand Up @@ -87,6 +100,7 @@ jobs:
sudo apt update
sudo apt install -y ca-certificates apt-transport-https gnupg
sudo apt-key adv --keyserver keyserver.ubuntu.com --recv-key 5F03AFA423A751913F249259814F888B20B09A7E
# TODO: remove secrets and pull_request_target once archive.furiosa.ai is public
sudo tee -a /etc/apt/auth.conf.d/furiosa.conf > /dev/null <<EOT
machine archive.furiosa.ai
login ${{ secrets.FURIOSA_ACCESS_KEY }}
Expand Down
1 change: 1 addition & 0 deletions .github/workflows/test_exporters_gpu.yml
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,7 @@ on:

jobs:
start-runner:
if: ${{ (github.event_name == 'workflow_dispatch') || (github.event_name == 'schedule') || contains( github.event.pull_request.labels.*.name, 'gpu-test') }}
name: Start self-hosted EC2 runner
runs-on: ubuntu-latest
env:
Expand Down
2 changes: 2 additions & 0 deletions docs/source/quicktour.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,8 @@ specific language governing permissions and limitations under the License.

# Quick tour

Hey I did a change here!

This quick tour is intended for developers who are ready to dive into the code and see examples of how to integrate 🤗 Optimum into their model training and inference workflows.

## Accelerated inference
Expand Down
Loading