zou 0.20.20__py3-none-any.whl → 0.20.21__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.20"
1
+ __version__ = "0.20.21"
@@ -355,7 +355,7 @@ class AssetAssetsResource(Resource):
355
355
  return breakdown_service.get_entity_casting(asset_id)
356
356
 
357
357
 
358
- class AssetTasksResource(Resource):
358
+ class AssetTasksResource(Resource, ArgsMixin):
359
359
  @jwt_required()
360
360
  def get(self, asset_id):
361
361
  """
@@ -376,7 +376,9 @@ class AssetTasksResource(Resource):
376
376
  """
377
377
  asset = assets_service.get_asset(asset_id)
378
378
  user_service.check_project_access(asset["project_id"])
379
- return tasks_service.get_tasks_for_asset(asset_id)
379
+ return tasks_service.get_tasks_for_asset(
380
+ asset_id, relations=self.get_relations()
381
+ )
380
382
 
381
383
 
382
384
  class AssetTaskTypesResource(Resource):
zou/app/utils/commands.py CHANGED
@@ -409,20 +409,29 @@ def sync_with_ldap_server():
409
409
  and persons_service.is_user_limit_reached()
410
410
  ):
411
411
  raise IsUserLimitReachedException
412
- persons_service.update_person(
413
- person["id"],
414
- {
415
- "email": user["email"],
416
- "first_name": user["first_name"],
417
- "last_name": user["last_name"],
418
- "active": user["active"],
419
- "is_generated_from_ldap": True,
420
- "desktop_login": user["desktop_login"],
421
- "ldap_uid": user["ldap_uid"],
422
- },
423
- bypass_protected_accounts=True,
424
- )
425
- print(f"User {user['desktop_login']} updated.")
412
+
413
+ if any(
414
+ user[key] != person[key]
415
+ for key in [
416
+ key
417
+ for key in user.keys()
418
+ if key not in ["thumbnail", "emails"]
419
+ ]
420
+ ):
421
+ persons_service.update_person(
422
+ person["id"],
423
+ {
424
+ "email": user["email"],
425
+ "first_name": user["first_name"],
426
+ "last_name": user["last_name"],
427
+ "active": user["active"],
428
+ "is_generated_from_ldap": True,
429
+ "desktop_login": user["desktop_login"],
430
+ "ldap_uid": user["ldap_uid"],
431
+ },
432
+ bypass_protected_accounts=True,
433
+ )
434
+ print(f"User {user['desktop_login']} updated.")
426
435
  except IsUserLimitReachedException:
427
436
  print(
428
437
  f"User {user['desktop_login']} update failed (limit reached, limit {config.USER_LIMIT})."
zou/cli.py CHANGED
@@ -295,13 +295,13 @@ def sync_with_ldap_server():
295
295
  For each user account in your LDAP server, it creates a new user.
296
296
  """
297
297
  with app.app_context():
298
- commands.sync_with_ldap_server()
299
298
  if persons_service.is_user_limit_reached():
300
299
  print(
301
300
  "User limit reached (limit %i). New users will not be added."
302
301
  % config.USER_LIMIT
303
302
  )
304
303
  sys.exit(1)
304
+ commands.sync_with_ldap_server()
305
305
 
306
306
 
307
307
  @cli.command()
@@ -33,7 +33,9 @@ def upgrade():
33
33
  batch_op.create_index(
34
34
  batch_op.f("ix_comment_updated_by"), ["updated_by"], unique=False
35
35
  )
36
- batch_op.create_foreign_key(None, "person", ["updated_by"], ["id"])
36
+ batch_op.create_foreign_key(
37
+ "comment_updated_by_fkey", "person", ["updated_by"], ["id"]
38
+ )
37
39
 
38
40
  # ### end Alembic commands ###
39
41
 
@@ -41,7 +43,7 @@ def upgrade():
41
43
  def downgrade():
42
44
  # ### commands auto generated by Alembic - please adjust! ###
43
45
  with op.batch_alter_table("comment", schema=None) as batch_op:
44
- batch_op.drop_constraint(None, type_="foreignkey")
46
+ batch_op.drop_constraint("comment_updated_by_fkey", type_="foreignkey")
45
47
  batch_op.drop_index(batch_op.f("ix_comment_updated_by"))
46
48
  batch_op.drop_column("updated_by")
47
49
 
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.2
2
2
  Name: zou
3
- Version: 0.20.20
3
+ Version: 0.20.21
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
@@ -1,5 +1,5 @@
1
- zou/__init__.py,sha256=M80qHAHUScEaOaXSHo-5mDQnYnmzzqcaIvaiBmoOQss,24
2
- zou/cli.py,sha256=8JyGrWm7-Ykshv5IBjwlBMn8JkFpHPCADChA9n8loTI,18755
1
+ zou/__init__.py,sha256=q-f3cQMtYC1aJHq5j-sBq9YJTtfqyzELRPrqcQwksrA,24
2
+ zou/cli.py,sha256=HuYi2Ma7SP2SD7C9d9dwpZ49BHpytKIoyJP_su9JwZY,18755
3
3
  zou/debug.py,sha256=1fawPbkD4wn0Y9Gk0BiBFSa-CQe5agFi8R9uJYl2Uyk,520
4
4
  zou/event_stream.py,sha256=EpohqFJwWL0zs-Ic_W5dX5_XSDeCrqHQPL5Re39OnQ0,6382
5
5
  zou/job_settings.py,sha256=_aqBhujt2Q8sXRWIbgbDf-LUdXRdBimdtTc-fZbiXoY,202
@@ -10,7 +10,7 @@ zou/app/mixin.py,sha256=tvg5ErxKKW0tBweteB0iCg7Y-v4tUMd5RhQ3DoL3qNM,4894
10
10
  zou/app/swagger.py,sha256=Jr7zsMqJi0V4FledODOdu-aqqVE02jMFzhqVxHK0_2c,54158
11
11
  zou/app/blueprints/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
12
12
  zou/app/blueprints/assets/__init__.py,sha256=T2zhDagHjXF6jRwOQ8vqokZTkBHyY7XtTI0Rlooamjs,2931
13
- zou/app/blueprints/assets/resources.py,sha256=Cqdot0vR6ccHNC5b0FVDq2x_Ujankk61N3EKV0A4q3M,25563
13
+ zou/app/blueprints/assets/resources.py,sha256=YIR1n21vsvM-dYPcnXVePU9rlCf1es-Y5HYURDVYKmI,25628
14
14
  zou/app/blueprints/auth/__init__.py,sha256=xP874bMWUnLIirOPSEbpe-Q2fBBQrxZGKd0tLZmNJXk,1128
15
15
  zou/app/blueprints/auth/resources.py,sha256=YIhdEVK9WQ7fCYtknwh3dR3TdSdURRm7rBpDxpNSGK0,45608
16
16
  zou/app/blueprints/breakdown/__init__.py,sha256=Dp6GWSGxxWIedpyzTTEKpCRUYEo8oVNVyQhwNvTMmQM,1888
@@ -225,7 +225,7 @@ zou/app/utils/auth.py,sha256=DZfZSr1Ulge0UK3hfvOWsMo3_d7RVP_llV118u9BtUI,870
225
225
  zou/app/utils/cache.py,sha256=MRluTvGG67ybOkyzgD70B6PGKMdRyFdTc0AYy3dEQe8,1210
226
226
  zou/app/utils/chats.py,sha256=ORngxQ3IQQF0QcVFJLxJ-RaU4ksQ9-0M8cmPa0pc0Ho,4302
227
227
  zou/app/utils/colors.py,sha256=LaGV17NL_8xY0XSp8snGWz5UMwGnm0KPWXyE5BTMG6w,200
228
- zou/app/utils/commands.py,sha256=pEVJ0HEapuaJ_P8mRQRCATshN4y6ZUHtMYWh7sRjRJ0,27606
228
+ zou/app/utils/commands.py,sha256=ztGq2x5GQJWXDFyHrBV9Cm0cBRWxzEH3zFkPeOD3D0U,27943
229
229
  zou/app/utils/csv_utils.py,sha256=GiI8SeUqmIh9o1JwhZGkQXU_0K0EcPrRHYIZ8bMoYzk,1228
230
230
  zou/app/utils/date_helpers.py,sha256=jFxDPCbAasg0I1gsC72AKEbGcx5c4pLqXZkSfZ4wLdQ,4724
231
231
  zou/app/utils/dbhelpers.py,sha256=RSJuoxLexGJyME16GQCs-euFLBR0u-XAFdJ1KMSv5M8,1143
@@ -258,7 +258,7 @@ zou/migrations/versions/003be8a91001_add_start_and_end_dates_to_projects.py,sha2
258
258
  zou/migrations/versions/0596674df51d_add_department_mentions_to_comments.py,sha256=OS9E9uF27t-w04kemMydRE6Trc2998_lDu4r-gRYaMs,1347
259
259
  zou/migrations/versions/05ac7e8caa21_remove_unique_constraint_for_taskstatus_.py,sha256=1Rfr8G6_q2qT--NI31H1koLJJq2IDvD7nHy7dOGKbpk,2568
260
260
  zou/migrations/versions/05b7dc79a416_add_archived_fields_to_main_tables.py,sha256=jNWh_Vq5SxJ5hUeksJ5OBgibijXF3AGX4PIO1pZAhH8,1362
261
- zou/migrations/versions/06552e22f9e7_add_comment_updated_by.py,sha256=4NSUjkwSz6jqfrutfKPMRy0tg00ywoce916ZIhs1v14,1343
261
+ zou/migrations/versions/06552e22f9e7_add_comment_updated_by.py,sha256=gPrYe6W4mF6FW3utUPeebgGMh1_KekLE483mp8PzMAE,1407
262
262
  zou/migrations/versions/0cf5e0e035fa_drop_column_tasktype_for_shots.py,sha256=9p0B2X3Zwhsyo8gq50XEFoZQq5KolhVBTVujHMRWtx4,2008
263
263
  zou/migrations/versions/0ec3762a745d_add_attachment_table.py,sha256=JDvrRgC9lfO8HH3PS1JzauEANz9TaTCGPiJj5lVuGOw,1819
264
264
  zou/migrations/versions/0ef6416a507b_.py,sha256=rT4hvfT5GwS6nCz2kco7V0kJXel-v0xndnEgYsQx1qY,1975
@@ -418,9 +418,9 @@ zou/remote/normalize_movie.py,sha256=zNfEY3N1UbAHZfddGONTg2Sff3ieLVWd4dfZa1dpnes
418
418
  zou/remote/playlist.py,sha256=AsDo0bgYhDcd6DfNRV6r6Jj3URWwavE2ZN3VkKRPbLU,3293
419
419
  zou/utils/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
420
420
  zou/utils/movie.py,sha256=d67fIL9dVBKt-E_qCGXRbNNdbJaJR5sHvZeX3hf8ldE,16559
421
- zou-0.20.20.dist-info/LICENSE,sha256=dql8h4yceoMhuzlcK0TT_i-NgTFNIZsgE47Q4t3dUYI,34520
422
- zou-0.20.20.dist-info/METADATA,sha256=EgMesyLvZ7hiO56x5CInXtaDo_9ZWHaTXVGclLmBKDo,6673
423
- zou-0.20.20.dist-info/WHEEL,sha256=jB7zZ3N9hIM9adW7qlTAyycLYW9npaWKLRzaoVcLKcM,91
424
- zou-0.20.20.dist-info/entry_points.txt,sha256=PelQoIx3qhQ_Tmne7wrLY-1m2izuzgpwokoURwSohy4,130
425
- zou-0.20.20.dist-info/top_level.txt,sha256=4S7G_jk4MzpToeDItHGjPhHx_fRdX52zJZWTD4SL54g,4
426
- zou-0.20.20.dist-info/RECORD,,
421
+ zou-0.20.21.dist-info/LICENSE,sha256=dql8h4yceoMhuzlcK0TT_i-NgTFNIZsgE47Q4t3dUYI,34520
422
+ zou-0.20.21.dist-info/METADATA,sha256=AGg5JHLs6j1WpwQtvy8P7Ho2XoG6uI1hS3U3hYP9aYc,6673
423
+ zou-0.20.21.dist-info/WHEEL,sha256=jB7zZ3N9hIM9adW7qlTAyycLYW9npaWKLRzaoVcLKcM,91
424
+ zou-0.20.21.dist-info/entry_points.txt,sha256=PelQoIx3qhQ_Tmne7wrLY-1m2izuzgpwokoURwSohy4,130
425
+ zou-0.20.21.dist-info/top_level.txt,sha256=4S7G_jk4MzpToeDItHGjPhHx_fRdX52zJZWTD4SL54g,4
426
+ zou-0.20.21.dist-info/RECORD,,
File without changes
File without changes