pantry-track/logs/database.log
Jadowyne Ulve 72eb87afe3 Implemented Recipe quantites needed on a label
so you have a QOL indicator
2025-08-09 20:57:31 -05:00

106 lines
40 KiB
Plaintext

2025-08-03 08:25:07.786121 --- ERROR --- DatabaseError(message=''int' object does not support indexing',
payload=1,
sql='SELECT * FROM logins WHERE id=%s;')
2025-08-05 15:17:02.305813 --- ERROR --- DatabaseError(message='column "id" does not existLINE 1: WITH passed_id AS (SELECT id AS passed_id FROM test_barcodes... ^',
payload=('%01231003%',),
sql='WITH passed_id AS (SELECT id AS passed_id FROM test_barcodes WHERE barcode=%s), logistics_id AS (SELECT logistics_info_id FROM test_items WHERE id=(SELECT passed_id FROM passed_id)), info_id AS (SELECT item_info_id FROM test_items WHERE id=(SELECT passed_id FROM passed_id)), cte_item_info AS ( SELECT test_item_info.*, row_to_json(units.*) as uom FROM test_item_info LEFT JOIN units ON test_item_info.uom = units.id WHERE test_item_info.id = (SELECT item_info_id FROM info_id) ), cte_groups AS ( SELECT test_groups.*, test_group_items.uuid, test_group_items.item_type, test_group_items.qty FROM test_groups JOIN test_group_items ON test_groups.id = test_group_items.gr_id WHERE test_group_items.item_id = (SELECT passed_id FROM passed_id) ), cte_shopping_lists AS ( SELECT test_shopping_lists.*, test_shopping_list_items.uuid, test_shopping_list_items.item_type, test_shopping_list_items.qty FROM test_shopping_lists JOIN test_shopping_list_items ON test_shopping_lists.id = test_shopping_list_items.sl_id WHERE test_shopping_list_items.item_id = (SELECT passed_id FROM passed_id) ), cte_itemlinks AS ( SELECT * FROM test_itemlinks WHERE link=(SELECT passed_id FROM passed_id) ), cte_item_locations AS ( SELECT * FROM test_item_locations LEFT JOIN test_locations ON test_locations.id = test_item_locations.location_id WHERE part_id = (SELECT passed_id FROM passed_id) ), cte_logistics_info AS ( SELECT li.*, row_to_json(pl) AS primary_location, row_to_json(ail) AS auto_issue_location, row_to_json(pz) AS primary_zone, row_to_json(aiz) AS auto_issue_zone FROM test_logistics_info AS li LEFT JOIN test_locations AS pl ON li.primary_location = pl.id LEFT JOIN test_locations AS ail ON li.auto_issue_location = ail.id LEFT JOIN test_zones AS pz ON li.primary_zone = pz.id LEFT JOIN test_zones AS aiz ON li.auto_issue_zone = aiz.id WHERE li.id=(SELECT logistics_info_id FROM logistics_id) )SELECT (SELECT passed_id FROM passed_id) AS passed_id, test_items.*, (SELECT COALESCE(row_to_json(logis), '{}') FROM cte_logistics_info logis) AS logistics_info, row_to_json(test_food_info.*) as food_info, row_to_json(test_brands.*) as brand, (SELECT COALESCE(row_to_json(ii), '{}') FROM cte_item_info ii) AS item_info, (SELECT COALESCE(array_agg(row_to_json(g)), '{}') FROM cte_groups g) AS item_groups, (SELECT COALESCE(array_agg(row_to_json(sl)), '{}') FROM cte_shopping_lists sl) AS item_shopping_lists, (SELECT COALESCE(array_agg(row_to_json(il)), '{}') FROM cte_itemlinks il) AS linked_items, (SELECT COALESCE(array_agg(row_to_json(ils)), '{}') FROM cte_item_locations ils) AS item_locationsFROM test_items LEFT JOIN test_item_info ON test_items.item_info_id = test_item_info.id LEFT JOIN test_food_info ON test_items.food_info_id = test_food_info.id LEFT JOIN test_brands ON test_items.brand = test_brands.id LEFT JOIN units ON test_item_info.uom = units.id LEFT JOIN cte_groups ON test_items.id = cte_groups.id LEFT JOIN cte_shopping_lists ON test_items.id = cte_shopping_lists.idWHERE test_items.id=(SELECT passed_id FROM passed_id)GROUP BY test_items.id, test_item_info.id, test_food_info.id, test_brands.id;')
2025-08-05 15:19:02.753652 --- ERROR --- DatabaseError(message='tuple index out of range',
payload=('%01231003%',),
sql='WITH item_uuid AS (SELECT item_uuid AS item_uuid FROM test_barcodes WHERE barcode=%s), passed_id As (SELECT id AS passed_id FROM test_items WHERE item_uuid=%s), logistics_id AS (SELECT logistics_info_id FROM test_items WHERE id=(SELECT passed_id FROM passed_id)), info_id AS (SELECT item_info_id FROM test_items WHERE id=(SELECT passed_id FROM passed_id)), cte_item_info AS ( SELECT test_item_info.*, row_to_json(units.*) as uom FROM test_item_info LEFT JOIN units ON test_item_info.uom = units.id WHERE test_item_info.id = (SELECT item_info_id FROM info_id) ), cte_groups AS ( SELECT test_groups.*, test_group_items.uuid, test_group_items.item_type, test_group_items.qty FROM test_groups JOIN test_group_items ON test_groups.id = test_group_items.gr_id WHERE test_group_items.item_id = (SELECT passed_id FROM passed_id) ), cte_shopping_lists AS ( SELECT test_shopping_lists.*, test_shopping_list_items.uuid, test_shopping_list_items.item_type, test_shopping_list_items.qty FROM test_shopping_lists JOIN test_shopping_list_items ON test_shopping_lists.id = test_shopping_list_items.sl_id WHERE test_shopping_list_items.item_id = (SELECT passed_id FROM passed_id) ), cte_itemlinks AS ( SELECT * FROM test_itemlinks WHERE link=(SELECT passed_id FROM passed_id) ), cte_item_locations AS ( SELECT * FROM test_item_locations LEFT JOIN test_locations ON test_locations.id = test_item_locations.location_id WHERE part_id = (SELECT passed_id FROM passed_id) ), cte_logistics_info AS ( SELECT li.*, row_to_json(pl) AS primary_location, row_to_json(ail) AS auto_issue_location, row_to_json(pz) AS primary_zone, row_to_json(aiz) AS auto_issue_zone FROM test_logistics_info AS li LEFT JOIN test_locations AS pl ON li.primary_location = pl.id LEFT JOIN test_locations AS ail ON li.auto_issue_location = ail.id LEFT JOIN test_zones AS pz ON li.primary_zone = pz.id LEFT JOIN test_zones AS aiz ON li.auto_issue_zone = aiz.id WHERE li.id=(SELECT logistics_info_id FROM logistics_id) )SELECT (SELECT passed_id FROM passed_id) AS passed_id, test_items.*, (SELECT COALESCE(row_to_json(logis), '{}') FROM cte_logistics_info logis) AS logistics_info, row_to_json(test_food_info.*) as food_info, row_to_json(test_brands.*) as brand, (SELECT COALESCE(row_to_json(ii), '{}') FROM cte_item_info ii) AS item_info, (SELECT COALESCE(array_agg(row_to_json(g)), '{}') FROM cte_groups g) AS item_groups, (SELECT COALESCE(array_agg(row_to_json(sl)), '{}') FROM cte_shopping_lists sl) AS item_shopping_lists, (SELECT COALESCE(array_agg(row_to_json(il)), '{}') FROM cte_itemlinks il) AS linked_items, (SELECT COALESCE(array_agg(row_to_json(ils)), '{}') FROM cte_item_locations ils) AS item_locationsFROM test_items LEFT JOIN test_item_info ON test_items.item_info_id = test_item_info.id LEFT JOIN test_food_info ON test_items.food_info_id = test_food_info.id LEFT JOIN test_brands ON test_items.brand = test_brands.id LEFT JOIN units ON test_item_info.uom = units.id LEFT JOIN cte_groups ON test_items.id = cte_groups.id LEFT JOIN cte_shopping_lists ON test_items.id = cte_shopping_lists.idWHERE test_items.id=(SELECT passed_id FROM passed_id)GROUP BY test_items.id, test_item_info.id, test_food_info.id, test_brands.id;')
2025-08-05 15:21:40.124158 --- ERROR --- DatabaseError(message='column reference "barcode" is ambiguousLINE 1: ...t_items.item_uuid = test_barcodes.item_uuid WHERE barcode='%... ^',
payload=('%01231003%',),
sql='WITH passed_id AS (SELECT id AS passed_id FROM test_barcodes LEFT JOIN test_items ON test_items.item_uuid = test_barcodes.item_uuid WHERE barcode=%s), logistics_id AS (SELECT logistics_info_id FROM test_items WHERE id=(SELECT passed_id FROM passed_id)), info_id AS (SELECT item_info_id FROM test_items WHERE id=(SELECT passed_id FROM passed_id)), cte_item_info AS ( SELECT test_item_info.*, row_to_json(units.*) as uom FROM test_item_info LEFT JOIN units ON test_item_info.uom = units.id WHERE test_item_info.id = (SELECT item_info_id FROM info_id) ), cte_groups AS ( SELECT test_groups.*, test_group_items.uuid, test_group_items.item_type, test_group_items.qty FROM test_groups JOIN test_group_items ON test_groups.id = test_group_items.gr_id WHERE test_group_items.item_id = (SELECT passed_id FROM passed_id) ), cte_shopping_lists AS ( SELECT test_shopping_lists.*, test_shopping_list_items.uuid, test_shopping_list_items.item_type, test_shopping_list_items.qty FROM test_shopping_lists JOIN test_shopping_list_items ON test_shopping_lists.id = test_shopping_list_items.sl_id WHERE test_shopping_list_items.item_id = (SELECT passed_id FROM passed_id) ), cte_itemlinks AS ( SELECT * FROM test_itemlinks WHERE link=(SELECT passed_id FROM passed_id) ), cte_item_locations AS ( SELECT * FROM test_item_locations LEFT JOIN test_locations ON test_locations.id = test_item_locations.location_id WHERE part_id = (SELECT passed_id FROM passed_id) ), cte_logistics_info AS ( SELECT li.*, row_to_json(pl) AS primary_location, row_to_json(ail) AS auto_issue_location, row_to_json(pz) AS primary_zone, row_to_json(aiz) AS auto_issue_zone FROM test_logistics_info AS li LEFT JOIN test_locations AS pl ON li.primary_location = pl.id LEFT JOIN test_locations AS ail ON li.auto_issue_location = ail.id LEFT JOIN test_zones AS pz ON li.primary_zone = pz.id LEFT JOIN test_zones AS aiz ON li.auto_issue_zone = aiz.id WHERE li.id=(SELECT logistics_info_id FROM logistics_id) )SELECT (SELECT passed_id FROM passed_id) AS passed_id, test_items.*, (SELECT COALESCE(row_to_json(logis), '{}') FROM cte_logistics_info logis) AS logistics_info, row_to_json(test_food_info.*) as food_info, row_to_json(test_brands.*) as brand, (SELECT COALESCE(row_to_json(ii), '{}') FROM cte_item_info ii) AS item_info, (SELECT COALESCE(array_agg(row_to_json(g)), '{}') FROM cte_groups g) AS item_groups, (SELECT COALESCE(array_agg(row_to_json(sl)), '{}') FROM cte_shopping_lists sl) AS item_shopping_lists, (SELECT COALESCE(array_agg(row_to_json(il)), '{}') FROM cte_itemlinks il) AS linked_items, (SELECT COALESCE(array_agg(row_to_json(ils)), '{}') FROM cte_item_locations ils) AS item_locationsFROM test_items LEFT JOIN test_item_info ON test_items.item_info_id = test_item_info.id LEFT JOIN test_food_info ON test_items.food_info_id = test_food_info.id LEFT JOIN test_brands ON test_items.brand = test_brands.id LEFT JOIN units ON test_item_info.uom = units.id LEFT JOIN cte_groups ON test_items.id = cte_groups.id LEFT JOIN cte_shopping_lists ON test_items.id = cte_shopping_lists.idWHERE test_items.id=(SELECT passed_id FROM passed_id)GROUP BY test_items.id, test_item_info.id, test_food_info.id, test_brands.id;')
2025-08-05 15:21:59.561578 --- ERROR --- DatabaseError(message='column reference "barcode" is ambiguousLINE 1: ...t_items.item_uuid = test_barcodes.item_uuid WHERE barcode='%... ^',
payload=('%01231003%',),
sql='WITH passed_id AS (SELECT test_items.id AS passed_id FROM test_barcodes LEFT JOIN test_items ON test_items.item_uuid = test_barcodes.item_uuid WHERE barcode=%s), logistics_id AS (SELECT logistics_info_id FROM test_items WHERE id=(SELECT passed_id FROM passed_id)), info_id AS (SELECT item_info_id FROM test_items WHERE id=(SELECT passed_id FROM passed_id)), cte_item_info AS ( SELECT test_item_info.*, row_to_json(units.*) as uom FROM test_item_info LEFT JOIN units ON test_item_info.uom = units.id WHERE test_item_info.id = (SELECT item_info_id FROM info_id) ), cte_groups AS ( SELECT test_groups.*, test_group_items.uuid, test_group_items.item_type, test_group_items.qty FROM test_groups JOIN test_group_items ON test_groups.id = test_group_items.gr_id WHERE test_group_items.item_id = (SELECT passed_id FROM passed_id) ), cte_shopping_lists AS ( SELECT test_shopping_lists.*, test_shopping_list_items.uuid, test_shopping_list_items.item_type, test_shopping_list_items.qty FROM test_shopping_lists JOIN test_shopping_list_items ON test_shopping_lists.id = test_shopping_list_items.sl_id WHERE test_shopping_list_items.item_id = (SELECT passed_id FROM passed_id) ), cte_itemlinks AS ( SELECT * FROM test_itemlinks WHERE link=(SELECT passed_id FROM passed_id) ), cte_item_locations AS ( SELECT * FROM test_item_locations LEFT JOIN test_locations ON test_locations.id = test_item_locations.location_id WHERE part_id = (SELECT passed_id FROM passed_id) ), cte_logistics_info AS ( SELECT li.*, row_to_json(pl) AS primary_location, row_to_json(ail) AS auto_issue_location, row_to_json(pz) AS primary_zone, row_to_json(aiz) AS auto_issue_zone FROM test_logistics_info AS li LEFT JOIN test_locations AS pl ON li.primary_location = pl.id LEFT JOIN test_locations AS ail ON li.auto_issue_location = ail.id LEFT JOIN test_zones AS pz ON li.primary_zone = pz.id LEFT JOIN test_zones AS aiz ON li.auto_issue_zone = aiz.id WHERE li.id=(SELECT logistics_info_id FROM logistics_id) )SELECT (SELECT passed_id FROM passed_id) AS passed_id, test_items.*, (SELECT COALESCE(row_to_json(logis), '{}') FROM cte_logistics_info logis) AS logistics_info, row_to_json(test_food_info.*) as food_info, row_to_json(test_brands.*) as brand, (SELECT COALESCE(row_to_json(ii), '{}') FROM cte_item_info ii) AS item_info, (SELECT COALESCE(array_agg(row_to_json(g)), '{}') FROM cte_groups g) AS item_groups, (SELECT COALESCE(array_agg(row_to_json(sl)), '{}') FROM cte_shopping_lists sl) AS item_shopping_lists, (SELECT COALESCE(array_agg(row_to_json(il)), '{}') FROM cte_itemlinks il) AS linked_items, (SELECT COALESCE(array_agg(row_to_json(ils)), '{}') FROM cte_item_locations ils) AS item_locationsFROM test_items LEFT JOIN test_item_info ON test_items.item_info_id = test_item_info.id LEFT JOIN test_food_info ON test_items.food_info_id = test_food_info.id LEFT JOIN test_brands ON test_items.brand = test_brands.id LEFT JOIN units ON test_item_info.uom = units.id LEFT JOIN cte_groups ON test_items.id = cte_groups.id LEFT JOIN cte_shopping_lists ON test_items.id = cte_shopping_lists.idWHERE test_items.id=(SELECT passed_id FROM passed_id)GROUP BY test_items.id, test_item_info.id, test_food_info.id, test_brands.id;')
2025-08-05 15:24:44.958603 --- ERROR --- DatabaseError(message='column reference "barcode" is ambiguousLINE 3: WHERE barcode='%041789001314%'), ^',
payload=('%041789001314%',),
sql='WITH passed_id AS (SELECT test_items.id AS passed_id FROM test_barcodes LEFT JOIN test_items ON test_items.item_uuid = test_barcodes.item_uuid WHERE barcode=%s), logistics_id AS (SELECT logistics_info_id FROM test_items WHERE id=(SELECT passed_id FROM passed_id)), info_id AS (SELECT item_info_id FROM test_items WHERE id=(SELECT passed_id FROM passed_id)), cte_item_info AS ( SELECT test_item_info.*, row_to_json(units.*) as uom FROM test_item_info LEFT JOIN units ON test_item_info.uom = units.id WHERE test_item_info.id = (SELECT item_info_id FROM info_id) ), cte_groups AS ( SELECT test_groups.*, test_group_items.uuid, test_group_items.item_type, test_group_items.qty FROM test_groups JOIN test_group_items ON test_groups.id = test_group_items.gr_id WHERE test_group_items.item_id = (SELECT passed_id FROM passed_id) ), cte_shopping_lists AS ( SELECT test_shopping_lists.*, test_shopping_list_items.uuid, test_shopping_list_items.item_type, test_shopping_list_items.qty FROM test_shopping_lists JOIN test_shopping_list_items ON test_shopping_lists.id = test_shopping_list_items.sl_id WHERE test_shopping_list_items.item_id = (SELECT passed_id FROM passed_id) ), cte_itemlinks AS ( SELECT * FROM test_itemlinks WHERE link=(SELECT passed_id FROM passed_id) ), cte_item_locations AS ( SELECT * FROM test_item_locations LEFT JOIN test_locations ON test_locations.id = test_item_locations.location_id WHERE part_id = (SELECT passed_id FROM passed_id) ), cte_logistics_info AS ( SELECT li.*, row_to_json(pl) AS primary_location, row_to_json(ail) AS auto_issue_location, row_to_json(pz) AS primary_zone, row_to_json(aiz) AS auto_issue_zone FROM test_logistics_info AS li LEFT JOIN test_locations AS pl ON li.primary_location = pl.id LEFT JOIN test_locations AS ail ON li.auto_issue_location = ail.id LEFT JOIN test_zones AS pz ON li.primary_zone = pz.id LEFT JOIN test_zones AS aiz ON li.auto_issue_zone = aiz.id WHERE li.id=(SELECT logistics_info_id FROM logistics_id) )SELECT (SELECT passed_id FROM passed_id) AS passed_id, test_items.*, (SELECT COALESCE(row_to_json(logis), '{}') FROM cte_logistics_info logis) AS logistics_info, row_to_json(test_food_info.*) as food_info, row_to_json(test_brands.*) as brand, (SELECT COALESCE(row_to_json(ii), '{}') FROM cte_item_info ii) AS item_info, (SELECT COALESCE(array_agg(row_to_json(g)), '{}') FROM cte_groups g) AS item_groups, (SELECT COALESCE(array_agg(row_to_json(sl)), '{}') FROM cte_shopping_lists sl) AS item_shopping_lists, (SELECT COALESCE(array_agg(row_to_json(il)), '{}') FROM cte_itemlinks il) AS linked_items, (SELECT COALESCE(array_agg(row_to_json(ils)), '{}') FROM cte_item_locations ils) AS item_locationsFROM test_items LEFT JOIN test_item_info ON test_items.item_info_id = test_item_info.id LEFT JOIN test_food_info ON test_items.food_info_id = test_food_info.id LEFT JOIN test_brands ON test_items.brand = test_brands.id LEFT JOIN units ON test_item_info.uom = units.id LEFT JOIN cte_groups ON test_items.id = cte_groups.id LEFT JOIN cte_shopping_lists ON test_items.id = cte_shopping_lists.idWHERE test_items.id=(SELECT passed_id FROM passed_id)GROUP BY test_items.id, test_item_info.id, test_food_info.id, test_brands.id;')
2025-08-05 15:25:24.830194 --- ERROR --- DatabaseError(message='invalid reference to FROM-clause entry for table "test_items"LINE 1: WITH passed_id AS (SELECT test_items.id AS passed_id FROM te... ^HINT: Perhaps you meant to reference the table alias "items".',
payload=('%041789001314%',),
sql='WITH passed_id AS (SELECT test_items.id AS passed_id FROM test_barcodes barcodes LEFT JOIN test_items items ON items.item_uuid = barcodes.item_uuid WHERE barcodes.barcode=%s), logistics_id AS (SELECT logistics_info_id FROM test_items WHERE id=(SELECT passed_id FROM passed_id)), info_id AS (SELECT item_info_id FROM test_items WHERE id=(SELECT passed_id FROM passed_id)), cte_item_info AS ( SELECT test_item_info.*, row_to_json(units.*) as uom FROM test_item_info LEFT JOIN units ON test_item_info.uom = units.id WHERE test_item_info.id = (SELECT item_info_id FROM info_id) ), cte_groups AS ( SELECT test_groups.*, test_group_items.uuid, test_group_items.item_type, test_group_items.qty FROM test_groups JOIN test_group_items ON test_groups.id = test_group_items.gr_id WHERE test_group_items.item_id = (SELECT passed_id FROM passed_id) ), cte_shopping_lists AS ( SELECT test_shopping_lists.*, test_shopping_list_items.uuid, test_shopping_list_items.item_type, test_shopping_list_items.qty FROM test_shopping_lists JOIN test_shopping_list_items ON test_shopping_lists.id = test_shopping_list_items.sl_id WHERE test_shopping_list_items.item_id = (SELECT passed_id FROM passed_id) ), cte_itemlinks AS ( SELECT * FROM test_itemlinks WHERE link=(SELECT passed_id FROM passed_id) ), cte_item_locations AS ( SELECT * FROM test_item_locations LEFT JOIN test_locations ON test_locations.id = test_item_locations.location_id WHERE part_id = (SELECT passed_id FROM passed_id) ), cte_logistics_info AS ( SELECT li.*, row_to_json(pl) AS primary_location, row_to_json(ail) AS auto_issue_location, row_to_json(pz) AS primary_zone, row_to_json(aiz) AS auto_issue_zone FROM test_logistics_info AS li LEFT JOIN test_locations AS pl ON li.primary_location = pl.id LEFT JOIN test_locations AS ail ON li.auto_issue_location = ail.id LEFT JOIN test_zones AS pz ON li.primary_zone = pz.id LEFT JOIN test_zones AS aiz ON li.auto_issue_zone = aiz.id WHERE li.id=(SELECT logistics_info_id FROM logistics_id) )SELECT (SELECT passed_id FROM passed_id) AS passed_id, test_items.*, (SELECT COALESCE(row_to_json(logis), '{}') FROM cte_logistics_info logis) AS logistics_info, row_to_json(test_food_info.*) as food_info, row_to_json(test_brands.*) as brand, (SELECT COALESCE(row_to_json(ii), '{}') FROM cte_item_info ii) AS item_info, (SELECT COALESCE(array_agg(row_to_json(g)), '{}') FROM cte_groups g) AS item_groups, (SELECT COALESCE(array_agg(row_to_json(sl)), '{}') FROM cte_shopping_lists sl) AS item_shopping_lists, (SELECT COALESCE(array_agg(row_to_json(il)), '{}') FROM cte_itemlinks il) AS linked_items, (SELECT COALESCE(array_agg(row_to_json(ils)), '{}') FROM cte_item_locations ils) AS item_locationsFROM test_items LEFT JOIN test_item_info ON test_items.item_info_id = test_item_info.id LEFT JOIN test_food_info ON test_items.food_info_id = test_food_info.id LEFT JOIN test_brands ON test_items.brand = test_brands.id LEFT JOIN units ON test_item_info.uom = units.id LEFT JOIN cte_groups ON test_items.id = cte_groups.id LEFT JOIN cte_shopping_lists ON test_items.id = cte_shopping_lists.idWHERE test_items.id=(SELECT passed_id FROM passed_id)GROUP BY test_items.id, test_item_info.id, test_food_info.id, test_brands.id;')
2025-08-08 18:22:06.689520 --- ERROR --- DatabaseError(message='syntax error at or near ","LINE 1: ..., in_exchange, out_exchange, descriptor) VALUES (?, ?, ?, ?,... ^',
payload=('%test%', '44c41878-e645-4e16-a402-e480936ac4aa', 1, 1, 'normal test'),
sql='INSERT INTO test_barcodes (barcode, item_uuid, in_exchange, out_exchange, descriptor) VALUES (?, ?, ?, ?, ?);')
2025-08-08 18:23:47.408991 --- ERROR --- DatabaseError(message='syntax error at or near ","LINE 1: ..., in_exchange, out_exchange, descriptor) VALUES (?, ?, ?, ?,... ^',
payload=('%test%', '44c41878-e645-4e16-a402-e480936ac4aa', 1, 1, 'normal test'),
sql='INSERT INTO test_barcodes (barcode, item_uuid, in_exchange, out_exchange, descriptor) VALUES (?, ?, ?, ?, ?) RETURNING *;')
2025-08-08 18:25:41.824363 --- ERROR --- DatabaseError(message='duplicate key value violates unique constraint "test_barcodes_pkey"DETAIL: Key (barcode)=(%test%) already exists.',
payload=('%test%', '44c41878-e645-4e16-a402-e480936ac4aa', 1, 1, 'normal test'),
sql='INSERT INTO test_barcodes (barcode, item_uuid, in_exchange, out_exchange, descriptor) VALUES (%s, %s, %s, %s, %s) RETURNING *;')
2025-08-09 07:32:58.410729 --- ERROR --- DatabaseError(message='duplicate key value violates unique constraint "test_barcodes_pkey"DETAIL: Key (barcode)=(tsath) already exists.',
payload=('tsath', '44c41878-e645-4e16-a402-e480936ac4aa', '2', '2', 'test2'),
sql='INSERT INTO test_barcodes (barcode, item_uuid, in_exchange, out_exchange, descriptor) VALUES (%s, %s, %s, %s, %s) RETURNING *;')
2025-08-09 07:34:13.926705 --- ERROR --- DatabaseError(message='duplicate key value violates unique constraint "test_barcodes_pkey"DETAIL: Key (barcode)=(tsath) already exists.',
payload=('tsath', '44c41878-e645-4e16-a402-e480936ac4aa', '1', '1', 'test'),
sql='INSERT INTO test_barcodes (barcode, item_uuid, in_exchange, out_exchange, descriptor) VALUES (%s, %s, %s, %s, %s) RETURNING *;')
2025-08-09 08:07:31.538747 --- ERROR --- DatabaseError(message='can't adapt type 'dict'',
payload={'barcode': {'barcode': 'tsath', 'descriptor': 'test', 'in_exchange': 1, 'out_exchange': 1}, 'update': {'in_exchange': '1', 'out_exchange': '1', 'descriptor': 'test changed'}},
sql='UPDATE test_barcodes SET in_exchange = %s, out_exchange = %s, descriptor = %s WHERE barcode=%s RETURNING *;')
2025-08-09 08:08:14.996560 --- ERROR --- DatabaseError(message='can't adapt type 'dict'',
payload={'barcode': {'barcode': 'tsath', 'descriptor': 'test', 'in_exchange': 1, 'out_exchange': 1}, 'update': {'in_exchange': '1', 'out_exchange': '1', 'descriptor': 'test c'}},
sql='UPDATE test_barcodes SET in_exchange = %s, out_exchange = %s, descriptor = %s WHERE barcode=%s RETURNING *;')
2025-08-09 08:08:51.302903 --- ERROR --- DatabaseError(message='can't adapt type 'dict'',
payload={'barcode': {'barcode': 'tsath', 'descriptor': 'test', 'in_exchange': 1, 'out_exchange': 1}, 'update': {'in_exchange': '1', 'out_exchange': '1', 'descriptor': 'test ggh'}},
sql='UPDATE test_barcodes SET in_exchange = %s, out_exchange = %s, descriptor = %s WHERE barcode=%s RETURNING *;')
2025-08-09 11:07:03.004000 --- ERROR --- DatabaseError(message='not all arguments converted during string formatting',
payload=('PLU SKU', 30, None, '8cac7ce9-dfd1-4da8-8856-57f5bdbc752b', 'Bubble Bath Lavender', 1, 1, '{"cost": 0, "expires": false}', 'Unresolved'),
sql='INSERT INTO test_receipt_items(type, receipt_id, barcode, name, qty, uom, data, status) VALUES (%s, %s, %s, %s, %s, %s, %s, %s) RETURNING *;')
2025-08-09 11:52:23.005675 --- ERROR --- DatabaseError(message='duplicate key value violates unique constraint "test_barcodes_pkey"DETAIL: Key (barcode)=(%6589%) already exists.',
payload=('%6589%', '7bdc9602-ca87-4e9f-b9ef-fc5e8f0eceb7', 1.0, 1.0, 'Test Item 22'),
sql='INSERT INTO test_barcodes (barcode, item_uuid, in_exchange, out_exchange, descriptor) VALUES (%s, %s, %s, %s, %s) RETURNING *;')
2025-08-09 14:49:30.457282 --- ERROR --- DatabaseError(message='not all arguments converted during string formatting',
payload=('sku', 36, '%078742015101%', '3405b49b-843a-4bca-a235-686e4a9f2e73', '100% grated parmesan cheese', 1, 1, '{"cost": 0, "expires": false}', 'Unresolved'),
sql='INSERT INTO test_receipt_items(type, receipt_id, barcode, name, qty, uom, data, status) VALUES (%s, %s, %s, %s, %s, %s, %s, %s) RETURNING *;')
2025-08-09 14:51:18.570501 --- ERROR --- DatabaseError(message='not all arguments converted during string formatting',
payload=('sku', 36, '%078742015101%', '3405b49b-843a-4bca-a235-686e4a9f2e73', '100% grated parmesan cheese', 1, 1, '{"cost": 0, "expires": false}', 'Unresolved'),
sql='INSERT INTO test_receipt_items(type, receipt_id, barcode, name, qty, uom, data, status) VALUES (%s, %s, %s, %s, %s, %s, %s, %s) RETURNING *;')
2025-08-09 14:53:40.869005 --- ERROR --- DatabaseError(message='not all arguments converted during string formatting',
payload=('sku', 36, '%078742015101%', '3405b49b-843a-4bca-a235-686e4a9f2e73', '100% grated parmesan cheese', 1, 1, '{"cost": 0, "expires": false}', 'Unresolved'),
sql='INSERT INTO test_receipt_items(type, receipt_id, barcode, name, qty, uom, data, status) VALUES (%s, %s, %s, %s, %s, %s, %s, %s) RETURNING *;')
2025-08-09 15:57:58.332708 --- ERROR --- DatabaseError(message='invalid input syntax for type uuid: ""LINE 3: VALUES ('custom', 36, '', '', 'test1', '1', '2', '{"cost": "... ^',
payload=('custom', 36, '', '', 'test1', '1', '2', '{"cost": "0.99", "expires": false}', 'Unresolved'),
sql='INSERT INTO test_receipt_items(type, receipt_id, barcode, item_uuid, name, qty, uom, data, status) VALUES (%s, %s, %s, %s, %s, %s, %s, %s, %s) RETURNING *;')
2025-08-09 16:10:49.684466 --- ERROR --- DatabaseError(message='operator does not exist: integer = character varyingLINE 4: ...(row_to_json(un), '{}') FROM units un WHERE un.id = items.uo... ^HINT: No operator matches the given name and argument types. You might need to add explicit type casts.',
payload=(1,),
sql='WITH passed_id AS (SELECT %s AS passed_id), cte_receipt_items AS ( SELECT items.* , (SELECT COALESCE(row_to_json(un), '{}') FROM units un WHERE un.id = items.uom LIMIT 1) AS uom FROM testa_receipt_items items WHERE items.receipt_id = (SELECT passed_id FROM passed_id) ORDER BY items.name ASC )SELECT (SELECT passed_id FROM passed_id) AS passed_id, testa_receipts.*, logins.username as submitted_by, (SELECT COALESCE(array_agg(row_to_json(ris)), '{}') FROM cte_receipt_items ris) AS receipt_items, row_to_json(testa_vendors.*) as vendorFROM testa_receiptsJOIN logins ON testa_receipts.submitted_by = logins.idLEFT JOIN testa_vendors ON testa_receipts.vendor_id = testa_vendors.id WHERE testa_receipts.id=(SELECT passed_id FROM passed_id)')
2025-08-09 16:20:46.492869 --- ERROR --- DatabaseError(message='relation "testa_recipes" does not existLINE 3: FROM testa_recipes LIMIT 10 OFFSET 0; ^',
payload=(10, 0),
sql='SELECT *, (SELECT COALESCE(array_agg(row_to_json(g)), '{}') FROM testa_recipe_items g WHERE rp_id = testa_recipes.id) AS rp_items FROM testa_recipes LIMIT %s OFFSET %s;')
2025-08-09 19:39:51.459243 --- ERROR --- DatabaseError(message='invalid input syntax for type uuid: "%812446030134%"LINE 3: VALUES ('%812446030134%', 6, 'sku', 'Rice cooked in bone bro... ^',
payload=('%812446030134%', 6, 'sku', 'Rice cooked in bone broth', 1, 1.0, 8, '{}'),
sql='INSERT INTO main_recipe_items(item_uuid, rp_id, item_type, item_name, uom, qty, item_id, links) VALUES (%s, %s, %s, %s, %s, %s, %s, %s) RETURNING *;')
2025-08-09 19:39:52.911421 --- ERROR --- DatabaseError(message='invalid input syntax for type uuid: "%812446030134%"LINE 3: VALUES ('%812446030134%', 6, 'sku', 'Rice cooked in bone bro... ^',
payload=('%812446030134%', 6, 'sku', 'Rice cooked in bone broth', 1, 1.0, 8, '{}'),
sql='INSERT INTO main_recipe_items(item_uuid, rp_id, item_type, item_name, uom, qty, item_id, links) VALUES (%s, %s, %s, %s, %s, %s, %s, %s) RETURNING *;')
2025-08-09 19:39:53.115678 --- ERROR --- DatabaseError(message='invalid input syntax for type uuid: "%812446030134%"LINE 3: VALUES ('%812446030134%', 6, 'sku', 'Rice cooked in bone bro... ^',
payload=('%812446030134%', 6, 'sku', 'Rice cooked in bone broth', 1, 1.0, 8, '{}'),
sql='INSERT INTO main_recipe_items(item_uuid, rp_id, item_type, item_name, uom, qty, item_id, links) VALUES (%s, %s, %s, %s, %s, %s, %s, %s) RETURNING *;')
2025-08-09 19:39:54.082880 --- ERROR --- DatabaseError(message='invalid input syntax for type uuid: "%812446030134%"LINE 3: VALUES ('%812446030134%', 6, 'sku', 'Rice cooked in bone bro... ^',
payload=('%812446030134%', 6, 'sku', 'Rice cooked in bone broth', 1, 1.0, 8, '{}'),
sql='INSERT INTO main_recipe_items(item_uuid, rp_id, item_type, item_name, uom, qty, item_id, links) VALUES (%s, %s, %s, %s, %s, %s, %s, %s) RETURNING *;')
2025-08-09 19:39:54.266687 --- ERROR --- DatabaseError(message='invalid input syntax for type uuid: "%812446030134%"LINE 3: VALUES ('%812446030134%', 6, 'sku', 'Rice cooked in bone bro... ^',
payload=('%812446030134%', 6, 'sku', 'Rice cooked in bone broth', 1, 1.0, 8, '{}'),
sql='INSERT INTO main_recipe_items(item_uuid, rp_id, item_type, item_name, uom, qty, item_id, links) VALUES (%s, %s, %s, %s, %s, %s, %s, %s) RETURNING *;')
2025-08-09 19:56:12.367519 --- ERROR --- DatabaseError(message='column "g" does not existLINE 2: (SELECT COALESCE(array_agg(row_to_json(g)), '{}') ^',
payload=(25, 0),
sql='SELECT *, (SELECT COALESCE(array_agg(row_to_json(g)), '{}') FROM test_recipe_items rp_item LEFT JOIN test_items items ON items.item_uuid = rp_item.item_uuid WHERE rp_id = test_recipes.id) AS rp_itemsFROM test_recipes LIMIT %s OFFSET %s;')
2025-08-09 20:03:06.560301 --- ERROR --- DatabaseError(message='column sum_cte.id does not existLINE 14: LEFT JOIN sum_cte ON items.id = sum_cte.id ^',
payload=(25, 0),
sql='WITH sum_cte AS ( SELECT items.item_uuid, SUM(items_locations.quantity_on_hand)::FLOAT8 AS total_sum FROM main_item_locations items_locations JOIN main_items items ON items_locations.part_id = items.id GROUP BY items.item_uuid )SELECT *, (SELECT COALESCE(array_agg(row_to_json(rp_item)), '{}') FROM main_recipe_items rp_item LEFT JOIN main_items items ON items.item_uuid = rp_item.item_uuid LEFT JOIN sum_cte ON items.id = sum_cte.id WHERE rp_item.rp_id = main_recipes.id) AS rp_itemsFROM main_recipes LIMIT %s OFFSET %s;')
2025-08-09 20:05:35.624889 --- ERROR --- DatabaseError(message='column "sum_cte.total_sum" must appear in the GROUP BY clause or be used in an aggregate functionLINE 11: ...OALESCE(array_agg(row_to_json(rp_item.*)), '{}'), sum_cte.to... ^',
payload=(25, 0),
sql='WITH sum_cte AS ( SELECT mi.id, SUM(mil.quantity_on_hand)::FLOAT8 AS total_sum FROM main_item_locations mil JOIN main_items mi ON mil.part_id = mi.id GROUP BY mi.id )SELECT *, (SELECT COALESCE(array_agg(row_to_json(rp_item.*)), '{}'), sum_cte.total_sum FROM main_recipe_items rp_item LEFT JOIN main_items items ON items.item_uuid = rp_item.item_uuid LEFT JOIN sum_cte ON items.id = sum_cte.id WHERE rp_item.rp_id = main_recipes.id) AS rp_itemsFROM main_recipes LIMIT %s OFFSET %s;')
2025-08-09 20:17:43.956632 --- ERROR --- DatabaseError(message='missing FROM-clause entry for table "rp_item"LINE 17: LEFT JOIN cte_recipe_items rp_items ON rp_item.rp_id = recip... ^',
payload=(25, 0),
sql='WITH sum_cte AS ( SELECT mi.item_uuid, SUM(mil.quantity_on_hand)::FLOAT8 AS total_sum FROM main_item_locations mil JOIN main_items mi ON mil.part_id = mi.id GROUP BY mi.id ), cte_recipe_items AS ( SELECT rp_item.*, COALESCE(sum_cte.total_sum, 0) as quantity_on_hand FROM main_recipe_items rp_item LEFT JOIN sum_cte ON sum_cte.item_uuid = rp_item.item_uuid )SELECT *, (SELECT COALESCE(row_to_json(rp_it), '{}') FROM rp_items rp_it) AS rp_itemsFROM main_recipes recipesLEFT JOIN cte_recipe_items rp_items ON rp_item.rp_id = recipes.id LIMIT %s OFFSET %s;')
2025-08-09 20:17:56.230829 --- ERROR --- DatabaseError(message='missing FROM-clause entry for table "rp_item"LINE 17: LEFT JOIN cte_recipe_items rp_items ON rp_item.rp_id = recip... ^',
payload=(25, 0),
sql='WITH sum_cte AS ( SELECT mi.item_uuid, SUM(mil.quantity_on_hand)::FLOAT8 AS total_sum FROM main_item_locations mil JOIN main_items mi ON mil.part_id = mi.id GROUP BY mi.id ), cte_recipe_items AS ( SELECT rp_item.*, COALESCE(sum_cte.total_sum, 0) as quantity_on_hand FROM main_recipe_items rp_item LEFT JOIN sum_cte ON sum_cte.item_uuid = rp_item.item_uuid )SELECT *, (SELECT COALESCE(row_to_json(rp_it), '{}') FROM rp_items rp_it) AS testFROM main_recipes recipesLEFT JOIN cte_recipe_items rp_items ON rp_item.rp_id = recipes.id LIMIT %s OFFSET %s;')
2025-08-09 20:18:34.287696 --- ERROR --- DatabaseError(message='relation "rp_items" does not existLINE 15: ... (SELECT COALESCE(row_to_json(rp_it), '{}') FROM rp_items r... ^',
payload=(25, 0),
sql='WITH sum_cte AS ( SELECT mi.item_uuid, SUM(mil.quantity_on_hand)::FLOAT8 AS total_sum FROM main_item_locations mil JOIN main_items mi ON mil.part_id = mi.id GROUP BY mi.id ), cte_recipe_items AS ( SELECT rp_item.*, COALESCE(sum_cte.total_sum, 0) as quantity_on_hand FROM main_recipe_items rp_item LEFT JOIN sum_cte ON sum_cte.item_uuid = rp_item.item_uuid )SELECT *, (SELECT COALESCE(row_to_json(rp_it), '{}') FROM rp_items rp_its) AS testFROM main_recipes recipesLEFT JOIN cte_recipe_items rp_items ON rp_items.rp_id = recipes.id LIMIT %s OFFSET %s;')
2025-08-09 20:19:12.850845 --- ERROR --- DatabaseError(message='relation "rp_items" does not existLINE 15: ... (SELECT COALESCE(row_to_json(rp_it), '{}') FROM rp_items r... ^',
payload=(25, 0),
sql='WITH sum_cte AS ( SELECT mi.item_uuid, SUM(mil.quantity_on_hand)::FLOAT8 AS total_sum FROM main_item_locations mil JOIN main_items mi ON mil.part_id = mi.id GROUP BY mi.id ), cte_recipe_items AS ( SELECT rp_item.*, COALESCE(sum_cte.total_sum, 0) as quantity_on_hand FROM main_recipe_items rp_item LEFT JOIN sum_cte ON sum_cte.item_uuid = rp_item.item_uuid )SELECT *, (SELECT COALESCE(row_to_json(rp_it), '{}') FROM rp_items rp_its) AS testFROM main_recipes recipesLEFT JOIN cte_recipe_items ON cte_recipe_items.rp_id = recipes.id LIMIT %s OFFSET %s;')