artemis-model 0.1.108__py3-none-any.whl → 0.1.110__py3-none-any.whl
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- artemis_model/banned_tracks.py +5 -7
- artemis_model/sqs/messages.py +11 -0
- {artemis_model-0.1.108.dist-info → artemis_model-0.1.110.dist-info}/METADATA +1 -1
- {artemis_model-0.1.108.dist-info → artemis_model-0.1.110.dist-info}/RECORD +5 -5
- {artemis_model-0.1.108.dist-info → artemis_model-0.1.110.dist-info}/WHEEL +0 -0
artemis_model/banned_tracks.py
CHANGED
@@ -1,16 +1,14 @@
|
|
1
1
|
"""Banned Tracks per Zone Model"""
|
2
2
|
|
3
|
-
from sqlalchemy import UUID,
|
4
|
-
|
3
|
+
from sqlalchemy import UUID, Integer
|
4
|
+
from sqlalchemy.orm import Mapped, mapped_column
|
5
5
|
from artemis_model.base import AuditMixin, TimeStampMixin, CustomSyncBase, CustomBase
|
6
6
|
|
7
7
|
|
8
8
|
class BannedTracksMixin(TimeStampMixin, AuditMixin):
|
9
|
-
"""Banned Tracks per Zone Model"""
|
10
|
-
|
11
|
-
|
12
|
-
zone_id: int = Column(Integer, primary_key=True)
|
13
|
-
track_id: UUID = Column(UUID(as_uuid=True), primary_key=True)
|
9
|
+
"""Banned Tracks per Zone Model"""
|
10
|
+
zone_id: Mapped[int] = mapped_column(Integer, primary_key=True)
|
11
|
+
track_id: Mapped[UUID] = mapped_column(UUID(as_uuid=True), primary_key=True)
|
14
12
|
|
15
13
|
|
16
14
|
class BannedTracksSync(CustomSyncBase, BannedTracksMixin):
|
artemis_model/sqs/messages.py
CHANGED
@@ -4,6 +4,8 @@ from datetime import datetime, timezone
|
|
4
4
|
from enum import Enum
|
5
5
|
from typing import Literal
|
6
6
|
|
7
|
+
from sqlalchemy import UUID
|
8
|
+
|
7
9
|
from artemis_model.redis.zone_state import SessionId
|
8
10
|
from artemis_model.schedule import ScheduleItem
|
9
11
|
from pydantic import BaseModel, Field
|
@@ -21,6 +23,7 @@ class Action(str, Enum):
|
|
21
23
|
REFRESH_TRACK_BUCKET = "refresh-track-bucket"
|
22
24
|
RECALCULATE_SCHEDULE = "recalculate-schedule"
|
23
25
|
PLAYER_MODE_CHANGE = "player-mode-change"
|
26
|
+
BAN_TRACK = "ban-track"
|
24
27
|
|
25
28
|
|
26
29
|
class BaseMessage(BaseModel):
|
@@ -89,3 +92,11 @@ class RecalculateScheduleIn(BaseMessage):
|
|
89
92
|
|
90
93
|
action: Action = Action.RECALCULATE_SCHEDULE
|
91
94
|
zone_id: int
|
95
|
+
|
96
|
+
|
97
|
+
class BanTrackIn(BaseMessage):
|
98
|
+
"""Ban track message schema."""
|
99
|
+
|
100
|
+
action: Action = Action.BAN_TRACK
|
101
|
+
zone_id: int
|
102
|
+
track_id: UUID
|
@@ -2,7 +2,7 @@ artemis_model/__init__.py,sha256=H2Cyijmm4KqmjvxJoPpyXZhFvrUZvM0g0X4lDoJ28qw,742
|
|
2
2
|
artemis_model/album.py,sha256=9uw9HVNHVBjl-0Dgv-o5MHXhUPwedvbnbzzY3A1cKQg,2077
|
3
3
|
artemis_model/artist.py,sha256=vjXlFN2mOEidAzUzxmsAP5GnVTvJUuhFdhQaH214lgw,1563
|
4
4
|
artemis_model/auth.py,sha256=0Yg_6N1nj4U31F86u1PE0leIa3D64QlYrsDlavulN6s,4033
|
5
|
-
artemis_model/banned_tracks.py,sha256=
|
5
|
+
artemis_model/banned_tracks.py,sha256=L8w8scdu9GL0Qcuf65HNolhzbqSUXq9TCprUzNtX2AU,665
|
6
6
|
artemis_model/base.py,sha256=zC20m8a1Sa11oEY0ay1iIRQeybGYvXY5p3Vr-pxoKnQ,6802
|
7
7
|
artemis_model/category.py,sha256=jhCZrK-LxPmc0pXmVifAZWdCENssBTzdTmC3nqqZc6s,1761
|
8
8
|
artemis_model/dj_set.py,sha256=fOYnCu4n5TiqyiSojfdFnO7LuPe_mM2SUwBV5xHy2Kc,3782
|
@@ -22,10 +22,10 @@ artemis_model/redis/zone_state.py,sha256=PgHiGUZ2WI3bqO-8CW2cwzLEQu3l4wJAzIABSWE
|
|
22
22
|
artemis_model/schedule.py,sha256=CkLHWz-BwvUY2EQCfoU4SymgCariPzoQdtRLITqBPmk,2451
|
23
23
|
artemis_model/setting.py,sha256=EWzOmE31mLNWwmV_wmqttHPMycvQZW7SJUIozF2b8bo,1190
|
24
24
|
artemis_model/sqs/__init__.py,sha256=nHpXQns64qQ5Cqjyo6w9fDGO_wWhprqn1bhKf3eWnio,17
|
25
|
-
artemis_model/sqs/messages.py,sha256=
|
25
|
+
artemis_model/sqs/messages.py,sha256=vfs3dkJ23-XmKYc-KR2r2AGV5xHmz1-BryoY7YCPQLM,2653
|
26
26
|
artemis_model/track.py,sha256=QwUF0QKVn1I64648B-NI75-IzGQvnLt9B0emD4GnS6E,3757
|
27
27
|
artemis_model/user.py,sha256=eqIdCiBJRNLjCwPPCn-gQ6si0O5JUBGfp9oWJL5zVW4,2131
|
28
28
|
artemis_model/zone.py,sha256=iGRUtzUwKh9LHT3MOfzzg1DnkPBts_ZBzZVTi2EmIgs,2282
|
29
|
-
artemis_model-0.1.
|
30
|
-
artemis_model-0.1.
|
31
|
-
artemis_model-0.1.
|
29
|
+
artemis_model-0.1.110.dist-info/METADATA,sha256=tmt8qF2oZcWljXRQ4g2NEeGKQ4kFCMM8q7vmt6F0Wyo,3445
|
30
|
+
artemis_model-0.1.110.dist-info/WHEEL,sha256=b4K_helf-jlQoXBBETfwnf4B04YC67LOev0jo4fX5m8,88
|
31
|
+
artemis_model-0.1.110.dist-info/RECORD,,
|
File without changes
|