tinybird-cli 3.9.1.dev6__tar.gz → 3.10.1.dev1__tar.gz

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.
Files changed (46) hide show
  1. {tinybird-cli-3.9.1.dev6 → tinybird-cli-3.10.1.dev1}/PKG-INFO +2 -18
  2. {tinybird-cli-3.9.1.dev6 → tinybird-cli-3.10.1.dev1}/tinybird/__cli__.py +2 -2
  3. {tinybird-cli-3.9.1.dev6 → tinybird-cli-3.10.1.dev1}/tinybird/feedback_manager.py +3 -0
  4. {tinybird-cli-3.9.1.dev6 → tinybird-cli-3.10.1.dev1}/tinybird/tb_cli_modules/connection.py +20 -6
  5. {tinybird-cli-3.9.1.dev6 → tinybird-cli-3.10.1.dev1}/tinybird_cli.egg-info/PKG-INFO +2 -18
  6. {tinybird-cli-3.9.1.dev6 → tinybird-cli-3.10.1.dev1}/setup.cfg +0 -0
  7. {tinybird-cli-3.9.1.dev6 → tinybird-cli-3.10.1.dev1}/tinybird/ch_utils/constants.py +0 -0
  8. {tinybird-cli-3.9.1.dev6 → tinybird-cli-3.10.1.dev1}/tinybird/ch_utils/engine.py +0 -0
  9. {tinybird-cli-3.9.1.dev6 → tinybird-cli-3.10.1.dev1}/tinybird/check_pypi.py +0 -0
  10. {tinybird-cli-3.9.1.dev6 → tinybird-cli-3.10.1.dev1}/tinybird/client.py +0 -0
  11. {tinybird-cli-3.9.1.dev6 → tinybird-cli-3.10.1.dev1}/tinybird/config.py +0 -0
  12. {tinybird-cli-3.9.1.dev6 → tinybird-cli-3.10.1.dev1}/tinybird/connectors.py +0 -0
  13. {tinybird-cli-3.9.1.dev6 → tinybird-cli-3.10.1.dev1}/tinybird/context.py +0 -0
  14. {tinybird-cli-3.9.1.dev6 → tinybird-cli-3.10.1.dev1}/tinybird/datafile.py +0 -0
  15. {tinybird-cli-3.9.1.dev6 → tinybird-cli-3.10.1.dev1}/tinybird/datatypes.py +0 -0
  16. {tinybird-cli-3.9.1.dev6 → tinybird-cli-3.10.1.dev1}/tinybird/git_settings.py +0 -0
  17. {tinybird-cli-3.9.1.dev6 → tinybird-cli-3.10.1.dev1}/tinybird/sql.py +0 -0
  18. {tinybird-cli-3.9.1.dev6 → tinybird-cli-3.10.1.dev1}/tinybird/sql_template.py +0 -0
  19. {tinybird-cli-3.9.1.dev6 → tinybird-cli-3.10.1.dev1}/tinybird/sql_template_fmt.py +0 -0
  20. {tinybird-cli-3.9.1.dev6 → tinybird-cli-3.10.1.dev1}/tinybird/sql_toolset.py +0 -0
  21. {tinybird-cli-3.9.1.dev6 → tinybird-cli-3.10.1.dev1}/tinybird/syncasync.py +0 -0
  22. {tinybird-cli-3.9.1.dev6 → tinybird-cli-3.10.1.dev1}/tinybird/tb_cli.py +0 -0
  23. {tinybird-cli-3.9.1.dev6 → tinybird-cli-3.10.1.dev1}/tinybird/tb_cli_modules/auth.py +0 -0
  24. {tinybird-cli-3.9.1.dev6 → tinybird-cli-3.10.1.dev1}/tinybird/tb_cli_modules/branch.py +0 -0
  25. {tinybird-cli-3.9.1.dev6 → tinybird-cli-3.10.1.dev1}/tinybird/tb_cli_modules/cicd.py +0 -0
  26. {tinybird-cli-3.9.1.dev6 → tinybird-cli-3.10.1.dev1}/tinybird/tb_cli_modules/cli.py +0 -0
  27. {tinybird-cli-3.9.1.dev6 → tinybird-cli-3.10.1.dev1}/tinybird/tb_cli_modules/common.py +0 -0
  28. {tinybird-cli-3.9.1.dev6 → tinybird-cli-3.10.1.dev1}/tinybird/tb_cli_modules/config.py +0 -0
  29. {tinybird-cli-3.9.1.dev6 → tinybird-cli-3.10.1.dev1}/tinybird/tb_cli_modules/datasource.py +0 -0
  30. {tinybird-cli-3.9.1.dev6 → tinybird-cli-3.10.1.dev1}/tinybird/tb_cli_modules/exceptions.py +0 -0
  31. {tinybird-cli-3.9.1.dev6 → tinybird-cli-3.10.1.dev1}/tinybird/tb_cli_modules/job.py +0 -0
  32. {tinybird-cli-3.9.1.dev6 → tinybird-cli-3.10.1.dev1}/tinybird/tb_cli_modules/pipe.py +0 -0
  33. {tinybird-cli-3.9.1.dev6 → tinybird-cli-3.10.1.dev1}/tinybird/tb_cli_modules/regions.py +0 -0
  34. {tinybird-cli-3.9.1.dev6 → tinybird-cli-3.10.1.dev1}/tinybird/tb_cli_modules/telemetry.py +0 -0
  35. {tinybird-cli-3.9.1.dev6 → tinybird-cli-3.10.1.dev1}/tinybird/tb_cli_modules/test.py +0 -0
  36. {tinybird-cli-3.9.1.dev6 → tinybird-cli-3.10.1.dev1}/tinybird/tb_cli_modules/tinyunit/tinyunit.py +0 -0
  37. {tinybird-cli-3.9.1.dev6 → tinybird-cli-3.10.1.dev1}/tinybird/tb_cli_modules/tinyunit/tinyunit_lib.py +0 -0
  38. {tinybird-cli-3.9.1.dev6 → tinybird-cli-3.10.1.dev1}/tinybird/tb_cli_modules/token.py +0 -0
  39. {tinybird-cli-3.9.1.dev6 → tinybird-cli-3.10.1.dev1}/tinybird/tb_cli_modules/workspace.py +0 -0
  40. {tinybird-cli-3.9.1.dev6 → tinybird-cli-3.10.1.dev1}/tinybird/tb_cli_modules/workspace_members.py +0 -0
  41. {tinybird-cli-3.9.1.dev6 → tinybird-cli-3.10.1.dev1}/tinybird/tornado_template.py +0 -0
  42. {tinybird-cli-3.9.1.dev6 → tinybird-cli-3.10.1.dev1}/tinybird_cli.egg-info/SOURCES.txt +0 -0
  43. {tinybird-cli-3.9.1.dev6 → tinybird-cli-3.10.1.dev1}/tinybird_cli.egg-info/dependency_links.txt +0 -0
  44. {tinybird-cli-3.9.1.dev6 → tinybird-cli-3.10.1.dev1}/tinybird_cli.egg-info/entry_points.txt +0 -0
  45. {tinybird-cli-3.9.1.dev6 → tinybird-cli-3.10.1.dev1}/tinybird_cli.egg-info/requires.txt +0 -0
  46. {tinybird-cli-3.9.1.dev6 → tinybird-cli-3.10.1.dev1}/tinybird_cli.egg-info/top_level.txt +0 -0
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.1
2
2
  Name: tinybird-cli
3
- Version: 3.9.1.dev6
3
+ Version: 3.10.1.dev1
4
4
  Summary: Tinybird Command Line Tool
5
5
  Home-page: https://www.tinybird.co/docs/cli/introduction.html
6
6
  Author: Tinybird
@@ -18,29 +18,13 @@ The Tinybird command-line tool allows you to use all the Tinybird functionality
18
18
  Changelog
19
19
  ----------
20
20
 
21
- 3.9.1.dev6
21
+ 3.10.0
22
22
  ************
23
23
 
24
24
  - `Added` Support for unlink materialized pipes doing `tb workspace clear`
25
-
26
- 3.9.1.dev5
27
- ************
28
-
29
25
  - `Added` support for adding multiple tokens when pushing a `.datasource` file
30
-
31
- 3.9.1.dev4
32
- ************
33
-
34
26
  - `Fixed` s3 iamrole connection creation will not fail when `pbcopy` dependency is not available
35
-
36
- 3.9.1.dev3
37
- ************
38
-
39
27
  - `Fixed` Fixed a bug on data branching
40
-
41
- 3.9.1.dev2
42
- ************
43
-
44
28
  - `Fixed` Support ngram index
45
29
 
46
30
  3.9.0
@@ -4,5 +4,5 @@ __description__ = 'Tinybird Command Line Tool'
4
4
  __url__ = 'https://www.tinybird.co/docs/cli/introduction.html'
5
5
  __author__ = 'Tinybird'
6
6
  __author_email__ = 'support@tinybird.co'
7
- __version__ = '3.9.1.dev6'
8
- __revision__ = '00f0cad'
7
+ __version__ = '3.10.1.dev1'
8
+ __revision__ = 'f17c3da'
@@ -850,6 +850,9 @@ Ready? """
850
850
  success_connection_file_created = success_message(
851
851
  "** {name} created successfully! Connection details saved in your connection file."
852
852
  )
853
+ success_s3_iam_connection_created = success_message(
854
+ "** Info associated with this connection:\n** External ID: {external_id}\n** Role ARN: {role_arn}"
855
+ )
853
856
 
854
857
  success_delete_connection = success_message("** Connection {connection_id} removed successfully")
855
858
  success_connection_using = success_message("** Using connection '{connection_name}'")
@@ -757,12 +757,15 @@ async def connection_create_s3_iamrole(
757
757
  raise Exception("S3 Integration not supported in this region")
758
758
  except Exception as e:
759
759
  raise CLIConnectionException(FeedbackManager.error_connection_integration_not_available(error=str(e)))
760
-
761
- return json.dumps(s3_access_policy, indent=4), json.dumps(s3_trust_policy, indent=4)
760
+ try:
761
+ external_id = s3_trust_policy["Statement"][0]["Condition"]["StringEquals"]["sts:ExternalId"]
762
+ except Exception:
763
+ external_id = ""
764
+ return json.dumps(s3_access_policy, indent=4), json.dumps(s3_trust_policy, indent=4), external_id
762
765
 
763
766
  async def validate_s3_integration(role_arn: Optional[str], region: Optional[str]):
764
767
  if no_validate is False:
765
- access_policy, trust_policy = await get_s3_policies()
768
+ access_policy, trust_policy, external_id = await get_s3_policies()
766
769
 
767
770
  if not role_arn:
768
771
  if not click.confirm(
@@ -805,7 +808,12 @@ async def connection_create_s3_iamrole(
805
808
  prompt_suffix="Press y to continue:",
806
809
  ):
807
810
  sys.exit(1)
808
-
811
+ else:
812
+ try:
813
+ trust_policy = await client.get_s3_trust_policy()
814
+ external_id = trust_policy["Statement"][0]["Condition"]["StringEquals"]["sts:ExternalId"]
815
+ except Exception:
816
+ external_id = ""
809
817
  if not role_arn:
810
818
  role_arn = click.prompt("Enter the ARN of the role you just created")
811
819
  validate_string_connector_param("Role ARN", role_arn)
@@ -814,7 +822,7 @@ async def connection_create_s3_iamrole(
814
822
  region = click.prompt("Enter the region where the bucket is located")
815
823
  validate_string_connector_param("Region", region)
816
824
 
817
- return role_arn, region
825
+ return role_arn, region, external_id
818
826
 
819
827
  async def validate_connection_name(connection_name: Optional[str]) -> str:
820
828
  if connection_name and no_validate is False:
@@ -862,6 +870,12 @@ async def connection_create_s3_iamrole(
862
870
  )
863
871
  click.echo(FeedbackManager.success_connection_file_created(name=conn_file_name))
864
872
 
865
- role_arn, region = await validate_s3_integration(role_arn, region)
873
+ role_arn, region, external_id = await validate_s3_integration(role_arn, region)
866
874
  connection_name = await validate_connection_name(connection_name)
867
875
  await create_connection(connection_name, role_arn, region)
876
+ if external_id:
877
+ click.echo(
878
+ FeedbackManager.success_s3_iam_connection_created(
879
+ connection_name=connection_name, external_id=external_id, role_arn=role_arn
880
+ )
881
+ )
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.1
2
2
  Name: tinybird-cli
3
- Version: 3.9.1.dev6
3
+ Version: 3.10.1.dev1
4
4
  Summary: Tinybird Command Line Tool
5
5
  Home-page: https://www.tinybird.co/docs/cli/introduction.html
6
6
  Author: Tinybird
@@ -18,29 +18,13 @@ The Tinybird command-line tool allows you to use all the Tinybird functionality
18
18
  Changelog
19
19
  ----------
20
20
 
21
- 3.9.1.dev6
21
+ 3.10.0
22
22
  ************
23
23
 
24
24
  - `Added` Support for unlink materialized pipes doing `tb workspace clear`
25
-
26
- 3.9.1.dev5
27
- ************
28
-
29
25
  - `Added` support for adding multiple tokens when pushing a `.datasource` file
30
-
31
- 3.9.1.dev4
32
- ************
33
-
34
26
  - `Fixed` s3 iamrole connection creation will not fail when `pbcopy` dependency is not available
35
-
36
- 3.9.1.dev3
37
- ************
38
-
39
27
  - `Fixed` Fixed a bug on data branching
40
-
41
- 3.9.1.dev2
42
- ************
43
-
44
28
  - `Fixed` Support ngram index
45
29
 
46
30
  3.9.0