tinybird 0.0.1.dev185__py3-none-any.whl → 0.0.1.dev186__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 tinybird might be problematic. Click here for more details.

tinybird/tb/__cli__.py CHANGED
@@ -4,5 +4,5 @@ __description__ = 'Tinybird Command Line Tool'
4
4
  __url__ = 'https://www.tinybird.co/docs/forward/commands'
5
5
  __author__ = 'Tinybird'
6
6
  __author_email__ = 'support@tinybird.co'
7
- __version__ = '0.0.1.dev185'
8
- __revision__ = 'b79d3c1'
7
+ __version__ = '0.0.1.dev186'
8
+ __revision__ = '57239e4'
@@ -138,7 +138,6 @@ async def workspace_current(ctx: Context):
138
138
 
139
139
  @workspace.command(name="create", short_help="Create a new Workspace for your Tinybird user")
140
140
  @click.argument("workspace_name", required=False)
141
- @click.option("--user_token", is_flag=False, default=None, help="When passed, tb won't prompt asking for the token")
142
141
  @click.option(
143
142
  "--fork",
144
143
  is_flag=True,
@@ -157,13 +156,25 @@ async def workspace_current(ctx: Context):
157
156
  async def create_workspace(
158
157
  ctx: Context,
159
158
  workspace_name: str,
160
- user_token: Optional[str],
161
159
  fork: bool,
162
160
  organization_id: Optional[str],
163
161
  ) -> None:
164
162
  config = CLIConfig.get_project_config()
163
+ is_cloud = ctx.ensure_object(dict)["env"] == "cloud"
164
+ if not is_cloud:
165
+ raise CLIWorkspaceException(
166
+ FeedbackManager.error(
167
+ message="`tb workspace create` is not available in local mode. Use --cloud to create a workspace in Tinybird Cloud and it will be used in Tinybird Local."
168
+ )
169
+ )
170
+
171
+ config = CLIConfig.get_project_config()
172
+ user_token = config.get_user_token()
165
173
 
166
- user_token = await get_user_token(config, user_token)
174
+ if not user_token:
175
+ raise CLIWorkspaceException(
176
+ FeedbackManager.error(message="This action requires authentication. Run 'tb login' first.")
177
+ )
167
178
 
168
179
  organization_name = None
169
180
  organizations = await get_organizations_by_user(config, user_token)
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.2
2
2
  Name: tinybird
3
- Version: 0.0.1.dev185
3
+ Version: 0.0.1.dev186
4
4
  Summary: Tinybird Command Line Tool
5
5
  Home-page: https://www.tinybird.co/docs/forward/commands
6
6
  Author: Tinybird
@@ -12,7 +12,7 @@ tinybird/syncasync.py,sha256=IPnOx6lMbf9SNddN1eBtssg8vCLHMt76SuZ6YNYm-Yk,27761
12
12
  tinybird/tornado_template.py,sha256=jjNVDMnkYFWXflmT8KU_Ssbo5vR8KQq3EJMk5vYgXRw,41959
13
13
  tinybird/ch_utils/constants.py,sha256=aYvg2C_WxYWsnqPdZB1ZFoIr8ZY-XjUXYyHKE9Ansj0,3890
14
14
  tinybird/ch_utils/engine.py,sha256=X4tE9OrfaUy6kO9cqVEzyI9cDcmOF3IAssRRzsTsfEQ,40781
15
- tinybird/tb/__cli__.py,sha256=frxkVk6NxktDwMyUqzmr41eBNhcoihthUbTM38gL06E,247
15
+ tinybird/tb/__cli__.py,sha256=fgDoHWj5-L_sJYYjP6ocah4vsol2C_odPl9VN2POpgU,247
16
16
  tinybird/tb/check_pypi.py,sha256=rW4QmDRbtgKdUUwJCnBkVjmTjZSZGN-XgZhx7vMkC0w,1009
17
17
  tinybird/tb/cli.py,sha256=u3eGOhX0MHkuT6tiwaZ0_3twqLmqKXDAOxF7yV_Nn9Q,1075
18
18
  tinybird/tb/client.py,sha256=59GH0IoYSV_KUG0eEbDDYHSWH4OlkVnSRFXE3mYAM0s,56571
@@ -54,7 +54,7 @@ tinybird/tb/modules/telemetry.py,sha256=X0p5AVkM8BNsK_Rhdcg4p2eIf6OHimHO_VLldBqH
54
54
  tinybird/tb/modules/test.py,sha256=QxyDkHGL9Ae46h7BA00z1Efb2_5dBYGqW8cgKIJer5s,13081
55
55
  tinybird/tb/modules/token.py,sha256=2fmKwu10_M0pqs6YmJVeILR9ZQB0ejRAET86agASbKM,13488
56
56
  tinybird/tb/modules/watch.py,sha256=H1FieLTVGRqmZ0hR0vELbQJ9l0CThrFCgGCta-MPuAY,8883
57
- tinybird/tb/modules/workspace.py,sha256=-XUvL2PB5GcviJ8m30h-ZDc5kwJcm1wy1dreYa2l4Ck,10658
57
+ tinybird/tb/modules/workspace.py,sha256=WDi3Vu9t60b4Ht5vbPsakUErFmsECtFRcfXb1l300xc,11057
58
58
  tinybird/tb/modules/workspace_members.py,sha256=RYLpyPM1ECCasHRg3uvpckzXplX0_KgNFsSPZn_i6qk,8744
59
59
  tinybird/tb/modules/datafile/build.py,sha256=d_h3pRFDPFrDKGhpFx2iejY25GuB2k8yfNouj6s8caw,50973
60
60
  tinybird/tb/modules/datafile/build_common.py,sha256=LU24kAQmxDJIyoIapDaYG-SU3P4FrMG9UBf8m9PgVSI,4565
@@ -80,8 +80,8 @@ tinybird/tb_cli_modules/config.py,sha256=IsgdtFRnUrkY8-Zo32lmk6O7u3bHie1QCxLwgp4
80
80
  tinybird/tb_cli_modules/exceptions.py,sha256=pmucP4kTF4irIt7dXiG-FcnI-o3mvDusPmch1L8RCWk,3367
81
81
  tinybird/tb_cli_modules/regions.py,sha256=QjsL5H6Kg-qr0aYVLrvb1STeJ5Sx_sjvbOYO0LrEGMk,166
82
82
  tinybird/tb_cli_modules/telemetry.py,sha256=Hh2Io8ZPROSunbOLuMvuIFU4TqwWPmQTqal4WS09K1A,10449
83
- tinybird-0.0.1.dev185.dist-info/METADATA,sha256=BYrQoaKZjaVJWTz6p19nmNwYT-SJgF0O-g07BCTduH4,1608
84
- tinybird-0.0.1.dev185.dist-info/WHEEL,sha256=In9FTNxeP60KnTkGw7wk6mJPYd_dQSjEZmXdBdMCI-8,91
85
- tinybird-0.0.1.dev185.dist-info/entry_points.txt,sha256=LwdHU6TfKx4Qs7BqqtaczEZbImgU7Abe9Lp920zb_fo,43
86
- tinybird-0.0.1.dev185.dist-info/top_level.txt,sha256=VqqqEmkAy7UNaD8-V51FCoMMWXjLUlR0IstvK7tJYVY,54
87
- tinybird-0.0.1.dev185.dist-info/RECORD,,
83
+ tinybird-0.0.1.dev186.dist-info/METADATA,sha256=XBsl7gXGbcV3mEUvFluqVdyPzg8F-X-c6kXWzx1Cbr4,1608
84
+ tinybird-0.0.1.dev186.dist-info/WHEEL,sha256=In9FTNxeP60KnTkGw7wk6mJPYd_dQSjEZmXdBdMCI-8,91
85
+ tinybird-0.0.1.dev186.dist-info/entry_points.txt,sha256=LwdHU6TfKx4Qs7BqqtaczEZbImgU7Abe9Lp920zb_fo,43
86
+ tinybird-0.0.1.dev186.dist-info/top_level.txt,sha256=VqqqEmkAy7UNaD8-V51FCoMMWXjLUlR0IstvK7tJYVY,54
87
+ tinybird-0.0.1.dev186.dist-info/RECORD,,