fix(website-crawler): Add missing crawl_status column to SELECT query
Some checks failed
GBCI / build (push) Failing after 14m19s
Some checks failed
GBCI / build (push) Failing after 14m19s
Fix the SQL query in check_and_crawl_websites() to also include crawl_status in the SELECT clause. The WebsiteCrawlRecord struct expects this field but it was only present in the WHERE clause, causing Diesel to fail with 'Column crawl_status was not present in query'. This resolves the second website crawler service error.
This commit is contained in:
parent
841b59affd
commit
d26f0652e5
1 changed files with 1 additions and 1 deletions
|
|
@ -81,7 +81,7 @@ impl WebsiteCrawlerService {
|
|||
}
|
||||
|
||||
let websites = diesel::sql_query(
|
||||
"SELECT id, bot_id, url, expires_policy, refresh_policy, max_depth, max_pages, next_crawl
|
||||
"SELECT id, bot_id, url, expires_policy, refresh_policy, max_depth, max_pages, next_crawl, crawl_status
|
||||
FROM website_crawls
|
||||
WHERE next_crawl <= NOW()
|
||||
AND crawl_status != 2
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue