Skip to content

Commit

Permalink
chore: Update templates
Browse files Browse the repository at this point in the history
  • Loading branch information
edgarrmondragon committed Jan 4, 2025
1 parent b1676bf commit fdd9762
Show file tree
Hide file tree
Showing 14 changed files with 34 additions and 25 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -24,13 +24,13 @@ repos:
- id: check-github-workflows

- repo: https://github.com/astral-sh/ruff-pre-commit
rev: v0.8.3
rev: v0.8.4
hooks:
- id: ruff
args: [--fix, --exit-non-zero-on-fix, --show-fixes]
- id: ruff-format

- repo: https://github.com/pre-commit/mirrors-mypy
rev: v1.13.0
rev: v1.14.1
hooks:
- id: mypy
Original file line number Diff line number Diff line change
Expand Up @@ -6,11 +6,11 @@ Built with the [Meltano Mapper SDK](https://sdk.meltano.com) for Singer Mappers.

<!--
Developer TODO: Update the below as needed to correctly describe the install procedure. For instance, if you do not have a PyPi repo, or if you want users to directly install from your git repo, you can modify this step as appropriate.
Developer TODO: Update the below as needed to correctly describe the install procedure. For instance, if you do not have a PyPI repo, or if you want users to directly install from your git repo, you can modify this step as appropriate.
## Installation
Install from PyPi:
Install from PyPI:
```bash
pipx install {{ cookiecutter.mapper_id }}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,9 @@ singer-sdk = { version="~=0.43.1", extras = ["testing"] }
s3 = ["fs-s3fs"]

[tool.pytest.ini_options]
addopts = '--durations=10'
addopts = [
"--durations=10",
]

[tool.mypy]
python_version = "3.12"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,8 @@ requires =
tox>=4.19

[testenv]
pass_env =
MAPPER_*
deps =
pytest
commands =
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -24,14 +24,14 @@ repos:
- id: check-github-workflows

- repo: https://github.com/astral-sh/ruff-pre-commit
rev: v0.8.3
rev: v0.8.4
hooks:
- id: ruff
args: [--fix, --exit-non-zero-on-fix, --show-fixes]
- id: ruff-format

- repo: https://github.com/pre-commit/mirrors-mypy
rev: v1.13.0
rev: v1.14.1
hooks:
- id: mypy
additional_dependencies:
Expand Down
7 changes: 4 additions & 3 deletions cookiecutter/tap-template/{{cookiecutter.tap_id}}/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,11 +6,11 @@ Built with the [Meltano Tap SDK](https://sdk.meltano.com) for Singer Taps.

<!--
Developer TODO: Update the below as needed to correctly describe the install procedure. For instance, if you do not have a PyPi repo, or if you want users to directly install from your git repo, you can modify this step as appropriate.
Developer TODO: Update the below as needed to correctly describe the install procedure. For instance, if you do not have a PyPI repo, or if you want users to directly install from your git repo, you can modify this step as appropriate.
## Installation
Install from PyPi:
Install from PyPI:
```bash
pipx install {{ cookiecutter.tap_id }}
Expand Down Expand Up @@ -121,7 +121,8 @@ Now you can test and orchestrate using Meltano:
```bash
# Test invocation:
meltano invoke {{ cookiecutter.tap_id }} --version
# OR run a test `elt` pipeline:

# OR run a test ELT pipeline:
meltano run {{ cookiecutter.tap_id }} target-jsonl
```

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,9 @@ singer-sdk = { version="~=0.43.1", extras = ["testing"] }
s3 = ["fs-s3fs"]

[tool.pytest.ini_options]
addopts = '--durations=10'
addopts = [
"--durations=10",
]

[tool.mypy]
python_version = "3.12"
Expand Down
2 changes: 2 additions & 0 deletions cookiecutter/tap-template/{{cookiecutter.tap_id}}/tox.ini
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,8 @@ requires =
tox>=4.19

[testenv]
pass_env =
TAP_*
deps =
pytest
commands =
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -24,14 +24,14 @@ repos:
- id: check-github-workflows

- repo: https://github.com/astral-sh/ruff-pre-commit
rev: v0.8.3
rev: v0.8.4
hooks:
- id: ruff
args: [--fix, --exit-non-zero-on-fix, --show-fixes]
- id: ruff-format

- repo: https://github.com/pre-commit/mirrors-mypy
rev: v1.13.0
rev: v1.14.1
hooks:
- id: mypy
additional_dependencies:
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -6,11 +6,11 @@ Build with the [Meltano Target SDK](https://sdk.meltano.com).

<!--
Developer TODO: Update the below as needed to correctly describe the install procedure. For instance, if you do not have a PyPi repo, or if you want users to directly install from your git repo, you can modify this step as appropriate.
Developer TODO: Update the below as needed to correctly describe the install procedure. For instance, if you do not have a PyPI repo, or if you want users to directly install from your git repo, you can modify this step as appropriate.
## Installation
Install from PyPi:
Install from PyPI:
```bash
pipx install {{ cookiecutter.target_id }}
Expand Down Expand Up @@ -66,8 +66,8 @@ You can easily run `{{ cookiecutter.target_id }}` by itself or in a pipeline usi
```bash
{{ cookiecutter.target_id }} --version
{{ cookiecutter.target_id }} --help
# Test using the "Carbon Intensity" sample:
tap-carbon-intensity | {{ cookiecutter.target_id }} --config /path/to/{{ cookiecutter.target_id }}-config.json
# Test using the "Smoke Test" tap:
tap-smoke-test | {{ cookiecutter.target_id }} --config /path/to/{{ cookiecutter.target_id }}-config.json
```

## Developer Resources
Expand Down Expand Up @@ -122,8 +122,9 @@ Now you can test and orchestrate using Meltano:
```bash
# Test invocation:
meltano invoke {{ cookiecutter.target_id }} --version
# OR run a test `elt` pipeline with the Carbon Intensity sample tap:
meltano run tap-carbon-intensity {{ cookiecutter.target_id }}

# OR run a test ELT pipeline with the Smoke Test sample tap:
meltano run tap-smoke-test {{ cookiecutter.target_id }}
```

### SDK Dev Guide
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -43,9 +43,6 @@ singer-sdk = { version="~=0.43.1", extras = ["testing"] }
[tool.poetry.extras]
s3 = ["fs-s3fs"]

[tool.pytest.ini_options]
addopts = '--durations=10'

[tool.mypy]
python_version = "3.12"
warn_unused_configs = true
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,8 @@ requires =
tox>=4.19

[testenv]
pass_env =
TARGET_*
deps =
pytest
commands =
Expand Down
2 changes: 1 addition & 1 deletion docs/python_tips.md
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@ creating and managing virtual environments, these two tools automate the process
`poetry add -D <pippable-dev-only-ref>`.
- If version conflicts occur, relax the version constraints in `pyproject.toml` for the
libraries where the conflict is reported, then try again.
- Poetry can also publish your libraries to PyPi.
- Poetry can also publish your libraries to PyPI.
- **pipx**: Install pipx once, and then use pipx _instead of_ pip.
- If you are using poetry for development, then all other pip-installables should be
executable tools and programs, which is what pipx is designed for.
Expand Down
4 changes: 2 additions & 2 deletions samples/sample_tap_dummy_json/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,11 +6,11 @@ Built with the [Meltano Tap SDK](https://sdk.meltano.com) for Singer Taps.

<!--
Developer TODO: Update the below as needed to correctly describe the install procedure. For instance, if you do not have a PyPi repo, or if you want users to directly install from your git repo, you can modify this step as appropriate.
Developer TODO: Update the below as needed to correctly describe the install procedure. For instance, if you do not have a PyPI repo, or if you want users to directly install from your git repo, you can modify this step as appropriate.
## Installation
Install from PyPi:
Install from PyPI:
```bash
pipx install tap-dummyjson
Expand Down

0 comments on commit fdd9762

Please sign in to comment.