Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: Added support for plural_name for foods #4129

Closed
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
102 commits
Select commit Hold shift + click to select a range
0061af8
Added support for plural_name for foods
Choromanski Aug 31, 2024
ef9955d
Fixed some issues, and added plurals for all items that might be the …
Choromanski Aug 31, 2024
e9c0637
Sorted the foods
Choromanski Aug 31, 2024
4358b7a
Removed UK language should be in en-UK, ignored Scallions, green onio…
Choromanski Aug 31, 2024
aba0440
Removed spacing for CI
Choromanski Aug 31, 2024
544634f
Updated test_seed_foods to reflect the new number of foods in the see…
Choromanski Aug 31, 2024
592cdec
Fixed comments in test_group_seeder.py
Choromanski Aug 31, 2024
2198172
Removed exta potato that I missed
Choromanski Aug 31, 2024
996e9b1
fix: PWA respects orientation lock (#4143)
Choromanski Sep 3, 2024
c0fe1cd
fix(deps): update dependency sqlalchemy to v2.0.33 (#4149)
renovate[bot] Sep 3, 2024
66b31f9
feat: Automate release drafting (#4147)
boc-the-git Sep 3, 2024
2e8922a
chore(l10n): New Crowdin updates (#4145)
hay-kot Sep 4, 2024
4648e3d
chore: Set 'chore' label on PR (#4154)
boc-the-git Sep 4, 2024
afa41ec
chore: Set "documentation" label on PR (#4153)
boc-the-git Sep 4, 2024
dc8fe5e
fix(deps): update dependency fastapi to v0.112.3 (#4159)
renovate[bot] Sep 5, 2024
92398c3
chore(deps): update dependency ruff to v0.6.4 (#4160)
renovate[bot] Sep 5, 2024
10c6c70
fix(deps): update dependency fastapi to ^0.113.0 (#4161)
renovate[bot] Sep 5, 2024
d1ead75
fix(deps): update dependency pydantic to v2.9.0 (#4162)
renovate[bot] Sep 5, 2024
1423b63
fix(deps): update dependency openai to v1.43.1 (#4164)
renovate[bot] Sep 5, 2024
0a68661
docs: OpenAI Documentation (#4165)
michael-genson Sep 6, 2024
ef488be
fix(deps): update dependency sqlalchemy to v2.0.34 (#4156)
renovate[bot] Sep 6, 2024
200706d
docs: Added OpenAI Page to mkdocs (#4167)
michael-genson Sep 6, 2024
777e9e7
docs: add keep screen alive entry (#4116)
paaff Sep 6, 2024
63709a3
docs: Fix OpenAI docs link (#4168)
michael-genson Sep 7, 2024
e8cec9a
feat: Added feature to limit mealplan data by date range (#4111)
vshulcz Sep 7, 2024
b8aa92c
fix(deps): update dependency fastapi to ^0.114.0 (#4169)
renovate[bot] Sep 7, 2024
ad31b09
fix(deps): update dependency openai to v1.44.0 (#4170)
renovate[bot] Sep 7, 2024
a0773a5
chore(l10n): New Crowdin updates (#4171)
hay-kot Sep 7, 2024
9890135
chore(l10n): New Crowdin updates (#4176)
hay-kot Sep 8, 2024
8eb1cc6
fix(deps): update dependency pydantic to v2.9.1 (#4180)
renovate[bot] Sep 9, 2024
042e91c
chore(auto): Update pre-commit hooks (#4179)
github-actions[bot] Sep 9, 2024
b23cd34
chore(l10n): New Crowdin updates (#4181)
hay-kot Sep 9, 2024
7b64664
fix(deps): update dependency openai to v1.44.1 (#4185)
renovate[bot] Sep 9, 2024
0f35803
feat: Add autolabeler functionality for PRs (#4188)
boc-the-git Sep 10, 2024
07ccaf0
chore(deps): update dependency pytest to v8.3.3 (#4189)
renovate[bot] Sep 10, 2024
6d5c852
chore(deps): update dependency rich to v13.8.1 (#4190)
renovate[bot] Sep 10, 2024
1cbfdbe
fix(deps): update dependency pydantic-settings to v2.5.0 (#4191)
renovate[bot] Sep 10, 2024
4ee292a
fix(deps): update dependency fastapi to v0.114.1 (#4194)
renovate[bot] Sep 11, 2024
4400be1
fix(deps): update dependency pydantic-settings to v2.5.2 (#4195)
renovate[bot] Sep 11, 2024
3480d11
feat: Change autolabeler regex to include : (#4196)
boc-the-git Sep 11, 2024
a4869ca
docs: boolean value in docker-compose examples not deserializable in …
ursuscamp Sep 11, 2024
b15d68b
fix: Tweak recipe card height to be consistent (#4150)
michael-genson Sep 11, 2024
924bac3
Updated the other language files
Choromanski Sep 12, 2024
39043fd
Removed all extra spaces, and fixed the name being plural
Choromanski Sep 12, 2024
11f845b
Fixed file encoding
Choromanski Sep 14, 2024
2f77a5e
fix: Broken Social Preview Links (#4183)
michael-genson Sep 12, 2024
87ffa6e
chore(deps): update dependency pydantic-to-typescript2 to v1.0.6 (#4199)
renovate[bot] Sep 12, 2024
25ab093
feat: Reorder ShoppingListItemEditor (#4200)
Kuchenpirat Sep 12, 2024
87ebec2
chore(l10n): New Crowdin updates (#4201)
hay-kot Sep 12, 2024
9dd2f15
fix(deps): update dependency openai to v1.45.0 (#4203)
renovate[bot] Sep 14, 2024
7a25532
chore(deps): update dependency ruff to v0.6.5 (#4205)
renovate[bot] Sep 14, 2024
22d88ad
fix(deps): update dependency fastapi to v0.114.2 (#4206)
renovate[bot] Sep 14, 2024
6f62b50
feat: Use Backend for Recipe Post Actions (#4163)
michael-genson Sep 14, 2024
c9f44d3
fix(deps): Update dependencies for Python 3.12 (#4204)
chishm Sep 15, 2024
3a07984
feat: Allow Cookbooks To Share Names (#4186)
michael-genson Sep 15, 2024
a36abf0
chore(auto): Update pre-commit hooks (#4213)
github-actions[bot] Sep 16, 2024
ef77e88
chore: Improve Alembic Migration Generation (#4192)
michael-genson Sep 16, 2024
a46fff1
fix(deps): update dependency sqlalchemy to v2.0.35 (#4221)
renovate[bot] Sep 16, 2024
2b4c258
fix(deps): update dependency openai to v1.45.1 (#4215)
renovate[bot] Sep 17, 2024
ffb3079
feat: Additional Household Permissions (#4158)
michael-genson Sep 17, 2024
f745242
fix(deps): update dependency fastapi to ^0.115.0 (#4228)
renovate[bot] Sep 18, 2024
0df7d18
fix(deps): update dependency openai to v1.46.0 (#4226)
renovate[bot] Sep 18, 2024
8dc139f
fix(deps): update dependency pydantic to v2.9.2 (#4225)
renovate[bot] Sep 18, 2024
2d7c6d5
chore(l10n): New Crowdin updates (#4230)
hay-kot Sep 18, 2024
f833e18
chore(deps): update dependency mkdocs-material to v9.5.35 (#4229)
renovate[bot] Sep 18, 2024
8e41aa3
chore(l10n): New Crowdin updates (#4233)
hay-kot Sep 19, 2024
0675627
fix(deps): update dependency openai to v1.46.1 (#4234)
renovate[bot] Sep 19, 2024
779b467
feat: Shopping list UI overhaul - increase list item width (#4237)
Wetzel402 Sep 19, 2024
a49791b
feat: Shopping list UI overhaul - label sorted by default (#4238)
Wetzel402 Sep 19, 2024
402a46c
chore: Optimize Loads on Queries (#4220)
michael-genson Sep 20, 2024
d0ea192
chore(deps): update dependency ruff to v0.6.6 (#4240)
renovate[bot] Sep 20, 2024
10a259a
fix: revert shopping list items - increased width (#4241)
Kuchenpirat Sep 20, 2024
9fb638c
chore(deps): update dependency pylint to v3.3.0 (#4243)
renovate[bot] Sep 20, 2024
eadbf6a
chore(deps): update dependency mkdocs-material to v9.5.36 (#4247)
renovate[bot] Sep 21, 2024
e222b41
fix(deps): update dependency openai to v1.47.0 (#4245)
renovate[bot] Sep 21, 2024
6e85d2b
fix: Exclude additional sensitive information from mealie logs (#4218)
bigcat2014 Sep 21, 2024
938c50d
fix(deps): update dependency python-multipart to ^0.0.10 (#4248)
renovate[bot] Sep 22, 2024
1aae037
chore(deps): update dependency ruff to v0.6.7 (#4249)
renovate[bot] Sep 22, 2024
45e51f9
feat: Filter Recipes By Household (and a ton of bug fixes) (#4207)
michael-genson Sep 22, 2024
05b3d6a
feat: OpenAI Custom Headers/Params and Debug Page (#4227)
michael-genson Sep 23, 2024
32d16e7
chore(l10n): New Crowdin updates (#4256)
hay-kot Sep 23, 2024
514fbc6
chore(auto): Update pre-commit hooks (#4255)
github-actions[bot] Sep 23, 2024
8ec1408
fix(deps): update dependency rapidfuzz to v3.10.0 (#4257)
renovate[bot] Sep 23, 2024
222d521
fix(deps): update dependency alembic to v1.13.3 (#4258)
renovate[bot] Sep 23, 2024
4c07092
fix(deps): update dependency openai to v1.47.1 (#4259)
renovate[bot] Sep 23, 2024
44bd649
fix(deps): update dependency tzdata to v2024.2 (#4261)
renovate[bot] Sep 23, 2024
869cabf
chore(l10n): New Crowdin updates (#4264)
hay-kot Sep 24, 2024
49cc627
feat: Shopping list UI overhaul - add label headings per category (#…
Wetzel402 Sep 24, 2024
f625440
chore(deps): update dependency pylint to v3.3.1 (#4265)
renovate[bot] Sep 24, 2024
2f2dff9
feat: sort labels by name,asc in shopping lists (#4253)
seamuslowry Sep 24, 2024
69cbcec
chore(deps): update dependency mkdocs-material to v9.5.37 (#4267)
renovate[bot] Sep 25, 2024
ecb6017
chore(l10n): New Crowdin updates (#4268)
hay-kot Sep 25, 2024
85dc5a8
docs: Update Docs for Households (#4266)
michael-genson Sep 25, 2024
8d0f067
fix(deps): update dependency openai to v1.48.0 (#4269)
renovate[bot] Sep 25, 2024
14f9b7e
chore(deps): update dependency mkdocs-material to v9.5.38 (#4270)
renovate[bot] Sep 26, 2024
0a0e798
chore(l10n): New Crowdin updates (#4271)
hay-kot Sep 26, 2024
6fce4a6
feat: add regex to url before scraping (#4174)
jlssmt Sep 27, 2024
b74ef08
feat: Add Household Filter to Meal Plan Rules (#4231)
michael-genson Sep 27, 2024
79cde72
fix(deps): update dependency openai to v1.50.2 (#4273)
renovate[bot] Sep 28, 2024
a6c49be
chore(deps): update dependency ruff to v0.6.8 (#4272)
renovate[bot] Sep 28, 2024
3318d3b
fix(deps): update dependency uvicorn to ^0.31.0 (#4277)
renovate[bot] Sep 28, 2024
b4acc9f
Resolved merge conflicts
Choromanski Oct 1, 2024
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
71 changes: 71 additions & 0 deletions .github/release-drafter.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,71 @@
---
name-template: "v$RESOLVED_VERSION"
tag-template: "v$RESOLVED_VERSION"
change-template: "- $TITLE @$AUTHOR (#$NUMBER)"
sort-direction: ascending

categories:
- title: "🚨 Breaking changes"
labels:
- "breaking-change"
- "major"
- title: "✨ New features"
labels:
- "feature"
- "minor"
- title: "🐛 Bug fixes"
labels:
- "bugfix"
- title: "🧰 Maintenance"
collapse-after: 3
labels:
- "ci"
- "chore"
- "l10n"
- title: "📚 Documentation"
labels:
- "documentation"
- title: "⬆️ Dependency updates"
collapse-after: 3
labels:
- "dependencies"

version-resolver:
major:
labels:
- "major"
- "breaking-change"
minor:
labels:
- "minor"
- "feature"
patch:
labels:
- "bugfix"
- "chore"
- "ci"
- "dependencies"
- "documentation"
- "l10n"
default: patch

template: |
# 🍴🍴🍴🍴🍴🍴

$CHANGES

# 🍴🍴🍴🍴🍴🍴

autolabeler:
- label: 'feature'
title:
- '/feat/i'
- label: 'bugfix'
title:
- '/fix:/i'
- label: 'documentation'
title:
- '/docs:/i'
- label: 'chore'
title:
- '/chore:/i'
30 changes: 30 additions & 0 deletions .github/workflows/release-drafter.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,30 @@
---
name: Release Drafter

on:
push:
branches:
- mealie-next
# pull_request event is required for autolabeler
pull_request:
types: [opened, labeled, unlabeled, reopened, synchronize]
# pull_request_target event is required for autolabeler to support PRs from forks
pull_request_target:
types: [opened, labeled, unlabeled, reopened, synchronize]
workflow_dispatch:

jobs:
update_release_draft:
permissions:
# write permission is required to create a github release
contents: write
# write permission is required for autolabeler
# otherwise, read permission is required at least
pull-requests: write
name: ✏️ Draft release
runs-on: ubuntu-latest
steps:
- name: 🚀 Run Release Drafter
uses: release-drafter/[email protected]
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
2 changes: 2 additions & 0 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -80,6 +80,8 @@ jobs:
with:
commit-message: "Update image tag, for release ${{ github.event.release.tag_name }}"
branch: "docs/newrelease-update-version-${{ github.event.release.tag_name }}"
labels: |
documentation
delete-branch: true
base: mealie-next
title: "docs(auto): Update image tag, for release ${{ github.event.release.tag_name }}"
Expand Down
4 changes: 3 additions & 1 deletion .github/workflows/scheduled-checks.yml
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,9 @@ jobs:
with:
commit-message: "Update pre-commit hooks"
branch: "fix/update-pre-commit-hooks"
labels: |
chore
delete-branch: true
base: mealie-next
title: "fix(auto): Update pre-commit hooks"
title: "chore(auto): Update pre-commit hooks"
body: "Auto-generated by `.github/workflows/scheduled-checks.yml`"
2 changes: 1 addition & 1 deletion .pre-commit-config.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ repos:
exclude: ^tests/data/
- repo: https://github.com/astral-sh/ruff-pre-commit
# Ruff version.
rev: v0.6.3
rev: v0.6.7
hooks:
- id: ruff
- id: ruff-format
36 changes: 32 additions & 4 deletions alembic/env.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,6 @@
from sqlalchemy import engine_from_config, pool
from typing import Any

import sqlalchemy as sa

import mealie.db.models._all_models # noqa: F401
from alembic import context
Expand Down Expand Up @@ -29,6 +31,28 @@
config.set_main_option("sqlalchemy.url", settings.DB_URL.replace("%", "%%"))


def include_object(object: Any, name: str, type_: str, reflected: bool, compare_to: Any):
# skip dropping food/unit unique constraints; they are defined manually so alembic doesn't see them
# see: revision dded3119c1fe
if type_ == "unique_constraint" and name == "ingredient_foods_name_group_id_key" and compare_to is None:
return False
if type_ == "unique_constraint" and name == "ingredient_units_name_group_id_key" and compare_to is None:
return False

# skip changing the quantity column in recipes_ingredients; it's a float on postgres, but an integer on sqlite
# see: revision 263dd6707191
if (
type_ == "column"
and name == "quantity"
and object.table.name == "recipes_ingredients"
and hasattr(compare_to, "type")
and isinstance(compare_to.type, sa.Integer)
):
return False

return True


def run_migrations_offline():
"""Run migrations in 'offline' mode.

Expand Down Expand Up @@ -60,15 +84,19 @@ def run_migrations_online():
and associate a connection with the context.

"""
connectable = engine_from_config(
connectable = sa.engine_from_config(
config.get_section(config.config_ini_section),
prefix="sqlalchemy.",
poolclass=pool.NullPool,
poolclass=sa.pool.NullPool,
)

with connectable.connect() as connection:
context.configure(
connection=connection, target_metadata=target_metadata, user_module_prefix="mealie.db.migration_types."
connection=connection,
target_metadata=target_metadata,
user_module_prefix="mealie.db.migration_types.",
render_as_batch=True,
include_object=include_object,
)

with context.begin_transaction():
Expand Down
10 changes: 6 additions & 4 deletions alembic/script.py.mako
Original file line number Diff line number Diff line change
Expand Up @@ -9,13 +9,15 @@ import sqlalchemy as sa

import mealie.db.migration_types
from alembic import op
${imports if imports else ""}
% if imports:
${imports}
% endif

# revision identifiers, used by Alembic.
revision = ${repr(up_revision)}
down_revision = ${repr(down_revision)}
branch_labels = ${repr(branch_labels)}
depends_on = ${repr(depends_on)}
down_revision: str | None = ${repr(down_revision)}
branch_labels: str | tuple[str, ...] | None = ${repr(branch_labels)}
depends_on: str | tuple[str, ...] | None = ${repr(depends_on)}


def upgrade():
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -14,9 +14,9 @@

# revision identifiers, used by Alembic.
revision = "6b0f5f32d602"
down_revision = None
branch_labels = None
depends_on = None
down_revision: str | None = None
branch_labels: str | tuple[str, ...] | None = None
depends_on: str | tuple[str, ...] | None = None


# Adapted from https://improveandrepeat.com/2021/09/python-friday-87-handling-pre-existing-tables-with-alembic-and-sqlalchemy/
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -13,8 +13,8 @@
# revision identifiers, used by Alembic.
revision = "263dd6707191"
down_revision = "6b0f5f32d602"
branch_labels = None
depends_on = None
branch_labels: str | tuple[str, ...] | None = None
depends_on: str | tuple[str, ...] | None = None


def is_postgres():
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -13,8 +13,8 @@
# revision identifiers, used by Alembic.
revision = "f1a2dbee5fe9"
down_revision = "263dd6707191"
branch_labels = None
depends_on = None
branch_labels: str | tuple[str, ...] | None = None
depends_on: str | tuple[str, ...] | None = None


def upgrade():
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -14,8 +14,8 @@
# revision identifiers, used by Alembic.
revision = "59eb59135381"
down_revision = "f1a2dbee5fe9"
branch_labels = None
depends_on = None
branch_labels: str | tuple[str, ...] | None = None
depends_on: str | tuple[str, ...] | None = None


def upgrade():
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -14,8 +14,8 @@
# revision identifiers, used by Alembic.
revision = "09dfc897ad62"
down_revision = "59eb59135381"
branch_labels = None
depends_on = None
branch_labels: str | tuple[str, ...] | None = None
depends_on: str | tuple[str, ...] | None = None


def upgrade():
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -13,8 +13,8 @@
# revision identifiers, used by Alembic.
revision = "ab0bae02578f"
down_revision = "09dfc897ad62"
branch_labels = None
depends_on = None
branch_labels: str | tuple[str, ...] | None = None
depends_on: str | tuple[str, ...] | None = None


def upgrade():
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -14,8 +14,8 @@
# revision identifiers, used by Alembic.
revision = "f30cf048c228"
down_revision = "ab0bae02578f"
branch_labels = None
depends_on = None
branch_labels: str | tuple[str, ...] | None = None
depends_on: str | tuple[str, ...] | None = None


def upgrade():
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -13,8 +13,8 @@
# revision identifiers, used by Alembic.
revision = "188374910655"
down_revision = "f30cf048c228"
branch_labels = None
depends_on = None
branch_labels: str | tuple[str, ...] | None = None
depends_on: str | tuple[str, ...] | None = None


def upgrade():
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -13,8 +13,8 @@
# revision identifiers, used by Alembic.
revision = "089bfa50d0ed"
down_revision = "188374910655"
branch_labels = None
depends_on = None
branch_labels: str | tuple[str, ...] | None = None
depends_on: str | tuple[str, ...] | None = None


def upgrade():
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -14,8 +14,8 @@
# revision identifiers, used by Alembic.
revision = "44e8d670719d"
down_revision = "089bfa50d0ed"
branch_labels = None
depends_on = None
branch_labels: str | tuple[str, ...] | None = None
depends_on: str | tuple[str, ...] | None = None


def upgrade():
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -14,8 +14,8 @@
# revision identifiers, used by Alembic.
revision = "2ea7a807915c"
down_revision = "44e8d670719d"
branch_labels = None
depends_on = None
branch_labels: str | tuple[str, ...] | None = None
depends_on: str | tuple[str, ...] | None = None


def upgrade():
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -13,8 +13,8 @@
# revision identifiers, used by Alembic.
revision = "1923519381ad"
down_revision = "2ea7a807915c"
branch_labels = None
depends_on = None
branch_labels: str | tuple[str, ...] | None = None
depends_on: str | tuple[str, ...] | None = None


def upgrade():
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -13,8 +13,8 @@
# revision identifiers, used by Alembic.
revision = "167eb69066ad"
down_revision = "1923519381ad"
branch_labels = None
depends_on = None
branch_labels: str | tuple[str, ...] | None = None
depends_on: str | tuple[str, ...] | None = None


def upgrade():
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -14,8 +14,8 @@
# revision identifiers, used by Alembic.
revision = "165d943c64ee"
down_revision = "167eb69066ad"
branch_labels = None
depends_on = None
branch_labels: str | tuple[str, ...] | None = None
depends_on: str | tuple[str, ...] | None = None


def upgrade():
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -11,8 +11,8 @@
# revision identifiers, used by Alembic.
revision = "ff5f73b01a7a"
down_revision = "165d943c64ee"
branch_labels = None
depends_on = None
branch_labels: str | tuple[str, ...] | None = None
depends_on: str | tuple[str, ...] | None = None


def upgrade():
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -11,8 +11,8 @@
# revision identifiers, used by Alembic.
revision = "16160bf731a0"
down_revision = "ff5f73b01a7a"
branch_labels = None
depends_on = None
branch_labels: str | tuple[str, ...] | None = None
depends_on: str | tuple[str, ...] | None = None


def upgrade():
Expand Down
Loading