Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
21 commits
Select commit Hold shift + click to select a range
7c4b415
refactor: refactor import process
Jul 14, 2025
bbc6480
feat: implement bulk EAN addition in database
Jul 14, 2025
c477dff
feat: add bulk store addition functionality to database
Jul 14, 2025
ab32f57
refactor: optimize bulk price insertion using CSV format
Jul 14, 2025
845d18f
feat: implement direct CSV streaming for price import to enhance perf…
Jul 14, 2025
dc95ecb
feat: enhance price import process with sequential and parallel EAN h…
Jul 14, 2025
ca91583
fix: improve logging for skipped price rows by including store and pr…
Jul 14, 2025
5ef529f
refactor: clean up code formatting and improve logging in import proc…
Jul 16, 2025
80e1209
fix: enhance error handling and logging in archive import and chain v…
Jul 16, 2025
b309776
fix: ensure idempotent table creation and improve directory handling …
Jul 16, 2025
7288a3a
refactor: clean up whitespace
Jul 16, 2025
057fcc7
refactor: update prices table structure by removing existing constrai…
Jul 18, 2025
3851d3c
Merge branch 'senko:main' into import-parallel
vjekoslav Jul 22, 2025
fc1d547
refactor: remove unnecessary whitespace
Jul 22, 2025
70a1bc3
refactor: simplify table creation logic in import process
Jul 22, 2025
0aec198
refactor: Break down large functions into smaller, focused functions
Jul 22, 2025
3cc9446
refactor: rename functions for clarity
Jul 22, 2025
e41aaa4
refactor: update type hint for optional product fields to allow None
Jul 22, 2025
e10429f
refactor: remove unnecessary whitespac
Jul 22, 2025
0b639be
refactor: add type ignore comment for possibly unbound attribute in C…
Jul 22, 2025
92f2da7
refactor: add type ignore comment for DictReader to handle type checking
Jul 22, 2025
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
26 changes: 26 additions & 0 deletions service/db/base.py
Original file line number Diff line number Diff line change
Expand Up @@ -83,6 +83,19 @@ async def add_store(self, store: Store) -> int:
"""
pass

@abstractmethod
async def add_many_stores(self, stores: list[Store]) -> dict[str, int]:
"""
Add multiple stores in a batch operation.

Args:
stores: List of Store objects to add or update.

Returns:
Dictionary mapping store codes to their database IDs.
"""
pass

@abstractmethod
async def update_store(
self,
Expand Down Expand Up @@ -191,6 +204,19 @@ async def add_ean(self, ean: str) -> int:
"""
pass

@abstractmethod
async def add_many_eans(self, eans: list[str]) -> dict[str, int]:
"""
Add multiple empty products with only EAN codes in a batch operation.

Args:
eans: List of EAN codes to add.

Returns:
Dictionary mapping EAN codes to their database IDs.
"""
pass

@abstractmethod
async def get_products_by_ean(self, ean: list[str]) -> list[ProductWithId]:
"""
Expand Down
Loading
Loading