Cannot add sets #62

Closed
opened 2025-02-08 08:03:40 +01:00 by FrederikBaerentsen · 4 comments

On my local test install, 1.2.0 works without issues, but after updating the docker image, my production install gives me error:

Error: Error while importing set 10294-1: Set storages with ID None was not found in the database
BrickTracker  |   File "/app/bricktracker/set.py", line 64, in download
BrickTracker  |     storage = BrickSetStorageList.get(
BrickTracker  |         data.get('storage', ''),
BrickTracker  |         allow_none=True
BrickTracker  |     )
BrickTracker  |   File "/app/bricktracker/metadata_list.py", line 123, in get
BrickTracker  |     raise NotFoundException(
BrickTracker  |     ...<4 lines>...
BrickTracker  |     )
BrickTracker  | bricktracker.exceptions.NotFoundException: Set storages with ID None was not found in the database

When i try and add a new set.

On my local test install, 1.2.0 works without issues, but after updating the docker image, my production install gives me error: Error: Error while importing set 10294-1: Set storages with ID None was not found in the database ```` BrickTracker | File "/app/bricktracker/set.py", line 64, in download BrickTracker | storage = BrickSetStorageList.get( BrickTracker | data.get('storage', ''), BrickTracker | allow_none=True BrickTracker | ) BrickTracker | File "/app/bricktracker/metadata_list.py", line 123, in get BrickTracker | raise NotFoundException( BrickTracker | ...<4 lines>... BrickTracker | ) BrickTracker | bricktracker.exceptions.NotFoundException: Set storages with ID None was not found in the database ```` When i try and add a new set.
Author
Owner

This happens if no Purchase location or Storage location is added under Set Metadata in the admin page.

It isn't necessary to select a purchase/storage location when adding a new set, but it is necessary to add the options.

This happens if no Purchase location or Storage location is added under Set Metadata in the admin page. It isn't necessary to select a purchase/storage location when adding a new set, but it is necessary to add the options.
Collaborator

Phew, I was worried that no bug were introduced after so many changes 😂. I'll take a look 😁.

Phew, I was worried that no bug were introduced after so many changes 😂. I'll take a look 😁.
Collaborator

Fixed.
I also added a case in the template to warn that no metadata is configured rather than displaying nothing under Metadata

  • Before

image

  • After

image

Fixed. I also added a case in the template to warn that no metadata is configured rather than displaying nothing under Metadata - Before ![image](/attachments/a04c59a3-bd9d-44c5-bfb7-8910af169721) - After ![image](/attachments/a27405b1-b169-4cb6-8209-13d7811e4daf)
Author
Owner

@gregoo Nice quick fix 👍 Pushed a new version

@gregoo Nice quick fix 👍 Pushed a new version
Sign in to join this conversation.
No description provided.