From adbc126ef50001c7f1f59c12bcbc8bc7bd713f37 Mon Sep 17 00:00:00 2001 From: Hayden Date: Sun, 3 Jan 2021 13:54:29 -0900 Subject: [PATCH] documentation --- dev/dev-notes.md | 10 ++++++++++ mealie/services/migrations/chowdown.py | 13 ++++++++++++- 2 files changed, 22 insertions(+), 1 deletion(-) diff --git a/dev/dev-notes.md b/dev/dev-notes.md index 9ef17a3620a3..992493257907 100644 --- a/dev/dev-notes.md +++ b/dev/dev-notes.md @@ -1,10 +1,15 @@ # Working Todos Frontend +- [ ] .Vue file reorganized into something that makes sense +- [ ] Recipe Print Page - [x] Catch 400 / bad response on create from URL - [ ] Recipe Editor Data Validation CLient Side - [x] Favicon - [x] Rename Window +- [ ] Add version indicator and notification for new version available +- [ ] Enhanced Search Functionality +- [ ] Organize Home Page my Category, ideally user selectable. Backend - [x] Add Debug folder for writing the last pulled recipe data to. @@ -12,11 +17,16 @@ Backend - [ ] Normalize Recipe data on scrape - [ ] Support how to Sections - [ ] Export Markdown on Auto backups +- [ ] Recipe request by category/tags +- [ ] Add Additional Migrations, See mealie/services/migrations/chowdown.py for examples of how to do this. + - [ ] Open Eats [See Issue #4](https://github.com/hay-kot/mealie/issues/4) + - [ ] NextCloud [See Issue #14](https://github.com/hay-kot/mealie/issues/14) # Draft Changelog ## v0.0.1 General +- Fixed opacity issues with marked steps - [mtoohey31](https://github.com/mtoohey31) - Updated Favicon - Renamed Frontend Window - Added Debug folder to dump scraper data prior to processing. diff --git a/mealie/services/migrations/chowdown.py b/mealie/services/migrations/chowdown.py index 785bb6c21c8c..77bdc2833127 100644 --- a/mealie/services/migrations/chowdown.py +++ b/mealie/services/migrations/chowdown.py @@ -29,6 +29,18 @@ def pull_repo(repo): def read_chowdown_file(recipe_file: Path) -> Recipe: + """Parse through the yaml file to try and pull out the relavent information. + Some issues occur when ":" are used in the text. I have no put a lot of effort + into this so there may be better ways of going about it. Currently, I get about 80-90% + of recipes from repos I've tried. + + Args: + recipe_file (Path): Path to the .yml file + + Returns: + Recipe: Recipe class object + """ + with open(recipe_file, "r") as stream: recipe_description: str = str recipe_data: dict = {} @@ -85,7 +97,6 @@ def chowdown_migrate(repo): except: failed_recipes.append(recipe.name) - report = {"failedImages": failed_images, "failedRecipes": failed_recipes} return report