gazu 0.10.15__py2.py3-none-any.whl → 0.10.16__py2.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.
- gazu/__version__.py +1 -1
- gazu/casting.py +4 -1
- gazu/playlist.py +11 -21
- gazu/task.py +3 -23
- {gazu-0.10.15.dist-info → gazu-0.10.16.dist-info}/METADATA +3 -3
- {gazu-0.10.15.dist-info → gazu-0.10.16.dist-info}/RECORD +9 -9
- {gazu-0.10.15.dist-info → gazu-0.10.16.dist-info}/WHEEL +1 -1
- {gazu-0.10.15.dist-info → gazu-0.10.16.dist-info}/LICENSE +0 -0
- {gazu-0.10.15.dist-info → gazu-0.10.16.dist-info}/top_level.txt +0 -0
gazu/__version__.py
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
__version__ = "0.10.
|
|
1
|
+
__version__ = "0.10.16"
|
gazu/casting.py
CHANGED
|
@@ -60,7 +60,10 @@ def update_episode_casting(project, episode, casting, client=default):
|
|
|
60
60
|
"""
|
|
61
61
|
episode = normalize_model_parameter(episode)
|
|
62
62
|
project = normalize_model_parameter(project)
|
|
63
|
-
path = "data/projects/%s/entities/%s/casting" % (
|
|
63
|
+
path = "data/projects/%s/entities/%s/casting" % (
|
|
64
|
+
project["id"],
|
|
65
|
+
episode["id"],
|
|
66
|
+
)
|
|
64
67
|
return raw.put(path, casting, client=client)
|
|
65
68
|
|
|
66
69
|
|
gazu/playlist.py
CHANGED
|
@@ -166,16 +166,12 @@ def get_entity_preview_files(entity, client=default):
|
|
|
166
166
|
entity = normalize_model_parameter(entity)
|
|
167
167
|
return raw.get(
|
|
168
168
|
"data/playlists/entities/%s/preview-files" % entity["id"],
|
|
169
|
-
client=client
|
|
169
|
+
client=client,
|
|
170
170
|
)
|
|
171
171
|
|
|
172
172
|
|
|
173
173
|
def add_entity_to_playlist(
|
|
174
|
-
playlist,
|
|
175
|
-
entity,
|
|
176
|
-
preview_file=None,
|
|
177
|
-
persist=True,
|
|
178
|
-
client=default
|
|
174
|
+
playlist, entity, preview_file=None, persist=True, client=default
|
|
179
175
|
):
|
|
180
176
|
"""
|
|
181
177
|
Add an entity to the playlist, use the last uploaded preview as revision
|
|
@@ -197,25 +193,23 @@ def add_entity_to_playlist(
|
|
|
197
193
|
for task_type_id in preview_files.keys():
|
|
198
194
|
task_type_files = preview_files[task_type_id]
|
|
199
195
|
first_file = task_type_files[0]
|
|
200
|
-
if
|
|
201
|
-
|
|
196
|
+
if (
|
|
197
|
+
preview_file is None
|
|
198
|
+
or preview_file["created_at"] < first_file["created_at"]
|
|
199
|
+
):
|
|
202
200
|
preview_file = first_file
|
|
203
201
|
|
|
204
202
|
preview_file = normalize_model_parameter(preview_file)
|
|
205
|
-
playlist["shots"].append(
|
|
206
|
-
"entity_id": entity["id"],
|
|
207
|
-
|
|
208
|
-
})
|
|
203
|
+
playlist["shots"].append(
|
|
204
|
+
{"entity_id": entity["id"], "preview_file_id": preview_file["id"]}
|
|
205
|
+
)
|
|
209
206
|
if persist:
|
|
210
207
|
update_playlist(playlist, client=client)
|
|
211
208
|
return playlist
|
|
212
209
|
|
|
213
210
|
|
|
214
211
|
def remove_entity_from_playlist(
|
|
215
|
-
playlist,
|
|
216
|
-
entity,
|
|
217
|
-
persist=True,
|
|
218
|
-
client=default
|
|
212
|
+
playlist, entity, persist=True, client=default
|
|
219
213
|
):
|
|
220
214
|
"""
|
|
221
215
|
Remove all occurences of a given entity from a playlist.
|
|
@@ -239,11 +233,7 @@ def remove_entity_from_playlist(
|
|
|
239
233
|
|
|
240
234
|
|
|
241
235
|
def update_entity_preview(
|
|
242
|
-
playlist,
|
|
243
|
-
entity,
|
|
244
|
-
preview_file,
|
|
245
|
-
persist=True,
|
|
246
|
-
client=default
|
|
236
|
+
playlist, entity, preview_file, persist=True, client=default
|
|
247
237
|
):
|
|
248
238
|
"""
|
|
249
239
|
Remove all occurences of a given entity from a playlist.
|
gazu/task.py
CHANGED
|
@@ -257,12 +257,7 @@ def all_tasks_for_task_status(project, task_type, task_status, client=default):
|
|
|
257
257
|
|
|
258
258
|
|
|
259
259
|
@cache
|
|
260
|
-
def all_tasks_for_task_type(
|
|
261
|
-
project,
|
|
262
|
-
task_type,
|
|
263
|
-
episode=None,
|
|
264
|
-
client=default
|
|
265
|
-
):
|
|
260
|
+
def all_tasks_for_task_type(project, task_type, episode=None, client=default):
|
|
266
261
|
"""
|
|
267
262
|
Args:
|
|
268
263
|
project (str / dict): The project dict or the project ID.
|
|
@@ -532,18 +527,6 @@ def get_task_status_by_name(name, client=default):
|
|
|
532
527
|
return raw.fetch_first("task-status", {"name": name}, client=client)
|
|
533
528
|
|
|
534
529
|
|
|
535
|
-
@cache
|
|
536
|
-
def get_default_task_status(client=default):
|
|
537
|
-
"""
|
|
538
|
-
Args:
|
|
539
|
-
name (str / dict): The name of claimed task status.
|
|
540
|
-
|
|
541
|
-
Returns:
|
|
542
|
-
dict: Task status matching given name.
|
|
543
|
-
"""
|
|
544
|
-
return raw.fetch_first("task-status", {"is_default": True}, client=client)
|
|
545
|
-
|
|
546
|
-
|
|
547
530
|
@cache
|
|
548
531
|
def get_task_status_by_short_name(task_status_short_name, client=default):
|
|
549
532
|
"""
|
|
@@ -661,7 +644,7 @@ def new_task(
|
|
|
661
644
|
entity = normalize_model_parameter(entity)
|
|
662
645
|
task_type = normalize_model_parameter(task_type)
|
|
663
646
|
if task_status is None:
|
|
664
|
-
task_status = get_default_task_status()
|
|
647
|
+
task_status = get_default_task_status(client=client)
|
|
665
648
|
|
|
666
649
|
data = {
|
|
667
650
|
"project_id": entity["project_id"],
|
|
@@ -1267,10 +1250,7 @@ def get_task_url(task, client=default):
|
|
|
1267
1250
|
|
|
1268
1251
|
|
|
1269
1252
|
def all_tasks_for_project(
|
|
1270
|
-
project,
|
|
1271
|
-
task_type=None,
|
|
1272
|
-
episode=None,
|
|
1273
|
-
client=default
|
|
1253
|
+
project, task_type=None, episode=None, client=default
|
|
1274
1254
|
):
|
|
1275
1255
|
"""
|
|
1276
1256
|
Args:
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.1
|
|
2
2
|
Name: gazu
|
|
3
|
-
Version: 0.10.
|
|
3
|
+
Version: 0.10.16
|
|
4
4
|
Summary: Gazu is a client for Zou, the API to store the data of your CG production.
|
|
5
5
|
Home-page: https://gazu.cg-wire.com/
|
|
6
6
|
Author: CG Wire
|
|
@@ -32,8 +32,8 @@ Provides-Extra: dev
|
|
|
32
32
|
Requires-Dist: wheel ; extra == 'dev'
|
|
33
33
|
Provides-Extra: lint
|
|
34
34
|
Requires-Dist: autoflake ==2.3.1 ; (python_version >= "3.8") and extra == 'lint'
|
|
35
|
-
Requires-Dist: black ==24.
|
|
36
|
-
Requires-Dist: pre-commit ==
|
|
35
|
+
Requires-Dist: black ==24.10.0 ; (python_version >= "3.9") and extra == 'lint'
|
|
36
|
+
Requires-Dist: pre-commit ==4.0.1 ; (python_version >= "3.9") and extra == 'lint'
|
|
37
37
|
Provides-Extra: test
|
|
38
38
|
Requires-Dist: pytest ; extra == 'test'
|
|
39
39
|
Requires-Dist: pytest-cov ; extra == 'test'
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
gazu/__init__.py,sha256=gVhtpZsvDiPuqvsEbCrgm6fKw8hluUhqspmlgGNIAvQ,3020
|
|
2
|
-
gazu/__version__.py,sha256=
|
|
2
|
+
gazu/__version__.py,sha256=42JGoIUYC3OTcHv48Vyebrqa1zvt0Ul05GgS6njtjLQ,24
|
|
3
3
|
gazu/asset.py,sha256=GWwam0yqHna_b9_5g5r0-O2zhMb7KlhfbIC17IOXKkY,14488
|
|
4
4
|
gazu/cache.py,sha256=MnxrnfYN7wHNTTL7qzkEpYCYzWcolT56fqQ0_RegMbE,5879
|
|
5
|
-
gazu/casting.py,sha256=
|
|
5
|
+
gazu/casting.py,sha256=0LTdsHaCTHSKEflBWFeuraSaYNYetGkMHAIdg6Lv81U,5059
|
|
6
6
|
gazu/client.py,sha256=YRIxX7u095XTe28JM0tMZ05WoTcYexJGS2jrxXSAQvs,14640
|
|
7
7
|
gazu/concept.py,sha256=GcOPEmkbtZcSwlX8tnUj9Q5DTPBprSxtmXhlq7ioPwk,3727
|
|
8
8
|
gazu/context.py,sha256=iUyug8EUz3kkF-kmYlH5JuLp66TUqR3uhAq7CouVd_U,4349
|
|
@@ -14,16 +14,16 @@ gazu/exception.py,sha256=Y0kVNm6h-uXLEU1sNIbMSUep7Zxk738uYHOIVs2waM8,1880
|
|
|
14
14
|
gazu/files.py,sha256=L82d5Bx3TkcaNczQ5t9s8DTKAcYXiqGaKUrag2cKjqI,39645
|
|
15
15
|
gazu/helpers.py,sha256=Qa4JlZitiXsfYMJGGuwVaedLvHQVMbIwcqEZ099EjMw,3916
|
|
16
16
|
gazu/person.py,sha256=BFh54J_R6_pIgYxAF_yAxFzjsO98hTLeBAKiZxewiK0,11098
|
|
17
|
-
gazu/playlist.py,sha256=
|
|
17
|
+
gazu/playlist.py,sha256=fzrhVY0fhxp5rSlvrowZPWEOqdl4rEYD4TKmnuvyKHg,6740
|
|
18
18
|
gazu/project.py,sha256=fssI_Bf5UqqRd9bfM68oyfkhjxwWvjdiAcYvvUhI5LY,12649
|
|
19
19
|
gazu/scene.py,sha256=bYsy7zKdQfDTfeqNAlgaqGMs2Hhxdy40NGt6TX_FBdA,5307
|
|
20
20
|
gazu/shot.py,sha256=mHg-8B7xk3PXMqbPo0oCx2X7br2sGCBmuM7hEhpXRas,18942
|
|
21
21
|
gazu/sorting.py,sha256=qSIO0pOHkj0Tl4gm9BJrYrcifWGGGmsW68Pl86zB_bg,266
|
|
22
22
|
gazu/sync.py,sha256=0ZJ5Z7Nuh5Kj4cswZCXLpXTLf8zQRcXsBLnurMw-i_E,21627
|
|
23
|
-
gazu/task.py,sha256=
|
|
23
|
+
gazu/task.py,sha256=rnOKunR-vXLQPkD5nOufPhppYLLkgAWZS9tYlutCMp0,36412
|
|
24
24
|
gazu/user.py,sha256=GyJf6mrynHvLllw3Hsiv-6wjaYTHO_PBNkJzyJjJA1A,9556
|
|
25
|
-
gazu-0.10.
|
|
26
|
-
gazu-0.10.
|
|
27
|
-
gazu-0.10.
|
|
28
|
-
gazu-0.10.
|
|
29
|
-
gazu-0.10.
|
|
25
|
+
gazu-0.10.16.dist-info/LICENSE,sha256=2n6rt7r999OuXp8iOqW9we7ORaxWncIbOwN1ILRGR2g,7651
|
|
26
|
+
gazu-0.10.16.dist-info/METADATA,sha256=izhNmWl2_06y8RzzDu1iLROBuFhKJU3R8_HJX0Rb3-Y,5264
|
|
27
|
+
gazu-0.10.16.dist-info/WHEEL,sha256=AHX6tWk3qWuce7vKLrj7lnulVHEdWoltgauo8bgCXgU,109
|
|
28
|
+
gazu-0.10.16.dist-info/top_level.txt,sha256=nv7fRIVpYYyIlk_66hBmMyvWcSC7UU-r-GE8uC1u1Go,5
|
|
29
|
+
gazu-0.10.16.dist-info/RECORD,,
|
|
File without changes
|
|
File without changes
|