synapse-sdk 1.0.0a14__py3-none-any.whl → 1.0.0a15__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.

Potentially problematic release.


This version of synapse-sdk might be problematic. Click here for more details.

@@ -26,7 +26,8 @@ def publish(ctx, host, user_token, tenant, debug_modules):
26
26
 
27
27
  data = {'plugin': plugin_release.plugin, 'file': str(archive_path), 'debug': debug}
28
28
  if debug:
29
- data['debug_meta'] = json.dumps({'modules': debug_modules.split(',')})
29
+ if debug_modules:
30
+ data['debug_meta'] = json.dumps({'modules': debug_modules.split(',')})
30
31
 
31
32
  client = BackendClient(host, user_token, tenant=tenant)
32
33
  client.create_plugin_release(data)
@@ -86,28 +86,26 @@ class Run:
86
86
  logger = None
87
87
  job_id = None
88
88
  context = None
89
+ client = None
89
90
 
90
91
  def __init__(self, job_id, context):
91
92
  self.job_id = job_id
92
93
  self.context = context
94
+ self.client = BackendClient(
95
+ self.context['envs']['SYNAPSE_PLUGIN_RUN_HOST'],
96
+ self.context['envs']['SYNAPSE_PLUGIN_RUN_USER_TOKEN'],
97
+ self.context['envs']['SYNAPSE_PLUGIN_RUN_TENANT'],
98
+ )
93
99
  self.set_logger()
94
100
 
95
101
  def set_logger(self):
96
102
  kwargs = {'progress_categories': self.context['progress_categories']}
103
+
97
104
  if self.job_id:
98
- client = BackendClient(
99
- self.context['envs']['SYNAPSE_PLUGIN_RUN_HOST'],
100
- self.context['envs']['SYNAPSE_PLUGIN_RUN_USER_TOKEN'],
101
- self.context['envs']['SYNAPSE_PLUGIN_RUN_TENANT'],
102
- )
103
- self.logger = BackendLogger(client, self.job_id, **kwargs)
105
+ self.logger = BackendLogger(self.client, self.job_id, **kwargs)
104
106
  else:
105
107
  self.logger = ConsoleLogger(**kwargs)
106
108
 
107
- @property
108
- def client(self):
109
- return getattr(self.logger, 'client', None)
110
-
111
109
  def set_progress(self, current, total, category=''):
112
110
  self.logger.set_progress(current, total, category)
113
111
 
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.1
2
2
  Name: synapse-sdk
3
- Version: 1.0.0a14
3
+ Version: 1.0.0a15
4
4
  Summary: synapse sdk
5
5
  Author-email: datamaker <developer@datamaker.io>
6
6
  License: MIT
@@ -26,7 +26,7 @@ synapse_sdk/clients/ray/serve.py,sha256=rbCpXZYWf0oP8XJ9faa9QFNPYU7h8dltIG8xn9Zc
26
26
  synapse_sdk/plugins/__init__.py,sha256=9vsbYhxah4_ofTaG0x0qLFID_raHNkO57Y8A31Ws-lU,222
27
27
  synapse_sdk/plugins/enums.py,sha256=s59P6Oz2WAK9IX-kLVhNOvNKYJifKlWBhPpZbc9-ttE,486
28
28
  synapse_sdk/plugins/exceptions.py,sha256=Qs7qODp_RRLO9y2otU2T4ryj5LFwIZODvSIXkAh91u0,691
29
- synapse_sdk/plugins/models.py,sha256=LTD5fUk1Y2i2kNx5MaCYVFvXEyzyheY6cEHpNC248ls,3621
29
+ synapse_sdk/plugins/models.py,sha256=T3ZuTw7BZwMKpz2QGaErnEPetKRD9d4z3qceJkV363o,3541
30
30
  synapse_sdk/plugins/upload.py,sha256=VJOotYMayylOH0lNoAGeGHRkLdhP7jnC_A0rFQMvQpQ,3228
31
31
  synapse_sdk/plugins/utils.py,sha256=UYkwxkmrs0-mRgQB63SkTGD1HpIQEIiHndzTcpdNaF4,2936
32
32
  synapse_sdk/plugins/categories/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
@@ -76,7 +76,7 @@ synapse_sdk/plugins/categories/smart_tool/templates/config.yaml,sha256=3jxW8daip
76
76
  synapse_sdk/plugins/categories/smart_tool/templates/plugin/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
77
77
  synapse_sdk/plugins/categories/smart_tool/templates/plugin/auto_label.py,sha256=eevNg0nOcYFR4z_L_R-sCvVOYoLWSAH1jwDkAf3YCjY,320
78
78
  synapse_sdk/plugins/cli/__init__.py,sha256=LPtUO0jqkhKq6xR1grpse7da2R6OoT_BeDyCNyUY0T4,380
79
- synapse_sdk/plugins/cli/publish.py,sha256=aJ7eWdw_c0stIoBY4jWRpeGP0h5qUJWTFUHD6jNs6aM,1200
79
+ synapse_sdk/plugins/cli/publish.py,sha256=rhUtJsKhYyeDTQlul8mQthfMeNuQCou64faHyaP9y1c,1230
80
80
  synapse_sdk/plugins/cli/run.py,sha256=lw1KbsL-xTGllF4NtD2cq-Rh6HMbhi-sO862_Ds-sUo,2330
81
81
  synapse_sdk/plugins/templates/cookiecutter.json,sha256=NxOWk9A_v1pO0Ny4IYT9Cj5iiJ16--cIQrGC67QdR0I,396
82
82
  synapse_sdk/plugins/templates/hooks/post_gen_project.py,sha256=jqlYkY1O2TxIR-Vh3gnwILYy8k-D39Xx66d2KNQVMCs,147
@@ -103,9 +103,9 @@ synapse_sdk/utils/pydantic/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJ
103
103
  synapse_sdk/utils/pydantic/config.py,sha256=1vYOcUI35GslfD1rrqhFkNXXJOXt4IDqOPSx9VWGfNE,123
104
104
  synapse_sdk/utils/pydantic/errors.py,sha256=0v0T12eQBr1KrFiEOBu6KMaPK4aPEGEC6etPJGoR5b4,1061
105
105
  synapse_sdk/utils/pydantic/validators.py,sha256=G47P8ObPhsePmd_QZDK8EdPnik2CbaYzr_N4Z6En8dc,193
106
- synapse_sdk-1.0.0a14.dist-info/LICENSE,sha256=bKzmC5YAg4V1Fhl8OO_tqY8j62hgdncAkN7VrdjmrGk,1101
107
- synapse_sdk-1.0.0a14.dist-info/METADATA,sha256=wQSUzLHaBl0ihU9g9q19Mrh0X4B69hldpDnylJijZ2I,1049
108
- synapse_sdk-1.0.0a14.dist-info/WHEEL,sha256=PZUExdf71Ui_so67QXpySuHtCi3-J3wvF4ORK6k_S8U,91
109
- synapse_sdk-1.0.0a14.dist-info/entry_points.txt,sha256=VNptJoGoNJI8yLXfBmhgUefMsmGI0m3-0YoMvrOgbxo,48
110
- synapse_sdk-1.0.0a14.dist-info/top_level.txt,sha256=ytgJMRK1slVOKUpgcw3LEyHHP7S34J6n_gJzdkcSsw8,12
111
- synapse_sdk-1.0.0a14.dist-info/RECORD,,
106
+ synapse_sdk-1.0.0a15.dist-info/LICENSE,sha256=bKzmC5YAg4V1Fhl8OO_tqY8j62hgdncAkN7VrdjmrGk,1101
107
+ synapse_sdk-1.0.0a15.dist-info/METADATA,sha256=Wh0N4QJ0Hy4XMeV9YUvIHoQUGRNYklUvVnPMv9E7Bbs,1049
108
+ synapse_sdk-1.0.0a15.dist-info/WHEEL,sha256=PZUExdf71Ui_so67QXpySuHtCi3-J3wvF4ORK6k_S8U,91
109
+ synapse_sdk-1.0.0a15.dist-info/entry_points.txt,sha256=VNptJoGoNJI8yLXfBmhgUefMsmGI0m3-0YoMvrOgbxo,48
110
+ synapse_sdk-1.0.0a15.dist-info/top_level.txt,sha256=ytgJMRK1slVOKUpgcw3LEyHHP7S34J6n_gJzdkcSsw8,12
111
+ synapse_sdk-1.0.0a15.dist-info/RECORD,,