QuLab 2.4.16__cp311-cp311-win_amd64.whl → 2.4.17__cp311-cp311-win_amd64.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.
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.2
2
2
  Name: QuLab
3
- Version: 2.4.16
3
+ Version: 2.4.17
4
4
  Summary: contral instruments and manage data
5
5
  Author-email: feihoo87 <feihoo87@gmail.com>
6
6
  Maintainer-email: feihoo87 <feihoo87@gmail.com>
@@ -1,17 +1,17 @@
1
1
  qulab/__init__.py,sha256=vkFybY8YSsQilYdThPRD83-btPAR41sy_WCXiM-6mME,141
2
2
  qulab/__main__.py,sha256=g9iBs8xxX6Yik7cmgllQkpBN8C4JNoZVsEOyCCLCyFU,63
3
3
  qulab/dicttree.py,sha256=ZoSJVWK4VMqfzj42gPb_n5RqLlM6K1Me0WmLIfLEYf8,14195
4
- qulab/fun.cp311-win_amd64.pyd,sha256=Ud9frCe9jfVXvl_IfrEf97TZotrnIWFyOn7gHeDeYrM,31744
5
- qulab/version.py,sha256=rVOnxEJVvl0ZWvCblBzVBGcp0VALbV_koS5W-UB9zfk,22
4
+ qulab/fun.cp311-win_amd64.pyd,sha256=H1XtP6wtWvUAQY8wmhNWbq2MJGwYoujLil94KpfThb4,31744
5
+ qulab/version.py,sha256=7sdjAp5MKcoRwUjjN0nAZGMtB3lz4cfXjSGNTq8NnJ4,22
6
6
  qulab/cli/__init__.py,sha256=6xd2eYw32k1NmfAuYSu__1kaP12Oz1QVqwbkYXdWno4,588
7
7
  qulab/cli/config.py,sha256=gvMObzaVJ-xTJ1GmhP3sATayfDasYlijX1krSGeccNY,3071
8
8
  qulab/executor/__init__.py,sha256=LosPzOMaljSZY1thy_Fxtbrgq7uubJszMABEB7oM7tU,101
9
- qulab/executor/cli.py,sha256=LRSb5-J8Tn7dj-fxwCp3OP_6YUgPRoY-f8O18sbWG8I,5164
10
- qulab/executor/load.py,sha256=yTLoWOtTvmCTuYFZ6qFsjBM_CvsrKgmUkBSHHz3223A,10899
9
+ qulab/executor/cli.py,sha256=9x7yCvEI41MaALE5Hv9-15Z_IGs2_Kswo3EjCoh_RPE,5595
10
+ qulab/executor/load.py,sha256=eKysHL5EHKd_YcfHOVwRoaNsD-k0cTuxDY_7Yn5W8hA,11078
11
11
  qulab/executor/schedule.py,sha256=SfMZys8WdmIvfW5fPM42g-F6XwewTdpC0-puhf5TA54,11721
12
12
  qulab/executor/storage.py,sha256=M66Q5_Uc5MMfc_QAuuaaexwAz7wxBPMkeleB5nRpQmI,4621
13
13
  qulab/executor/transform.py,sha256=inaOn6eqCs22ZZ0xAQl8s8YCoEACaXSwFNNu7jqdwAk,2148
14
- qulab/executor/utils.py,sha256=jp3F0swO9gpKhmTauxbgEK9WVorjI9FAL6zT60cYTdk,3106
14
+ qulab/executor/utils.py,sha256=RmnT0wMTAvavM-abgFt2tQN8TaaHuk86-YAiOUQCoBU,3101
15
15
  qulab/monitor/__init__.py,sha256=xEVDkJF8issrsDeLqQmDsvtRmrf-UiViFcGTWuzdlFU,43
16
16
  qulab/monitor/__main__.py,sha256=k2H1H5Zf9LLXTDLISJkbikLH-z0f1e5i5i6wXXYPOrE,105
17
17
  qulab/monitor/config.py,sha256=y_5StMkdrbZO1ziyKBrvIkB7Jclp9RCPK1QbsOhCxnY,785
@@ -91,9 +91,9 @@ qulab/visualization/plot_seq.py,sha256=Uo1-dB1YE9IN_A9tuaOs9ZG3S5dKDQ_l98iD2Wbxp
91
91
  qulab/visualization/qdat.py,sha256=HubXFu4nfcA7iUzghJGle1C86G6221hicLR0b-GqhKQ,5887
92
92
  qulab/visualization/rot3d.py,sha256=jGHJcqj1lEWBUV-W4GUGONGacqjrYvuFoFCwPse5h1Y,757
93
93
  qulab/visualization/widgets.py,sha256=HcYwdhDtLreJiYaZuN3LfofjJmZcLwjMfP5aasebgDo,3266
94
- QuLab-2.4.16.dist-info/LICENSE,sha256=b4NRQ-GFVpJMT7RuExW3NwhfbrYsX7AcdB7Gudok-fs,1086
95
- QuLab-2.4.16.dist-info/METADATA,sha256=800PogLCuT2uN9w6hfEuVv5sOrzXlr3AobBHeiruLrQ,3804
96
- QuLab-2.4.16.dist-info/WHEEL,sha256=yNnHoQL2GZYIUXm9YvoaBpFjGlUoK9qq9oqYeudrWlE,101
97
- QuLab-2.4.16.dist-info/entry_points.txt,sha256=b0v1GXOwmxY-nCCsPN_rHZZvY9CtTbWqrGj8u1m8yHo,45
98
- QuLab-2.4.16.dist-info/top_level.txt,sha256=3T886LbAsbvjonu_TDdmgxKYUn939BVTRPxPl9r4cEg,6
99
- QuLab-2.4.16.dist-info/RECORD,,
94
+ QuLab-2.4.17.dist-info/LICENSE,sha256=b4NRQ-GFVpJMT7RuExW3NwhfbrYsX7AcdB7Gudok-fs,1086
95
+ QuLab-2.4.17.dist-info/METADATA,sha256=DwgNA--FfjwweGZlKCLdUpvP80VyQQiYE-iisAp0d5E,3804
96
+ QuLab-2.4.17.dist-info/WHEEL,sha256=yNnHoQL2GZYIUXm9YvoaBpFjGlUoK9qq9oqYeudrWlE,101
97
+ QuLab-2.4.17.dist-info/entry_points.txt,sha256=b0v1GXOwmxY-nCCsPN_rHZZvY9CtTbWqrGj8u1m8yHo,45
98
+ QuLab-2.4.17.dist-info/top_level.txt,sha256=3T886LbAsbvjonu_TDdmgxKYUn939BVTRPxPl9r4cEg,6
99
+ QuLab-2.4.17.dist-info/RECORD,,
qulab/executor/cli.py CHANGED
@@ -54,6 +54,7 @@ def create(workflow, code):
54
54
  """
55
55
  Create a new workflow file.
56
56
  """
57
+ logger.info(f'[CMD]: create {workflow} --code {code}')
57
58
  if code is None:
58
59
  code = Path.cwd()
59
60
 
@@ -82,6 +83,7 @@ def set(key, value, api):
82
83
  """
83
84
  Set a config.
84
85
  """
86
+ logger.info(f'[CMD]: set {key} {value} --api {api}')
85
87
  from . import transform
86
88
  if api is not None:
87
89
  api = importlib.import_module(api)
@@ -103,6 +105,7 @@ def get(key, api):
103
105
  """
104
106
  Get a config.
105
107
  """
108
+ logger.info(f'[CMD]: get {key} --api {api}')
106
109
  from . import transform
107
110
  if api is not None:
108
111
  api = importlib.import_module(api)
@@ -123,6 +126,9 @@ def run(workflow, code, data, api, plot, no_dependents):
123
126
  """
124
127
  Run a workflow.
125
128
  """
129
+ logger.info(
130
+ f'[CMD]: run {workflow} --code {code} --data {data} --api {api} --plot {plot} --no-dependents {no_dependents}'
131
+ )
126
132
  if api is not None:
127
133
  api = importlib.import_module(api)
128
134
  set_config_api(api.query_config, api.update_config)
@@ -159,6 +165,9 @@ def maintain(workflow, code, data, api, plot):
159
165
  """
160
166
  Maintain a workflow.
161
167
  """
168
+ logger.info(
169
+ f'[CMD]: maintain {workflow} --code {code} --data {data} --api {api} --plot {plot}'
170
+ )
162
171
  if api is not None:
163
172
  api = importlib.import_module(api)
164
173
  set_config_api(api.query_config, api.update_config)
qulab/executor/load.py CHANGED
@@ -21,7 +21,7 @@ class SetConfigWorkflow():
21
21
  self.key = key
22
22
 
23
23
  def depends(self):
24
- return [[]]
24
+ return []
25
25
 
26
26
  def check_state(self, history: Result) -> bool:
27
27
  from . import transform
@@ -254,6 +254,10 @@ def load_workflow_from_template(template_path: str,
254
254
  return new_text
255
255
 
256
256
  template = string.Template(replace(content))
257
+ keys = template.get_identifiers()
258
+ missing = set(keys) - set(mappping.keys())
259
+ if missing:
260
+ raise KeyError(f"{template_path}: Missing keys in mapping: {missing}")
257
261
  content = template.substitute(mappping)
258
262
 
259
263
  hash_str = hashlib.md5(pickle.dumps(mappping)).hexdigest()[:8]
@@ -323,7 +327,7 @@ def get_dependents(workflow: WorkflowType,
323
327
  code_path: str | Path) -> list[WorkflowType]:
324
328
  return [
325
329
  load_workflow(n, code_path, mtime=workflow.__mtime__)
326
- for n in workflow.depends()[0]
330
+ for n in workflow.depends()
327
331
  ]
328
332
 
329
333
 
qulab/executor/utils.py CHANGED
@@ -25,7 +25,7 @@ def dependent_tree(node: str, code_path: str | Path) -> dict[str, list[str]]:
25
25
  Returns a dict of nodes and their dependents.
26
26
  '''
27
27
  tree = {}
28
- for n in load_workflow(node, code_path).depends()[0]:
28
+ for n in load_workflow(node, code_path).depends():
29
29
  tree[n] = dependent_tree(n, code_path)
30
30
  return tree
31
31
 
@@ -43,7 +43,7 @@ import numpy as np
43
43
  __timeout__ = 7*24*3600
44
44
 
45
45
  def depends():
46
- return [{deps!r}]
46
+ return {deps!r}
47
47
 
48
48
 
49
49
  def calibrate():
Binary file
qulab/version.py CHANGED
@@ -1 +1 @@
1
- __version__ = "2.4.16"
1
+ __version__ = "2.4.17"
File without changes