From ae76e37677b34a4e34b2b67fd68acf43de04f749 Mon Sep 17 00:00:00 2001 From: Atalya Alon Date: Sun, 29 Dec 2024 13:15:20 +0200 Subject: [PATCH] re-add set_critical --- anyway/parsers/news_flash.py | 3 +++ 1 file changed, 3 insertions(+) diff --git a/anyway/parsers/news_flash.py b/anyway/parsers/news_flash.py index 4d2191dd..88e20b66 100644 --- a/anyway/parsers/news_flash.py +++ b/anyway/parsers/news_flash.py @@ -40,6 +40,7 @@ def update_all_in_db(source=None, newsflash_id=None, use_existing_coordinates_on newsflash=newsflash, use_existing_coordinates_only=use_existing_coordinates_only, ) + newsflash.set_critical() if i % 1000 == 0: db.commit() db.commit() @@ -56,6 +57,7 @@ def scrape_extract_store_rss(site_name, db): if newsflash.accident: # FIX: No accident-accurate date extracted extract_geo_features(db=db, newsflash=newsflash, use_existing_coordinates_only=False) + newsflash.set_critical() db.insert_new_newsflash(newsflash) @@ -69,6 +71,7 @@ def scrape_extract_store_twitter(screen_name, db): newsflash.organization = classify_organization("twitter") if newsflash.accident: extract_geo_features(db=db, newsflash=newsflash, use_existing_coordinates_only=False) + newsflash.set_critical() db.insert_new_newsflash(newsflash)