diff --git a/backend/importers/base.py b/backend/importers/base.py index d18e6d9..fa6e1fd 100644 --- a/backend/importers/base.py +++ b/backend/importers/base.py @@ -30,7 +30,7 @@ class ImporterBase(ABC): VERTICAL_DESCRIPTION: str = "" # Rate limiting - REQUEST_DELAY: float = 0.5 # seconds between requests + REQUEST_DELAY: float = 2.0 # seconds between requests (setlist.fm is strict) # Cache settings CACHE_DIR: Path = Path(__file__).parent / ".cache" diff --git a/backend/run_import.py b/backend/run_import.py index dd7d82f..046261a 100644 --- a/backend/run_import.py +++ b/backend/run_import.py @@ -44,13 +44,14 @@ class DynamicImporter(SetlistFmImporter): self.VERTICAL_SLUG = vertical.slug self.VERTICAL_DESCRIPTION = vertical.description or "" self.ARTIST_MBID = mbid - self._vertical_id = vertical.id + self._vertical_obj = vertical super().__init__(session) def get_or_create_vertical(self): """Override to use existing vertical""" - self.vertical_id = self._vertical_id - return self._vertical_id + self.vertical = self._vertical_obj + self.vertical_id = self._vertical_obj.id + return self._vertical_obj def run_import(slug: str):