zou 0.20.59__py3-none-any.whl → 0.20.61__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.
zou/__init__.py CHANGED
@@ -1 +1 @@
1
- __version__ = "0.20.59"
1
+ __version__ = "0.20.61"
@@ -99,3 +99,14 @@ class PreviewFile(db.Model, BaseMixin, SerializerMixin):
99
99
  "created_at": self.created_at,
100
100
  }
101
101
  )
102
+
103
+ def present_minimal(self):
104
+ return fields.serialize_dict(
105
+ {
106
+ "id": self.id,
107
+ "name": self.name,
108
+ "extension": self.extension,
109
+ "revision": self.revision,
110
+ "position": self.position,
111
+ }
112
+ )
@@ -169,6 +169,7 @@ def get_last_news_for_project(
169
169
  Task.entity_id,
170
170
  PreviewFile.extension,
171
171
  PreviewFile.annotations,
172
+ PreviewFile.revision,
172
173
  Entity.preview_file_id,
173
174
  )
174
175
 
@@ -187,6 +188,7 @@ def get_last_news_for_project(
187
188
  task_entity_id,
188
189
  preview_file_extension,
189
190
  preview_file_annotations,
191
+ preview_file_revision,
190
192
  entity_preview_file_id,
191
193
  ) in news_list:
192
194
  full_entity_name, episode_id, _ = names_service.get_full_entity_name(
@@ -206,7 +208,7 @@ def get_last_news_for_project(
206
208
  "task_entity_id": task_entity_id,
207
209
  "preview_file_id": news.preview_file_id,
208
210
  "preview_file_extension": preview_file_extension,
209
- "preview_file_annotations": preview_file_annotations,
211
+ "preview_file_revision": preview_file_revision,
210
212
  "project_id": project_id,
211
213
  "project_name": project_name,
212
214
  "created_at": news.created_at,
@@ -217,6 +219,30 @@ def get_last_news_for_project(
217
219
  }
218
220
  )
219
221
  )
222
+
223
+ if only_preview:
224
+ task_ids = [
225
+ news["task_id"] for news in result if news["task_id"] is not None
226
+ ]
227
+ revisions = [news["preview_file_revision"] for news in result]
228
+ preview_files = (
229
+ PreviewFile.query.filter(PreviewFile.task_id.in_(task_ids))
230
+ .filter(PreviewFile.revision.in_(revisions))
231
+ .order_by(
232
+ PreviewFile.task_id, PreviewFile.revision, PreviewFile.position
233
+ )
234
+ )
235
+ preview_files_map = {}
236
+ for preview_file in preview_files:
237
+ key = f"{str(preview_file.task_id)}-{preview_file.revision}"
238
+ if not key in preview_files_map:
239
+ preview_files_map[key] = []
240
+ preview_files_map[key].append(preview_file.present_minimal())
241
+
242
+ for entry in result:
243
+ key = f"{entry['task_id']}-{entry['preview_file_revision']}"
244
+ entry["preview_files"] = preview_files_map[key]
245
+
220
246
  return {
221
247
  "data": result,
222
248
  "total": total,
zou/event_stream.py CHANGED
@@ -267,7 +267,6 @@ def on_change_version(data):
267
267
  emit("preview-room:comparison-panzoom-changed", data, room=room_id)
268
268
 
269
269
 
270
-
271
270
  if __name__ == "__main__":
272
271
  socketio.run(
273
272
  app,
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: zou
3
- Version: 0.20.59
3
+ Version: 0.20.61
4
4
  Summary: API to store and manage the data of your animation production
5
5
  Home-page: https://zou.cg-wire.com
6
6
  Author: CG Wire
@@ -53,7 +53,7 @@ Requires-Dist: numpy==2.2.6
53
53
  Requires-Dist: opencv-python==4.12.0.88
54
54
  Requires-Dist: OpenTimelineIO==0.17.0
55
55
  Requires-Dist: OpenTimelineIO-Plugins==0.17.0
56
- Requires-Dist: orjson==3.10.18
56
+ Requires-Dist: orjson==3.11.0
57
57
  Requires-Dist: pillow==11.3.0
58
58
  Requires-Dist: psutil==7.0.0
59
59
  Requires-Dist: psycopg[binary]==3.2.9
@@ -65,7 +65,7 @@ Requires-Dist: python-socketio==5.13.0
65
65
  Requires-Dist: pytz==2025.2
66
66
  Requires-Dist: redis==5.2.1
67
67
  Requires-Dist: requests==2.32.4
68
- Requires-Dist: rq==2.4.0
68
+ Requires-Dist: rq==2.4.1
69
69
  Requires-Dist: semver==3.0.4
70
70
  Requires-Dist: slackclient==2.9.4
71
71
  Requires-Dist: spdx-license-list==3.27.0
@@ -88,7 +88,7 @@ Requires-Dist: pytest==8.4.1; extra == "test"
88
88
  Provides-Extra: monitoring
89
89
  Requires-Dist: prometheus-flask-exporter==0.23.2; extra == "monitoring"
90
90
  Requires-Dist: pygelf==0.4.3; extra == "monitoring"
91
- Requires-Dist: sentry-sdk==2.32.0; extra == "monitoring"
91
+ Requires-Dist: sentry-sdk==2.33.2; extra == "monitoring"
92
92
  Provides-Extra: lint
93
93
  Requires-Dist: autoflake==2.3.1; extra == "lint"
94
94
  Requires-Dist: black==25.1.0; extra == "lint"
@@ -1,7 +1,7 @@
1
- zou/__init__.py,sha256=31liBOsQexhNsR3sYFhpdTmwrvjCEHROh_85aI2LtYg,24
1
+ zou/__init__.py,sha256=HVP6QxBsnnZAb4guN788yYq1qR4UpkvbI_EYcOB5eNo,24
2
2
  zou/cli.py,sha256=W7nhMII-gyl8AlL6zgDmverSdFphDV_WnuN3BHrHc8w,22448
3
3
  zou/debug.py,sha256=1fawPbkD4wn0Y9Gk0BiBFSa-CQe5agFi8R9uJYl2Uyk,520
4
- zou/event_stream.py,sha256=YOWVGAgseVQKC6usoYDW4T9iRVrG7R8TvP-Nr2AKi6k,8576
4
+ zou/event_stream.py,sha256=9O1PE_vDW8p3yfHJNSZ8w0ybD-660x8oGN0izgJdTjM,8575
5
5
  zou/job_settings.py,sha256=_aqBhujt2Q8sXRWIbgbDf-LUdXRdBimdtTc-fZbiXoY,202
6
6
  zou/app/__init__.py,sha256=zGmaBGBHSS_Px34I3_WZmcse62G_AZJArjm4F6TwmRk,7100
7
7
  zou/app/api.py,sha256=Esgni_0-tAaE3msWxNMEdUS_wwIdElM0P2GrjhaHbCk,3727
@@ -169,7 +169,7 @@ zou/app/models/person.py,sha256=xRjoPL2OayjmwUJcvbD7BJY7atxm-daIzPfEhgr5LbU,8107
169
169
  zou/app/models/playlist.py,sha256=YGgAk84u0_fdIEY02Dal4kfk8APVZvWFwWYV74qvrio,1503
170
170
  zou/app/models/plugin.py,sha256=zNs9Qi1h_v_6edZs5GHRSKItaAG4Gnlk1FQKumiiv68,766
171
171
  zou/app/models/preview_background_file.py,sha256=j8LgRmY7INnlB07hFwwB-8ssQrRC8vsb8VcpsTbt6tA,559
172
- zou/app/models/preview_file.py,sha256=eDPXw0QIdJze_E4kAS8SsyabrefWhIIdwuGmjss7iXo,3282
172
+ zou/app/models/preview_file.py,sha256=ofN0aTvjc7eYBMj7OjUs3Yhw9_HZGOYB9ftbH3XAVCM,3587
173
173
  zou/app/models/project.py,sha256=mXoLK7fEwDRGd21AoQadgV9K0AgoxYwTb5Sdf_cezlY,9203
174
174
  zou/app/models/project_status.py,sha256=pExaHH7x4Eu8xOqD3_mRRbMzjT2jJZ8rm-9jo7yUGXA,390
175
175
  zou/app/models/salary_scale.py,sha256=3TaOtgJkGq2sPUAmE9nbzAqgkPzZYiSLZw-YSv-oLyc,814
@@ -207,7 +207,7 @@ zou/app/services/file_tree_service.py,sha256=8JNBDgnXtV-AmSJ3gnUGB4oSwLjPgi1WYyL
207
207
  zou/app/services/files_service.py,sha256=df1_9v-vwE5HVi9XjtilTPWHuiWunvrwPyQh_IXupNM,28517
208
208
  zou/app/services/index_service.py,sha256=IaffQz_oj6GPEbuDp4a2qnSc6n-hhIcmA_LrTm3Wots,10201
209
209
  zou/app/services/names_service.py,sha256=TOSrintROmxcAlcFQE0i2E3PBLnw81GAztNselpTn18,2947
210
- zou/app/services/news_service.py,sha256=eOXkvLhOcgncI2NrgiJEccV28oxZX5CsZVqaE-l4kWQ,9084
210
+ zou/app/services/news_service.py,sha256=uYzk8PwJ6khWy6OCnTFx4Su5yQkPXMJ5Qu4MSDDFj8U,10097
211
211
  zou/app/services/notifications_service.py,sha256=7GDRio_mGaRYV5BHOAdpxBZjA_LLYUfVpbwZqy1n9pI,15685
212
212
  zou/app/services/persons_service.py,sha256=HjV-su80Y2BO9l5zoBKHMNF0mDGtkWqPhEOs3nQ3nlI,16566
213
213
  zou/app/services/playlists_service.py,sha256=IKjvT3RZigwXsrhsRFqaWWlm-tZSN6-jgMDf0Hn3w3Q,33179
@@ -447,9 +447,9 @@ zou/remote/normalize_movie.py,sha256=zNfEY3N1UbAHZfddGONTg2Sff3ieLVWd4dfZa1dpnes
447
447
  zou/remote/playlist.py,sha256=AsDo0bgYhDcd6DfNRV6r6Jj3URWwavE2ZN3VkKRPbLU,3293
448
448
  zou/utils/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
449
449
  zou/utils/movie.py,sha256=d67fIL9dVBKt-E_qCGXRbNNdbJaJR5sHvZeX3hf8ldE,16559
450
- zou-0.20.59.dist-info/licenses/LICENSE,sha256=dql8h4yceoMhuzlcK0TT_i-NgTFNIZsgE47Q4t3dUYI,34520
451
- zou-0.20.59.dist-info/METADATA,sha256=OJ352VnH675IpJvqelgd9HEJYuJ0o_WwFV-UfFrjVy4,6698
452
- zou-0.20.59.dist-info/WHEEL,sha256=_zCd3N1l69ArxyTb8rzEoP9TpbYXkqRFSNOD5OuxnTs,91
453
- zou-0.20.59.dist-info/entry_points.txt,sha256=PelQoIx3qhQ_Tmne7wrLY-1m2izuzgpwokoURwSohy4,130
454
- zou-0.20.59.dist-info/top_level.txt,sha256=4S7G_jk4MzpToeDItHGjPhHx_fRdX52zJZWTD4SL54g,4
455
- zou-0.20.59.dist-info/RECORD,,
450
+ zou-0.20.61.dist-info/licenses/LICENSE,sha256=dql8h4yceoMhuzlcK0TT_i-NgTFNIZsgE47Q4t3dUYI,34520
451
+ zou-0.20.61.dist-info/METADATA,sha256=2Ip8kSrQE3ojU3BuHuDKRGMPmebh6QBQaRndG6pNmYE,6697
452
+ zou-0.20.61.dist-info/WHEEL,sha256=_zCd3N1l69ArxyTb8rzEoP9TpbYXkqRFSNOD5OuxnTs,91
453
+ zou-0.20.61.dist-info/entry_points.txt,sha256=PelQoIx3qhQ_Tmne7wrLY-1m2izuzgpwokoURwSohy4,130
454
+ zou-0.20.61.dist-info/top_level.txt,sha256=4S7G_jk4MzpToeDItHGjPhHx_fRdX52zJZWTD4SL54g,4
455
+ zou-0.20.61.dist-info/RECORD,,
File without changes