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

Add support for grouprecipes.com #873

Merged
merged 2 commits into from
Sep 25, 2023
Merged

Add support for grouprecipes.com #873

merged 2 commits into from
Sep 25, 2023

Conversation

jayaddison
Copy link
Collaborator

Resolves #872.

@jayaddison
Copy link
Collaborator Author

@jknndy could I get your help with review/commentary for this pull request? (something of a trade for previous code reviews - although I don't think I can keep up with your pace of development!)

@jknndy
Copy link
Collaborator

jknndy commented Sep 24, 2023

@jayaddison, all looks good to me, added one comment about a possible description adjustment.

I'm going to tackle adding some ingredient grouping support to some of the preexisting scrapers in place of adding new ones for the moment which should make for some easier reviews!

@jayaddison
Copy link
Collaborator Author

Thanks @jknndy - I think your comment about the description field went missing? I don't see it here.

@jknndy
Copy link
Collaborator

jknndy commented Sep 25, 2023

Thanks @jknndy - I think your comment about the description field went missing? I don't see it here.

The .stripped_strings at the end of this removes the additional information that pops up if you click "Read more" unfortunately when you remove it it appends "read more" & "see less" to the output string. There doesn't seem to be many recipes that this applies to but I think the additional info could be useful on the odd occasion it appears.

For example on this recipe it omits "Biscuit dough finishes this dish off for a filling meal all in one scoop."

def description(self):
    container = self.soup.find("div", {"class": "details"})
    description_text = container.find("p").text
    description_text = description_text.replace("Read more", "").replace("See less", "")
    return normalize_string(description_text)

@jayaddison
Copy link
Collaborator Author

Thanks @jknndy - I think your comment about the description field went missing? I don't see it here.

The .stripped_strings at the end of this removes the additional information that pops up if you click "Read more" unfortunately when you remove it it appends "read more" & "see less" to the output string.

Gotcha, yep. That's intentional in this case - I usually prefer a shorter description than a longer one given the choice, and it seems like the site does a good job of choosing the first few sentences (so the text always appears to end at a sentence / full-stop boundary, as far as I can tell).

@jayaddison
Copy link
Collaborator Author

(or, equivalently, that if the mis-shapen cupcake is provided to someone, then othe participants are able to see that that happened, and figure out a bit for themselves about what went on there; benign/voluntary/well-humoured/etc. I guess some could argue that a little bit of mischief and pecking-order behaviour is normal in social gatherings.. I think if we have the opportunity to do better, either at a cupcake party, or in a technical standard, then doing so is worth considering)

@jayaddison
Copy link
Collaborator Author

I think I'll pause now because this is getting a bit rambly and potentially off-topic - but thank you for the opportunity to discuss this.

@jayaddison jayaddison closed this Sep 25, 2023
@jayaddison jayaddison deleted the issue-872/grouprecipes branch September 25, 2023 22:17
@jayaddison
Copy link
Collaborator Author

Argh, wrong thread :)

@jayaddison
Copy link
Collaborator Author

Re-opening..

@jayaddison jayaddison restored the issue-872/grouprecipes branch September 25, 2023 22:20
@jayaddison jayaddison reopened this Sep 25, 2023
@jayaddison jayaddison merged commit 5cdaddd into main Sep 25, 2023
29 checks passed
@jayaddison jayaddison deleted the issue-872/grouprecipes branch September 25, 2023 22:23
strangetom pushed a commit to strangetom/recipe-scrapers that referenced this pull request Nov 12, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

website request: grouprecipes.com
2 participants