gazu 0.10.17__py2.py3-none-any.whl → 0.10.18__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/asset.py +11 -7
- gazu/events.py +18 -0
- gazu/scene.py +6 -2
- {gazu-0.10.17.dist-info → gazu-0.10.18.dist-info}/METADATA +2 -1
- {gazu-0.10.17.dist-info → gazu-0.10.18.dist-info}/RECORD +9 -9
- {gazu-0.10.17.dist-info → gazu-0.10.18.dist-info}/LICENSE +0 -0
- {gazu-0.10.17.dist-info → gazu-0.10.18.dist-info}/WHEEL +0 -0
- {gazu-0.10.17.dist-info → gazu-0.10.18.dist-info}/top_level.txt +0 -0
gazu/__version__.py
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
__version__ = "0.10.
|
|
1
|
+
__version__ = "0.10.18"
|
gazu/asset.py
CHANGED
|
@@ -166,7 +166,7 @@ def new_asset(
|
|
|
166
166
|
project,
|
|
167
167
|
asset_type,
|
|
168
168
|
name,
|
|
169
|
-
description=
|
|
169
|
+
description=None,
|
|
170
170
|
extra_data={},
|
|
171
171
|
episode=None,
|
|
172
172
|
client=default,
|
|
@@ -189,7 +189,10 @@ def new_asset(
|
|
|
189
189
|
asset_type = normalize_model_parameter(asset_type)
|
|
190
190
|
episode = normalize_model_parameter(episode)
|
|
191
191
|
|
|
192
|
-
data = {"name": name, "
|
|
192
|
+
data = {"name": name, "data": extra_data}
|
|
193
|
+
|
|
194
|
+
if description is not None:
|
|
195
|
+
data["description"] = description
|
|
193
196
|
|
|
194
197
|
if episode is not None:
|
|
195
198
|
data["episode_id"] = episode["id"]
|
|
@@ -449,7 +452,7 @@ def all_asset_instances_for_asset(asset, client=default):
|
|
|
449
452
|
|
|
450
453
|
|
|
451
454
|
def new_asset_asset_instance(
|
|
452
|
-
asset, asset_to_instantiate, description=
|
|
455
|
+
asset, asset_to_instantiate, description=None, client=default
|
|
453
456
|
):
|
|
454
457
|
"""
|
|
455
458
|
Creates a new asset instance for given asset. The instance number is
|
|
@@ -465,10 +468,11 @@ def new_asset_asset_instance(
|
|
|
465
468
|
"""
|
|
466
469
|
asset = normalize_model_parameter(asset)
|
|
467
470
|
asset_to_instantiate = normalize_model_parameter(asset_to_instantiate)
|
|
468
|
-
data = {
|
|
469
|
-
|
|
470
|
-
|
|
471
|
-
|
|
471
|
+
data = {"asset_to_instantiate_id": asset_to_instantiate["id"]}
|
|
472
|
+
|
|
473
|
+
if description is not None:
|
|
474
|
+
data["description"] = description
|
|
475
|
+
|
|
472
476
|
return raw.post(
|
|
473
477
|
"data/assets/%s/asset-asset-instances" % asset["id"],
|
|
474
478
|
data,
|
gazu/events.py
CHANGED
|
@@ -7,7 +7,25 @@ if sys.version_info[0] == 2:
|
|
|
7
7
|
from .exception import AuthFailedException
|
|
8
8
|
from .client import default_client, get_event_host
|
|
9
9
|
from gazu.client import make_auth_header
|
|
10
|
+
from engineio.base_client import signal_handler
|
|
10
11
|
import socketio
|
|
12
|
+
import os
|
|
13
|
+
import inspect
|
|
14
|
+
import signal
|
|
15
|
+
import socketio
|
|
16
|
+
|
|
17
|
+
if os.name == "nt":
|
|
18
|
+
from win32api import SetConsoleCtrlHandler
|
|
19
|
+
|
|
20
|
+
def WindowsSignalHandler(event):
|
|
21
|
+
if event == 0:
|
|
22
|
+
try:
|
|
23
|
+
signal_handler(signal.SIGINT, inspect.currentframe())
|
|
24
|
+
except:
|
|
25
|
+
# SetConsoleCtrlHandler handle cannot raise exceptions
|
|
26
|
+
pass
|
|
27
|
+
|
|
28
|
+
SetConsoleCtrlHandler(WindowsSignalHandler, 1)
|
|
11
29
|
|
|
12
30
|
|
|
13
31
|
class EventsNamespace(socketio.ClientNamespace):
|
gazu/scene.py
CHANGED
|
@@ -85,14 +85,18 @@ def update_scene(scene, client=default):
|
|
|
85
85
|
return raw.put("data/entities/%s" % scene["id"], scene, client=client)
|
|
86
86
|
|
|
87
87
|
|
|
88
|
-
def new_scene_asset_instance(scene, asset, description=
|
|
88
|
+
def new_scene_asset_instance(scene, asset, description=None, client=default):
|
|
89
89
|
"""
|
|
90
90
|
Creates a new asset instance on given scene. The instance number is
|
|
91
91
|
automatically generated (increment highest number).
|
|
92
92
|
"""
|
|
93
93
|
scene = normalize_model_parameter(scene)
|
|
94
94
|
asset = normalize_model_parameter(asset)
|
|
95
|
-
data = {"asset_id": asset["id"]
|
|
95
|
+
data = {"asset_id": asset["id"]}
|
|
96
|
+
|
|
97
|
+
if description is not None:
|
|
98
|
+
data["description"] = description
|
|
99
|
+
|
|
96
100
|
return raw.post(
|
|
97
101
|
"data/scenes/%s/asset-instances" % scene["id"], data, client=client
|
|
98
102
|
)
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.1
|
|
2
2
|
Name: gazu
|
|
3
|
-
Version: 0.10.
|
|
3
|
+
Version: 0.10.18
|
|
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
|
|
@@ -28,6 +28,7 @@ License-File: LICENSE
|
|
|
28
28
|
Requires-Dist: requests >=2.25.1
|
|
29
29
|
Requires-Dist: Deprecated ==1.2.14
|
|
30
30
|
Requires-Dist: python-socketio[client] <6,>=5.11.0 ; python_version != "2.7"
|
|
31
|
+
Requires-Dist: pywin32 >=308 ; sys_platform == "win32" and python_version != "2.7"
|
|
31
32
|
Provides-Extra: dev
|
|
32
33
|
Requires-Dist: wheel ; extra == 'dev'
|
|
33
34
|
Provides-Extra: lint
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
gazu/__init__.py,sha256=gVhtpZsvDiPuqvsEbCrgm6fKw8hluUhqspmlgGNIAvQ,3020
|
|
2
|
-
gazu/__version__.py,sha256=
|
|
3
|
-
gazu/asset.py,sha256=
|
|
2
|
+
gazu/__version__.py,sha256=v-1GqQyIvDmQj5EPtDb_ZdYDNlTzy0taZU1A8TSJZ9o,24
|
|
3
|
+
gazu/asset.py,sha256=2D7_2fFElfkS6DrHVh0FI-1H73-vhX7VuYCjRgQPVJ0,14564
|
|
4
4
|
gazu/cache.py,sha256=MnxrnfYN7wHNTTL7qzkEpYCYzWcolT56fqQ0_RegMbE,5879
|
|
5
5
|
gazu/casting.py,sha256=0LTdsHaCTHSKEflBWFeuraSaYNYetGkMHAIdg6Lv81U,5059
|
|
6
6
|
gazu/client.py,sha256=1Ak9gXp-3tTAHgXYzY_y5CVt1vQjocvtkOGgOrEe_PY,15527
|
|
@@ -9,21 +9,21 @@ gazu/context.py,sha256=iUyug8EUz3kkF-kmYlH5JuLp66TUqR3uhAq7CouVd_U,4349
|
|
|
9
9
|
gazu/edit.py,sha256=sPSsnzykGr1Htl6ceKulUSVHGhoQLGLeWDni3Pul7BE,4609
|
|
10
10
|
gazu/encoder.py,sha256=dj8U5mlGVy0GeaA7HIIdPSRdKswUQ8h4DzjFKLhwvR0,394
|
|
11
11
|
gazu/entity.py,sha256=Pbc_sbgo8RhQV88nksP1whHyWL4hVyHR3CZ0sVplPY4,3670
|
|
12
|
-
gazu/events.py,sha256=
|
|
12
|
+
gazu/events.py,sha256=x8zlxQuXq68OXyGsosMRPDea7FNDKN6g0o9XWQ_JZRo,2198
|
|
13
13
|
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
17
|
gazu/playlist.py,sha256=fzrhVY0fhxp5rSlvrowZPWEOqdl4rEYD4TKmnuvyKHg,6740
|
|
18
18
|
gazu/project.py,sha256=fssI_Bf5UqqRd9bfM68oyfkhjxwWvjdiAcYvvUhI5LY,12649
|
|
19
|
-
gazu/scene.py,sha256=
|
|
19
|
+
gazu/scene.py,sha256=Q4AVmiMfGhSZfaXwOceyR-taTlpx1WCELe0UBSiHm8o,5357
|
|
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
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.18.dist-info/LICENSE,sha256=2n6rt7r999OuXp8iOqW9we7ORaxWncIbOwN1ILRGR2g,7651
|
|
26
|
+
gazu-0.10.18.dist-info/METADATA,sha256=H4FbrMCVtfD2fkwcHAW0nPla_1A-kSgSMOaj-nxaR8g,5347
|
|
27
|
+
gazu-0.10.18.dist-info/WHEEL,sha256=0VNUDWQJzfRahYI3neAhz2UVbRCtztpN5dPHAGvmGXc,109
|
|
28
|
+
gazu-0.10.18.dist-info/top_level.txt,sha256=nv7fRIVpYYyIlk_66hBmMyvWcSC7UU-r-GE8uC1u1Go,5
|
|
29
|
+
gazu-0.10.18.dist-info/RECORD,,
|
|
File without changes
|
|
File without changes
|
|
File without changes
|