Skip to content

Commit b3ba6e6

Browse files
refactor: Rebuild from cookiecutter (#104)
* rebuild from cookiecutter * add more streams back after testing * video ads and fix pks * refactor unescaped params and add first analytics stream * analytics creative stream * sort streams by name * refresh poetry and readme * [pre-commit.ci] auto fixes from pre-commit.com hooks for more information, see https://pre-commit.ci * fix account users stream * rename to unencoded and add doc string * use private convention on intermediate streams * directory refactor and reuse, manual date filtering * [pre-commit.ci] auto fixes from pre-commit.com hooks for more information, see https://pre-commit.ci * use incremental streams and bookmarks * [pre-commit.ci] auto fixes from pre-commit.com hooks for more information, see https://pre-commit.ci * pre commit fixes * ad analytics to full table replication for now * missing replication fields for creatives --------- Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
1 parent e811092 commit b3ba6e6

32 files changed

+2946
-2963
lines changed

.env.template

Lines changed: 0 additions & 6 deletions
This file was deleted.

.github/dependabot.yml

Lines changed: 18 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -8,19 +8,34 @@ updates:
88
- package-ecosystem: pip
99
directory: "/"
1010
schedule:
11-
interval: "daily"
11+
interval: weekly
1212
commit-message:
1313
prefix: "chore(deps): "
1414
prefix-development: "chore(deps-dev): "
15+
groups:
16+
development-dependencies:
17+
dependency-type: development
18+
runtime-dependencies:
19+
dependency-type: production
20+
update-types:
21+
- "patch"
1522
- package-ecosystem: pip
1623
directory: "/.github/workflows"
1724
schedule:
18-
interval: daily
25+
interval: weekly
1926
commit-message:
2027
prefix: "ci: "
28+
groups:
29+
ci:
30+
patterns:
31+
- "*"
2132
- package-ecosystem: github-actions
2233
directory: "/"
2334
schedule:
24-
interval: "weekly"
35+
interval: weekly
2536
commit-message:
2637
prefix: "ci: "
38+
groups:
39+
actions:
40+
patterns:
41+
- "*"

.github/workflows/build.yml

Lines changed: 45 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,45 @@
1+
name: Release
2+
3+
on:
4+
push:
5+
6+
permissions:
7+
contents: write # Needed to upload artifacts to the release
8+
id-token: write # Needed for OIDC PyPI publishing
9+
10+
jobs:
11+
build:
12+
runs-on: ubuntu-latest
13+
steps:
14+
- uses: actions/checkout@v4
15+
with:
16+
fetch-depth: 0
17+
- uses: hynek/build-and-inspect-python-package@v2
18+
19+
publish:
20+
name: Publish to PyPI
21+
runs-on: ubuntu-latest
22+
needs: [build]
23+
## TODO: optionally provide the name of the environment for the trusted
24+
## publisher on PyPI
25+
## https://docs.github.com/en/actions/deployment/targeting-different-environments/using-environments-for-deployment
26+
# environment: pypi
27+
if: startsWith(github.ref, 'refs/tags/')
28+
steps:
29+
- uses: actions/download-artifact@v4
30+
with:
31+
name: Packages
32+
path: dist
33+
- name: Upload wheel to release
34+
uses: svenstaro/upload-release-action@v2
35+
with:
36+
repo_token: ${{secrets.GITHUB_TOKEN}}
37+
file: dist/*.whl
38+
tag: ${{github.ref}}
39+
overwrite: true
40+
file_glob: true
41+
42+
- name: Publish
43+
## TODO: create a trusted publisher on PyPI
44+
## https://docs.pypi.org/trusted-publishers/
45+
uses: pypa/[email protected]

.github/workflows/ci_workflow.yml

Lines changed: 0 additions & 48 deletions
This file was deleted.

.github/workflows/constraints.txt

Lines changed: 0 additions & 5 deletions
This file was deleted.

.github/workflows/release.yaml

Lines changed: 0 additions & 51 deletions
This file was deleted.

.github/workflows/test.yml

Lines changed: 50 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,50 @@
1+
### A CI workflow template that runs linting and python testing
2+
### TODO: Modify as needed or as desired.
3+
4+
name: Test tap-linkedin-ads
5+
6+
on:
7+
push:
8+
branches: [main]
9+
paths:
10+
- .github/workflows/test.yml
11+
- tap_linkedin_ads/**
12+
- tests/**
13+
- poetry.lock
14+
- pyproject.toml
15+
- tox.ini
16+
pull_request:
17+
branches: [main]
18+
paths:
19+
- .github/workflows/test.yml
20+
- tap_linkedin_ads/**
21+
- tests/**
22+
- poetry.lock
23+
- pyproject.toml
24+
- tox.ini
25+
workflow_dispatch:
26+
27+
env:
28+
FORCE_COLOR: 1
29+
30+
jobs:
31+
pytest:
32+
runs-on: ubuntu-latest
33+
strategy:
34+
fail-fast: false
35+
matrix:
36+
python-version:
37+
- "3.9"
38+
- "3.10"
39+
- "3.11"
40+
- "3.12"
41+
steps:
42+
- uses: actions/checkout@v4
43+
- name: Set up Python ${{ matrix.python-version }}
44+
uses: actions/setup-python@v5
45+
with:
46+
python-version: ${{ matrix.python-version }}
47+
- run: pipx install tox
48+
- name: Run Tox
49+
run: |
50+
tox -e $(echo py${{ matrix.python-version }} | tr -d .)

.gitignore

Lines changed: 1 addition & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -1,14 +1,10 @@
11
# Secrets and internal config files
2-
.secrets/
2+
**/.secrets/*
33

44
# Ignore meltano internal cache and sqlite systemdb
55

66
.meltano/
77

8-
.DS_Store
9-
.github/.DS_Store
10-
11-
128
# Byte-compiled / optimized / DLL files
139
__pycache__/
1410
*.py[cod]
@@ -138,9 +134,3 @@ dmypy.json
138134

139135
# Pyre type checker
140136
.pyre/
141-
.idea/inspectionProfiles/profiles_settings.xml
142-
.idea/misc.xml
143-
.idea/modules.xml
144-
.idea/tap-linkedin-sdk.iml
145-
.idea/workspace.xml
146-
.idea/vcs.xml

.idea/.gitignore

Lines changed: 0 additions & 8 deletions
This file was deleted.

.pre-commit-config.yaml

Lines changed: 11 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -1,41 +1,38 @@
11
ci:
2-
autofix_commit_msg: '[pre-commit.ci] auto fixes'
32
autofix_prs: true
43
autoupdate_schedule: weekly
5-
autoupdate_commit_msg: 'chore(deps): pre-commit autoupdate'
4+
autoupdate_commit_msg: 'chore: pre-commit autoupdate'
65

76
repos:
87
- repo: https://github.com/pre-commit/pre-commit-hooks
9-
rev: v4.4.0
8+
rev: v4.6.0
109
hooks:
1110
- id: check-json
12-
exclude: "\\.vscode/.*.json"
11+
exclude: |
12+
(?x)^(
13+
\.vscode/.*\.json
14+
)$
1315
- id: check-toml
1416
- id: check-yaml
1517
- id: end-of-file-fixer
1618
- id: trailing-whitespace
1719

1820
- repo: https://github.com/python-jsonschema/check-jsonschema
19-
rev: 0.26.3
21+
rev: 0.29.3
2022
hooks:
2123
- id: check-dependabot
2224
- id: check-github-workflows
2325

2426
- repo: https://github.com/astral-sh/ruff-pre-commit
25-
rev: v0.0.287
27+
rev: v0.6.8
2628
hooks:
2729
- id: ruff
28-
args: ["--fix"]
29-
30-
- repo: https://github.com/psf/black
31-
rev: 23.7.0
32-
hooks:
33-
- id: black
30+
args: [--fix, --exit-non-zero-on-fix, --show-fixes]
31+
- id: ruff-format
3432

3533
- repo: https://github.com/pre-commit/mirrors-mypy
36-
rev: v1.5.1
34+
rev: v1.11.2
3735
hooks:
3836
- id: mypy
39-
pass_filenames: true
4037
additional_dependencies:
4138
- types-requests

0 commit comments

Comments
 (0)