Creating recipes
To retrieve a list of random ingredients,
you can use the lumache.get_random_ingredients()
function:
- lumache.get_random_ingredients(kind=None)
Return a list of random ingredients as strings.
- Parameters
kind (list[str] or None) – Optional “kind” of ingredients.
- Raises
lumache.InvalidKindError – If the kind is invalid.
- Returns
The ingredients list.
- Return type
list[str]
The kind
parameter should be either "meat"
, "fish"
,
or "veggies"
. Otherwise, lumache.get_random_ingredients()
#:py:func:fpdf_table.main.PDFTable.barcode will raise an exception. # .. py:exception:: lumache.InvalidKindError
Raised if the kind is invalid.
Welcome to Lumache’s documentation!
Lumache (/lu’make/) is a Python library for cooks and food lovers that creates recipes mixing random ingredients. It pulls data from the Open Food Facts database and offers a simple and intuitive API.
Check out the Usage section for further information, including how to install the project.
Hint
This is a note admonition. This is the second line of the first paragraph.
Important
This is a note admonition. This is the second line of the first paragraph.
Tip
This is a note admonition. This is the second line of the first paragraph.