Skip to content

Commit

Permalink
Remove stuff that I've pulled into separate PRs
Browse files Browse the repository at this point in the history
  • Loading branch information
seanh committed Jan 10, 2025
1 parent 56be5fc commit c161481
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 16 deletions.
10 changes: 1 addition & 9 deletions _shared/project/pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -164,10 +164,6 @@ show_missing = true
precision = 2
fail_under = 100.00
skip_covered = true
exclude_also = [
# # TYPE_CHECKING block is only executed while running mypy
"if TYPE_CHECKING:"
]

{% if cookiecutter.get("linter") != "ruff" %}
[tool.isort]
Expand Down Expand Up @@ -273,7 +269,6 @@ pretty = true
warn_unused_configs = true
warn_redundant_casts = true
warn_unused_ignores = true
check_untyped_defs = true

disable_error_code = [
# https://mypy.readthedocs.io/en/stable/error_code_list.html#code-import-untyped
Expand All @@ -284,12 +279,9 @@ disable_error_code = [
]

[[tool.mypy.overrides]]
module = [
module= [
# Don't try to typecheck the tests for now
"tests.*",
{% if include_exists("mypy/ignored_modules") %}
{{- include("mypy/ignored_modules", indent=4) -}}
{% endif %}
]
ignore_errors = true
{% if include_exists("pyproject.toml") %}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -54,13 +54,7 @@ def delete(engine: Engine) -> None:
else:
pre_delete(engine)

with engine.connect() as connection:
# Delete the DB "public" schema directly.
# We do this instead of using SQLAlchemy's drop_all because we want to delete all tables in the current DB.
# For example, this will delete tables created by migrations in other branches, not only the ones SQLAlchemy know about in the current code base.
connection.execute(text("DROP SCHEMA PUBLIC CASCADE;"))
connection.execute(text("CREATE SCHEMA PUBLIC;"))
connection.execute(text("COMMIT;"))
Base.metadata.drop_all(engine)

try:
from {{ cookiecutter.package_name }}.db import post_delete
Expand Down

0 comments on commit c161481

Please sign in to comment.