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

remove GHA, allow-failure is not currently supported #734

Merged
merged 1 commit into from
Sep 2, 2020

Conversation

iliabylich
Copy link
Collaborator

No description provided.

@iliabylich iliabylich changed the title Configure GitHub Actions (based on #733) migrate to GH actions Sep 2, 2020
@iliabylich
Copy link
Collaborator Author

@palkan ok, it seems to be working now

@palkan
Copy link
Contributor

palkan commented Sep 2, 2020

🎉

@iliabylich iliabylich force-pushed the add-gh-action-config branch 3 times, most recently from 339a823 to 7ae328c Compare September 2, 2020 13:20
@iliabylich
Copy link
Collaborator Author

Interesting. GH actions doesn't support "allow_failure" option (here's a tracking issue - actions/runner#2347), and so if rubocop/master or ruby-head are broken we get failure for the whole PR.

I'm not sure if that's the right strategy. Many commits will be marked as red because atm rubocop does require 'parser/ruby28' that doesn't exist anymore. PR is marked as red and all commits in the history will be red too.

I don't see any options except removing .github directory and waiting for actions/runner#2347 to be resolved.

@iliabylich iliabylich changed the title migrate to GH actions removed GHA, allow-failure is not currently supported Sep 2, 2020
@iliabylich iliabylich changed the title removed GHA, allow-failure is not currently supported remove GHA, allow-failure is not currently supported Sep 2, 2020
@iliabylich
Copy link
Collaborator Author

I've removed .github directory

Latest .github/workflows/test.yml
name: Tests

on:
  push:
    branches:
    - master
  pull_request:

jobs:
  test:
    runs-on: ubuntu-latest
    env:
      BUNDLE_JOBS: 4
      BUNDLE_RETRY: 3
      CI: true
      TRUFFLERUBYOPT: "--engine.Mode=latency"
    continue-on-error: ${{ matrix.allow_failure }}
    strategy:
      fail-fast: false
      matrix:
        ruby: ["2.4.10", "2.5.8", "2.6.6", "2.7.1", "jruby-9.2", "truffleruby"]
        test_command: ["bundle exec rake test"]
        allow_failure: [false]
        include:
          - ruby: "head"
            test_command: "bundle exec rake test"
            allow_failure: true
          - ruby: "2.7.1"
            test_command: "./ci/run_rubocop_specs"
            allow_failure: true
    steps:
    - uses: actions/checkout@v2
    - uses: actions/cache@v1
      with:
        path: /home/runner/bundle
        key: bundle-${{ matrix.ruby }}-${{ hashFiles('../Gemfile') }}-${{ hashFiles('**/*.gemspec') }}
        restore-keys: |
          bundle-${{ matrix.ruby }}-
    - uses: ruby/setup-ruby@v1
      with:
        ruby-version: ${{ matrix.ruby }}
    - name: Install Ragel
      run: |
        sudo apt-get update
        sudo apt-get install ragel
    - name: Bundle install
      run: |
        bundle config path /home/runner/bundle
        bundle install
        bundle update
    - name: Run tests
      run: |
        ${{ matrix.test_command }}

@iliabylich iliabylich merged commit e0dd69d into whitequark:master Sep 2, 2020
@iliabylich iliabylich deleted the add-gh-action-config branch September 2, 2020 14:07
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