Skip to content

Commit

Permalink
Merge branch 'master' into christmas-support-2024
Browse files Browse the repository at this point in the history
  • Loading branch information
abigailbramble authored Dec 17, 2024
2 parents 0cf2253 + 219bad7 commit 9ceb7de
Show file tree
Hide file tree
Showing 972 changed files with 50,239 additions and 31,432 deletions.
3 changes: 3 additions & 0 deletions .eslintignore
Original file line number Diff line number Diff line change
@@ -1,2 +1,5 @@
.eslintrc.js
jest.config.ts
node_modules
rust
livestream
2 changes: 1 addition & 1 deletion .eslintrc.js
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ const globals = {
}

module.exports = {
ignorePatterns: ['node_modules', 'plugin-server'],
ignorePatterns: ['node_modules', 'plugin-server', 'rust', 'livestream'],
env,
settings: {
react: {
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/alert-on-failed-automerge.yml
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ on:
jobs:
notify_on_failure:
if: ${{ github.event.check_suite.conclusion == 'failure' }}
runs-on: ubuntu-latest
runs-on: ubuntu-24.04

steps:
- name: Checkout code
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/automerge.yml
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ on:
jobs:
automerge:
name: Automerge if requested
runs-on: ubuntu-latest
runs-on: ubuntu-24.04
env:
IS_POSTHOG_BOT_AVAILABLE: ${{ secrets.POSTHOG_BOT_GITHUB_TOKEN != '' }}
steps:
Expand Down
40 changes: 40 additions & 0 deletions .github/workflows/browserslist-update.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,40 @@
name: Update Browserslist database

on:
schedule:
- cron: '0 12 * * MON'
workflow_dispatch:

permissions:
contents: write
pull-requests: write

jobs:
update-browserslist-database:
runs-on: ubuntu-latest
steps:
- name: Checkout repository
uses: actions/checkout@v3
with:
fetch-depth: 0

- name: Configure git
run: |
git config --global user.email "[email protected]"
git config --global user.name "Browserslist Update Action"
- name: Install pnpm
uses: pnpm/action-setup@v4

- name: Set up Node.js
uses: actions/setup-node@v4
with:
node-version: 18.12.1

- name: Update Browserslist database and create PR if applies
uses: c2corg/browserslist-update-action@v2
with:
github_token: ${{ secrets.POSTHOG_BOT_GITHUB_TOKEN }} # This token has permission to open PRs
commit_message: 'build: update Browserslist db'
title: 'build: update Browserslist db'
labels: 'dependencies, automerge'
2 changes: 1 addition & 1 deletion .github/workflows/ci-backend-update-test-timing.yml
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ env:
jobs:
django:
name: Run Django tests and save test durations
runs-on: ubuntu-latest
runs-on: ubuntu-24.04
steps:
- uses: actions/checkout@v3

Expand Down
12 changes: 6 additions & 6 deletions .github/workflows/ci-backend.yml
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@ jobs:
# Job to decide if we should run backend ci
# See https://github.com/dorny/paths-filter#conditional-execution for more details
changes:
runs-on: ubuntu-latest
runs-on: ubuntu-24.04
timeout-minutes: 5
name: Determine need to run backend checks
# Set job outputs to values from filter step
Expand Down Expand Up @@ -94,7 +94,7 @@ jobs:
timeout-minutes: 30

name: Python code quality checks
runs-on: ubuntu-latest
runs-on: ubuntu-24.04

steps:
# If this run wasn't initiated by the bot (meaning: snapshot update) and we've determined
Expand Down Expand Up @@ -153,7 +153,7 @@ jobs:
timeout-minutes: 10

name: Validate Django and CH migrations
runs-on: ubuntu-latest
runs-on: ubuntu-24.04

steps:
- uses: actions/checkout@v3
Expand Down Expand Up @@ -228,7 +228,7 @@ jobs:
timeout-minutes: 30

name: Django tests – ${{ matrix.segment }} (persons-on-events ${{ matrix.person-on-events && 'on' || 'off' }}), Py ${{ matrix.python-version }}, ${{ matrix.clickhouse-server-image }} (${{matrix.group}}/${{ matrix.concurrency }})
runs-on: ubuntu-latest
runs-on: ubuntu-24.04

strategy:
fail-fast: false
Expand Down Expand Up @@ -328,7 +328,7 @@ jobs:
matrix:
clickhouse-server-image: ['clickhouse/clickhouse-server:24.8.7.41']
if: needs.changes.outputs.backend == 'true'
runs-on: ubuntu-latest
runs-on: ubuntu-24.04
steps:
- name: 'Checkout repo'
uses: actions/checkout@v3
Expand Down Expand Up @@ -382,7 +382,7 @@ jobs:
calculate-running-time:
name: Calculate running time
needs: [django, async-migrations]
runs-on: ubuntu-latest
runs-on: ubuntu-24.04
if: # Run on pull requests to PostHog/posthog + on PostHog/posthog outside of PRs - but never on forks
needs.changes.outputs.backend == 'true' &&
(
Expand Down
10 changes: 5 additions & 5 deletions .github/workflows/ci-e2e.yml
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ concurrency:

jobs:
changes:
runs-on: ubuntu-latest
runs-on: ubuntu-24.04
timeout-minutes: 5
name: Determine need to run E2E checks
# Set job outputs to values from filter step
Expand Down Expand Up @@ -53,7 +53,7 @@ jobs:
chunks:
needs: changes
name: Cypress preparation
runs-on: ubuntu-latest
runs-on: ubuntu-24.04
timeout-minutes: 5
outputs:
chunks: ${{ steps.chunk.outputs.chunks }}
Expand All @@ -67,7 +67,7 @@ jobs:

container:
name: Build and cache container image
runs-on: ubuntu-latest
runs-on: ubuntu-24.04
timeout-minutes: 60
needs: [changes]
permissions:
Expand All @@ -91,7 +91,7 @@ jobs:

cypress:
name: Cypress E2E tests (${{ strategy.job-index }})
runs-on: ubuntu-latest
runs-on: ubuntu-24.04
timeout-minutes: 60
needs: [chunks, changes, container]
permissions:
Expand Down Expand Up @@ -279,7 +279,7 @@ jobs:

calculate-running-time:
name: Calculate running time
runs-on: ubuntu-latest
runs-on: ubuntu-24.04
needs: [cypress]
if: needs.changes.outputs.shouldTriggerCypress == 'true' &&
github.event.pull_request.head.repo.full_name == 'PostHog/posthog'
Expand Down
6 changes: 3 additions & 3 deletions .github/workflows/ci-frontend.yml
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ jobs:
# we skip each step individually, so they are still reported as success
# because many of them are required for CI checks to be green
changes:
runs-on: ubuntu-latest
runs-on: ubuntu-24.04
timeout-minutes: 5
name: Determine need to run frontend checks
outputs:
Expand Down Expand Up @@ -54,7 +54,7 @@ jobs:
name: Code quality checks
needs: changes
# kea typegen and typescript:check need some more oomph
runs-on: ubuntu-latest
runs-on: ubuntu-24.04
steps:
# we need at least one thing to run to make sure we include everything for required jobs
- uses: actions/checkout@v3
Expand Down Expand Up @@ -121,7 +121,7 @@ jobs:
minimum-change-threshold: 1000

jest:
runs-on: ubuntu-latest
runs-on: ubuntu-24.04
needs: changes
name: Jest test (${{ matrix.segment }} - ${{ matrix.chunk }})

Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/ci-hobby.yml
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ concurrency:

jobs:
changes:
runs-on: ubuntu-latest
runs-on: ubuntu-24.04
# this is a slow one
timeout-minutes: 30
name: Setup DO Hobby Instance and test
Expand Down
Loading

0 comments on commit 9ceb7de

Please sign in to comment.