dart-tools 0.8.0__py3-none-any.whl → 0.8.1__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 dart-tools might be problematic. Click here for more details.

dart/old.py CHANGED
@@ -124,9 +124,15 @@ def replicate_space(
124
124
  def get_dartboards(space_id: str, include_special: bool = False) -> list[dict]:
125
125
  dart = DartOld()
126
126
 
127
- response = dart.get(_LIST_DARTBOARDS_URL_FRAG, params={"space_duid": space_id})
127
+ response = dart.get(_LIST_DARTBOARDS_URL_FRAG, params={"space_duid": space_id, "limit": 100})
128
128
  response_json = response.json()
129
129
  dartboards = response_json["results"] if response_json is not None else []
130
+ while response_json.get("next") is not None:
131
+ response = dart.get(response_json["next"])
132
+ response_json = response.json()
133
+ if response_json is not None and "results" in response_json:
134
+ dartboards.extend(response_json["results"])
135
+
130
136
  if not include_special:
131
137
  dartboards = [e for e in dartboards if e["kind"] == "Custom"]
132
138
 
@@ -178,9 +184,15 @@ def update_dartboard(dartboard_id: str, *, title: Union[str, None] = None, color
178
184
  def get_folders(space_id: str, *, include_special: Union[bool, None] = False) -> list[dict]:
179
185
  dart = DartOld()
180
186
 
181
- response = dart.get(_LIST_FOLDERS_URL_FRAG, params={"space_duid": space_id})
187
+ response = dart.get(_LIST_FOLDERS_URL_FRAG, params={"space_duid": space_id, "limit": 50})
182
188
  response_json = response.json()
183
189
  folders = response_json["results"] if response_json is not None else []
190
+ while response_json.get("next") is not None:
191
+ response = dart.get(response_json["next"])
192
+ response_json = response.json()
193
+ if response_json is not None and "results" in response_json:
194
+ folders.extend(response_json["results"])
195
+
184
196
  if not include_special:
185
197
  folders = [e for e in folders if e["kind"] == "Other"]
186
198
 
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: dart-tools
3
- Version: 0.8.0
3
+ Version: 0.8.1
4
4
  Summary: The Dart CLI and Python Library
5
5
  Author-email: Dart <software@dartai.com>
6
6
  License: MIT License
@@ -1,7 +1,7 @@
1
1
  dart/__init__.py,sha256=M4oDY_DtfE7s50jXziRxVuL95hE1EKEaWOEmWxy8_Ig,523
2
2
  dart/dart.py,sha256=MLFFI63heQ16CLCdTxwPTXYBcsnVxJxE2gaAIFsnxDo,27289
3
3
  dart/exception.py,sha256=evN1SFV7Bal5dQIIOnhYA0cRu6jSa0cOCiG7AkHZD5A,85
4
- dart/old.py,sha256=LqwFKYDpNwHlp_0NT9UACmAsx8PwYLyogLmY7YcuzVg,7053
4
+ dart/old.py,sha256=Dx7su_6Qwtw25xgRhm3vnV-mPajqNdXfnLrlRPz7pjE,7609
5
5
  dart/order_manager.py,sha256=WI8YEjdOuEFDNcRCm30INAA5lY8016ttt0yXElGIeUU,1882
6
6
  dart/webhook.py,sha256=1_8m1ik4k7yOHi1mBKUQrTy6RIXCFCuq0QJkoloZEGY,590
7
7
  dart/generated/__init__.py,sha256=8fO-FKZzuZzOUUaqtlgw7k08MUwNLf8Ll-cAt7BgmAU,158
@@ -78,9 +78,9 @@ dart/generated/models/wrapped_task.py,sha256=TRlVMxIGhDwSaJlXdMH6q7Vx2hpz7EdiGns
78
78
  dart/generated/models/wrapped_task_create.py,sha256=Oxdot2EwfEuC3l4uo0fAvmyjRNVkXALmWCvfgHI7BcI,1654
79
79
  dart/generated/models/wrapped_task_update.py,sha256=_erGSSR_k6ahF_RFjgLKdyitx5TDQiFw_Ml77zHQdJM,1654
80
80
  dart/generated/models/wrapped_view.py,sha256=zflJxA4UnITM8w-0EObw4AF54yS-c_e5UL6vaikXyG8,1577
81
- dart_tools-0.8.0.dist-info/licenses/LICENSE,sha256=aD_0TnuylEaAHWNURgifNek_ODn5Pg36o9gFdspgHtg,1061
82
- dart_tools-0.8.0.dist-info/METADATA,sha256=UJejLRhuCYTDcLh_YgaVucW8bdj-SWTMeLILAiSZJxM,8996
83
- dart_tools-0.8.0.dist-info/WHEEL,sha256=_zCd3N1l69ArxyTb8rzEoP9TpbYXkqRFSNOD5OuxnTs,91
84
- dart_tools-0.8.0.dist-info/entry_points.txt,sha256=KOVAnDWJbSKn9HoXWQ7x6NfACYzSMGHBBaBxonHEv6w,34
85
- dart_tools-0.8.0.dist-info/top_level.txt,sha256=ZwUQ6QjCyi1i32BJOAkbOA7UfgitLmIwToJGJwZXPrg,5
86
- dart_tools-0.8.0.dist-info/RECORD,,
81
+ dart_tools-0.8.1.dist-info/licenses/LICENSE,sha256=aD_0TnuylEaAHWNURgifNek_ODn5Pg36o9gFdspgHtg,1061
82
+ dart_tools-0.8.1.dist-info/METADATA,sha256=UnhGfEgQST-1gauzSEeAzRYaypepjLuOoGJ--0vejJ8,8996
83
+ dart_tools-0.8.1.dist-info/WHEEL,sha256=_zCd3N1l69ArxyTb8rzEoP9TpbYXkqRFSNOD5OuxnTs,91
84
+ dart_tools-0.8.1.dist-info/entry_points.txt,sha256=KOVAnDWJbSKn9HoXWQ7x6NfACYzSMGHBBaBxonHEv6w,34
85
+ dart_tools-0.8.1.dist-info/top_level.txt,sha256=ZwUQ6QjCyi1i32BJOAkbOA7UfgitLmIwToJGJwZXPrg,5
86
+ dart_tools-0.8.1.dist-info/RECORD,,