Skip to content

Commit

Permalink
Merge branch 'main' into 1519-feat-conditionally-required-settings
Browse files Browse the repository at this point in the history
  • Loading branch information
edgarrmondragon committed Feb 6, 2025
2 parents 590e22b + 61a0b88 commit f6824d8
Show file tree
Hide file tree
Showing 113 changed files with 4,315 additions and 4,602 deletions.
2 changes: 1 addition & 1 deletion .github/ISSUE_TEMPLATE/bug.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ body:
attributes:
label: Singer SDK Version
description: Version of the library you are using
placeholder: "0.43.1"
placeholder: "0.44.3"
validations:
required: true
- type: checkboxes
Expand Down
6 changes: 6 additions & 0 deletions .github/ISSUE_TEMPLATE/config.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,3 +3,9 @@ contact_links:
- name: Meltano Community
url: https://meltano.com/slack
about: Join us on Slack.
- name: Start a discussion
url: https://github.com/meltano/sdk/discussions/new
about: Start a GitHub discussion.
- name: Singer SDK Documentation
url: https://sdk.meltano.com
about: Learn more about the Singer SDK.
2 changes: 1 addition & 1 deletion .github/dependabot.yml
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ updates:
- "patch"
versioning-strategy: increase-if-necessary
- package-ecosystem: pip
directory: "/.github/workflows"
directory: "/.github/workflows/resources"
schedule:
interval: weekly
time: "12:00"
Expand Down
16 changes: 11 additions & 5 deletions .github/workflows/api-changes.yml
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,11 @@ concurrency:
group: ${{ github.workflow }}-${{ github.head_ref || github.run_id }}
cancel-in-progress: true

env:
FORCE_COLOR: 1
UV_CONSTRAINT: ${{ github.workspace }}/.github/workflows/resources/requirements.txt
UV_VERSION: 0.5.26

permissions: # added using https://github.com/step-security/secure-repo
contents: read

Expand All @@ -32,13 +37,14 @@ jobs:
with:
python-version: 3.x

- uses: astral-sh/setup-uv@v5
with:
version: ${{ env.UV_VERSION }}

- name: Install tools
env:
PIP_CONSTRAINT: ${{ github.workspace }}/.github/workflows/constraints.txt
run: |
python -Im pip install -U pip
pipx install griffe nox
pipx list
uv tool install nox
uv tool list
- name: Set REF
id: set-ref
Expand Down
25 changes: 10 additions & 15 deletions .github/workflows/codspeed.yml
Original file line number Diff line number Diff line change
Expand Up @@ -9,16 +9,16 @@ on:
- "singer_sdk/**"
- "tests/**"
- "noxfile.py"
- "poetry.lock"
- "pyproject.toml"
- "uv.lock"
- ".github/workflows/codspeed.yml"
pull_request:
paths:
- "singer_sdk/**"
- "tests/**"
- "noxfile.py"
- "poetry.lock"
- "pyproject.toml"
- "uv.lock"
- ".github/workflows/codspeed.yml"
# `workflow_dispatch` allows CodSpeed to trigger backtest
# performance analysis in order to generate initial data.
Expand All @@ -41,20 +41,15 @@ jobs:
python-version: 3.x
architecture: x64

- name: Install poetry
run: |
curl -fsS https://install.python-poetry.org | python - -y
- name: Configure poetry
run: poetry config virtualenvs.create false
- name: Install uv
uses: astral-sh/setup-uv@v5
with:
version: ">=0.5.19"

- name: Install project
run: >
poetry install
-vvv
--with dev
--with benchmark
--all-extras
- name: Install dependencies
run: |
uv export --no-hashes --frozen --all-extras --group benchmark -o requirements.txt
uv pip install --system -r requirements.txt
- uses: CodSpeedHQ/action@v3
with:
Expand Down
5 changes: 0 additions & 5 deletions .github/workflows/constraints.txt

This file was deleted.

31 changes: 8 additions & 23 deletions .github/workflows/cookiecutter-e2e.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@ on:
pull_request:
types: [opened, synchronize, reopened]
paths:
- noxfile.py
- "cookiecutter/**"
- "e2e-tests/cookiecutters/**"
- ".github/workflows/cookiecutter-e2e.yml"
Expand All @@ -12,6 +13,7 @@ on:
- main
- v*
paths:
- noxfile.py
- "cookiecutter/**"
- "e2e-tests/cookiecutters/**"
- ".github/workflows/cookiecutter-e2e.yml"
Expand All @@ -23,43 +25,26 @@ concurrency:

env:
FORCE_COLOR: "1"
UV_CONSTRAINT: ${{ github.workspace }}/.github/workflows/resources/requirements.txt

jobs:
lint:
name: Cookiecutter E2E Python
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Upgrade pip
env:
PIP_CONSTRAINT: ${{ github.workspace }}/.github/workflows/constraints.txt
run: |
pip install pip
pip --version
- name: Install Poetry
env:
PIP_CONSTRAINT: ${{ github.workspace }}/.github/workflows/constraints.txt
run: |
pipx install poetry
poetry --version
- uses: actions/setup-python@v5
with:
python-version: 3.x
fetch-depth: 0

- uses: astral-sh/setup-uv@v5
with:
version: ">=0.4.30"
version: ">=0.5.19"

- name: Install pre-commit
run: |
uv tool install --with=pre-commit-uv pre-commit
pre-commit --version
- uses: actions/setup-python@v5
with:
python-version: 3.x

- name: Install Nox
env:
PIP_CONSTRAINT: ${{ github.workspace }}/.github/workflows/constraints.txt
run: |
uv tool install nox
nox --version
Expand Down
7 changes: 5 additions & 2 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -7,11 +7,14 @@ jobs:
build:
name: Build artifacts
runs-on: ubuntu-latest
outputs:
version: ${{ steps.baipp.outputs.package_version }}
steps:
- uses: actions/checkout@v4
with:
fetch-depth: 0
- uses: hynek/build-and-inspect-python-package@v2
id: baipp

check-tag:
name: Check tag
Expand Down Expand Up @@ -55,7 +58,7 @@ jobs:
needs: [build]
environment:
name: publishing
url: https://pypi.org/p/singer-sdk
url: https://pypi.org/project/singer-sdk/${{ needs.build.outputs.version }}
if: startsWith(github.ref, 'refs/tags/')
permissions:
id-token: write # Needed for OIDC PyPI publishing
Expand All @@ -65,7 +68,7 @@ jobs:
name: Packages
path: dist
- name: Publish
uses: pypa/[email protected].3
uses: pypa/[email protected].4

upload-to-release:
name: Upload files to release
Expand Down
4 changes: 4 additions & 0 deletions .github/workflows/resources/requirements.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
griffe~=1.5
nox==2024.10.9
pre-commit==4.1.0
twine==6.1.0
59 changes: 21 additions & 38 deletions .github/workflows/test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,29 +4,27 @@ on:
pull_request:
types: [opened, synchronize, reopened]
paths:
- "cookiecutter/**"
- "samples/**"
- "singer_sdk/**"
- "tests/**"
- "noxfile.py"
- "poetry.lock"
- "pyproject.toml"
- "uv.lock"
- ".github/workflows/test.yml"
- ".github/workflows/constraints.txt"
- ".github/workflows/resources/requirements.txt"
push:
branches:
- main
- v*
paths:
- "cookiecutter/**"
- "samples/**"
- "singer_sdk/**"
- "tests/**"
- "noxfile.py"
- "poetry.lock"
- "pyproject.toml"
- "uv.lock"
- ".github/workflows/test.yml"
- ".github/workflows/constraints.txt"
- ".github/workflows/resources/requirements.txt"
workflow_dispatch:
inputs: {}

Expand All @@ -36,6 +34,8 @@ concurrency:

env:
FORCE_COLOR: "1"
UV_CONSTRAINT: ${{ github.workspace }}/.github/workflows/resources/requirements.txt
UV_VERSION: 0.5.26

jobs:
tests:
Expand Down Expand Up @@ -71,29 +71,23 @@ jobs:
python-version: ${{ matrix.python-version }}
allow-prereleases: true

- name: Upgrade pip
env:
PIP_CONSTRAINT: ${{ github.workspace }}/.github/workflows/constraints.txt
run: |
pip install pip
pip --version
- uses: astral-sh/setup-uv@v5
with:
version: ${{ env.UV_VERSION }}

- name: Install Nox
env:
PIP_CONSTRAINT: ${{ github.workspace }}/.github/workflows/constraints.txt
run: |
pipx install 'nox[uv]'
uv tool install 'nox[uv]'
nox --version
- uses: actions/cache@v4
if: matrix.session == 'tests'
with:
path: http_cache.sqlite
key: http_cache-${{ runner.os }}-${{ matrix.python-version }}-${{ matrix.sqlalchemy }}
key: http_cache-${{ runner.os }}-${{ matrix.python-version }}

- name: Run Nox
env:
PIP_PRE: "1"
UV_PRERELEASE: allow
run: |
nox --verbose
Expand All @@ -102,7 +96,7 @@ jobs:
if: always() && (matrix.session == 'tests')
with:
include-hidden-files: true
name: coverage-data-nox_-${{ matrix.os }}-py${{ matrix.python-version }}_sqlalchemy_${{ matrix.sqlalchemy }}
name: coverage-data-nox_-${{ matrix.os }}-py${{ matrix.python-version }}
path: ".coverage.*"

tests-external:
Expand All @@ -126,23 +120,17 @@ jobs:
with:
python-version: ${{ env.NOXPYTHON }}

- name: Upgrade pip
env:
PIP_CONSTRAINT: ${{ github.workspace }}/.github/workflows/constraints.txt
run: |
pip install pip
pip --version
- uses: astral-sh/setup-uv@v5
with:
version: ${{ env.UV_VERSION }}

- name: Install Nox
env:
PIP_CONSTRAINT: ${{ github.workspace }}/.github/workflows/constraints.txt
run: |
pipx install 'nox[uv]'
uv tool install 'nox[uv]'
nox --version
- name: Run Nox
env:
PIP_PRE: "1"
UV_PRERELEASE: allow
run: |
nox -- -m "external"
Expand All @@ -159,23 +147,18 @@ jobs:
with:
python-version: '3.x'

- name: Upgrade pip
env:
PIP_CONSTRAINT: ${{ github.workspace }}/.github/workflows/constraints.txt
run: |
pip install pip
pip --version
- uses: actions/download-artifact@v4
with:
pattern: coverage-data-*
merge-multiple: true

- uses: astral-sh/setup-uv@v5
with:
version: ${{ env.UV_VERSION }}

- name: Install Nox
env:
PIP_CONSTRAINT: ${{ github.workspace }}/.github/workflows/constraints.txt
run: |
pipx install 'nox[uv]'
uv tool install 'nox[uv]'
nox --version
- run: nox --install-only
Expand Down
Loading

0 comments on commit f6824d8

Please sign in to comment.