tinybird 0.0.1.dev91__tar.gz → 0.0.1.dev92__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.

Potentially problematic release.


This version of tinybird might be problematic. Click here for more details.

Files changed (106) hide show
  1. {tinybird-0.0.1.dev91 → tinybird-0.0.1.dev92}/PKG-INFO +1 -1
  2. {tinybird-0.0.1.dev91 → tinybird-0.0.1.dev92}/tinybird/tb/__cli__.py +2 -2
  3. {tinybird-0.0.1.dev91 → tinybird-0.0.1.dev92}/tinybird/tb/modules/deployment.py +2 -2
  4. {tinybird-0.0.1.dev91 → tinybird-0.0.1.dev92}/tinybird/tb/modules/playground.py +1 -1
  5. {tinybird-0.0.1.dev91 → tinybird-0.0.1.dev92}/tinybird/tb/modules/test.py +14 -14
  6. {tinybird-0.0.1.dev91 → tinybird-0.0.1.dev92}/tinybird.egg-info/PKG-INFO +1 -1
  7. {tinybird-0.0.1.dev91 → tinybird-0.0.1.dev92}/setup.cfg +0 -0
  8. {tinybird-0.0.1.dev91 → tinybird-0.0.1.dev92}/tinybird/__cli__.py +0 -0
  9. {tinybird-0.0.1.dev91 → tinybird-0.0.1.dev92}/tinybird/ch_utils/constants.py +0 -0
  10. {tinybird-0.0.1.dev91 → tinybird-0.0.1.dev92}/tinybird/ch_utils/engine.py +0 -0
  11. {tinybird-0.0.1.dev91 → tinybird-0.0.1.dev92}/tinybird/check_pypi.py +0 -0
  12. {tinybird-0.0.1.dev91 → tinybird-0.0.1.dev92}/tinybird/client.py +0 -0
  13. {tinybird-0.0.1.dev91 → tinybird-0.0.1.dev92}/tinybird/config.py +0 -0
  14. {tinybird-0.0.1.dev91 → tinybird-0.0.1.dev92}/tinybird/connectors.py +0 -0
  15. {tinybird-0.0.1.dev91 → tinybird-0.0.1.dev92}/tinybird/context.py +0 -0
  16. {tinybird-0.0.1.dev91 → tinybird-0.0.1.dev92}/tinybird/datafile.py +0 -0
  17. {tinybird-0.0.1.dev91 → tinybird-0.0.1.dev92}/tinybird/datatypes.py +0 -0
  18. {tinybird-0.0.1.dev91 → tinybird-0.0.1.dev92}/tinybird/feedback_manager.py +0 -0
  19. {tinybird-0.0.1.dev91 → tinybird-0.0.1.dev92}/tinybird/git_settings.py +0 -0
  20. {tinybird-0.0.1.dev91 → tinybird-0.0.1.dev92}/tinybird/prompts.py +0 -0
  21. {tinybird-0.0.1.dev91 → tinybird-0.0.1.dev92}/tinybird/sql.py +0 -0
  22. {tinybird-0.0.1.dev91 → tinybird-0.0.1.dev92}/tinybird/sql_template.py +0 -0
  23. {tinybird-0.0.1.dev91 → tinybird-0.0.1.dev92}/tinybird/sql_template_fmt.py +0 -0
  24. {tinybird-0.0.1.dev91 → tinybird-0.0.1.dev92}/tinybird/sql_toolset.py +0 -0
  25. {tinybird-0.0.1.dev91 → tinybird-0.0.1.dev92}/tinybird/syncasync.py +0 -0
  26. {tinybird-0.0.1.dev91 → tinybird-0.0.1.dev92}/tinybird/tb/cli.py +0 -0
  27. {tinybird-0.0.1.dev91 → tinybird-0.0.1.dev92}/tinybird/tb/modules/auth.py +0 -0
  28. {tinybird-0.0.1.dev91 → tinybird-0.0.1.dev92}/tinybird/tb/modules/build.py +0 -0
  29. {tinybird-0.0.1.dev91 → tinybird-0.0.1.dev92}/tinybird/tb/modules/cicd.py +0 -0
  30. {tinybird-0.0.1.dev91 → tinybird-0.0.1.dev92}/tinybird/tb/modules/cli.py +0 -0
  31. {tinybird-0.0.1.dev91 → tinybird-0.0.1.dev92}/tinybird/tb/modules/common.py +0 -0
  32. {tinybird-0.0.1.dev91 → tinybird-0.0.1.dev92}/tinybird/tb/modules/config.py +0 -0
  33. {tinybird-0.0.1.dev91 → tinybird-0.0.1.dev92}/tinybird/tb/modules/connection.py +0 -0
  34. {tinybird-0.0.1.dev91 → tinybird-0.0.1.dev92}/tinybird/tb/modules/copy.py +0 -0
  35. {tinybird-0.0.1.dev91 → tinybird-0.0.1.dev92}/tinybird/tb/modules/create.py +0 -0
  36. {tinybird-0.0.1.dev91 → tinybird-0.0.1.dev92}/tinybird/tb/modules/datafile/build.py +0 -0
  37. {tinybird-0.0.1.dev91 → tinybird-0.0.1.dev92}/tinybird/tb/modules/datafile/build_common.py +0 -0
  38. {tinybird-0.0.1.dev91 → tinybird-0.0.1.dev92}/tinybird/tb/modules/datafile/build_datasource.py +0 -0
  39. {tinybird-0.0.1.dev91 → tinybird-0.0.1.dev92}/tinybird/tb/modules/datafile/build_pipe.py +0 -0
  40. {tinybird-0.0.1.dev91 → tinybird-0.0.1.dev92}/tinybird/tb/modules/datafile/common.py +0 -0
  41. {tinybird-0.0.1.dev91 → tinybird-0.0.1.dev92}/tinybird/tb/modules/datafile/diff.py +0 -0
  42. {tinybird-0.0.1.dev91 → tinybird-0.0.1.dev92}/tinybird/tb/modules/datafile/exceptions.py +0 -0
  43. {tinybird-0.0.1.dev91 → tinybird-0.0.1.dev92}/tinybird/tb/modules/datafile/fixture.py +0 -0
  44. {tinybird-0.0.1.dev91 → tinybird-0.0.1.dev92}/tinybird/tb/modules/datafile/format_common.py +0 -0
  45. {tinybird-0.0.1.dev91 → tinybird-0.0.1.dev92}/tinybird/tb/modules/datafile/format_datasource.py +0 -0
  46. {tinybird-0.0.1.dev91 → tinybird-0.0.1.dev92}/tinybird/tb/modules/datafile/format_pipe.py +0 -0
  47. {tinybird-0.0.1.dev91 → tinybird-0.0.1.dev92}/tinybird/tb/modules/datafile/parse_datasource.py +0 -0
  48. {tinybird-0.0.1.dev91 → tinybird-0.0.1.dev92}/tinybird/tb/modules/datafile/parse_pipe.py +0 -0
  49. {tinybird-0.0.1.dev91 → tinybird-0.0.1.dev92}/tinybird/tb/modules/datafile/pipe_checker.py +0 -0
  50. {tinybird-0.0.1.dev91 → tinybird-0.0.1.dev92}/tinybird/tb/modules/datafile/playground.py +0 -0
  51. {tinybird-0.0.1.dev91 → tinybird-0.0.1.dev92}/tinybird/tb/modules/datafile/pull.py +0 -0
  52. {tinybird-0.0.1.dev91 → tinybird-0.0.1.dev92}/tinybird/tb/modules/datasource.py +0 -0
  53. {tinybird-0.0.1.dev91 → tinybird-0.0.1.dev92}/tinybird/tb/modules/endpoint.py +0 -0
  54. {tinybird-0.0.1.dev91 → tinybird-0.0.1.dev92}/tinybird/tb/modules/exceptions.py +0 -0
  55. {tinybird-0.0.1.dev91 → tinybird-0.0.1.dev92}/tinybird/tb/modules/feedback_manager.py +0 -0
  56. {tinybird-0.0.1.dev91 → tinybird-0.0.1.dev92}/tinybird/tb/modules/fmt.py +0 -0
  57. {tinybird-0.0.1.dev91 → tinybird-0.0.1.dev92}/tinybird/tb/modules/job.py +0 -0
  58. {tinybird-0.0.1.dev91 → tinybird-0.0.1.dev92}/tinybird/tb/modules/llm.py +0 -0
  59. {tinybird-0.0.1.dev91 → tinybird-0.0.1.dev92}/tinybird/tb/modules/llm_utils.py +0 -0
  60. {tinybird-0.0.1.dev91 → tinybird-0.0.1.dev92}/tinybird/tb/modules/local.py +0 -0
  61. {tinybird-0.0.1.dev91 → tinybird-0.0.1.dev92}/tinybird/tb/modules/local_common.py +0 -0
  62. {tinybird-0.0.1.dev91 → tinybird-0.0.1.dev92}/tinybird/tb/modules/login.py +0 -0
  63. {tinybird-0.0.1.dev91 → tinybird-0.0.1.dev92}/tinybird/tb/modules/logout.py +0 -0
  64. {tinybird-0.0.1.dev91 → tinybird-0.0.1.dev92}/tinybird/tb/modules/materialization.py +0 -0
  65. {tinybird-0.0.1.dev91 → tinybird-0.0.1.dev92}/tinybird/tb/modules/mock.py +0 -0
  66. {tinybird-0.0.1.dev91 → tinybird-0.0.1.dev92}/tinybird/tb/modules/pipe.py +0 -0
  67. {tinybird-0.0.1.dev91 → tinybird-0.0.1.dev92}/tinybird/tb/modules/project.py +0 -0
  68. {tinybird-0.0.1.dev91 → tinybird-0.0.1.dev92}/tinybird/tb/modules/regions.py +0 -0
  69. {tinybird-0.0.1.dev91 → tinybird-0.0.1.dev92}/tinybird/tb/modules/secret.py +0 -0
  70. {tinybird-0.0.1.dev91 → tinybird-0.0.1.dev92}/tinybird/tb/modules/shell.py +0 -0
  71. {tinybird-0.0.1.dev91 → tinybird-0.0.1.dev92}/tinybird/tb/modules/table.py +0 -0
  72. {tinybird-0.0.1.dev91 → tinybird-0.0.1.dev92}/tinybird/tb/modules/tag.py +0 -0
  73. {tinybird-0.0.1.dev91 → tinybird-0.0.1.dev92}/tinybird/tb/modules/telemetry.py +0 -0
  74. {tinybird-0.0.1.dev91 → tinybird-0.0.1.dev92}/tinybird/tb/modules/tinyunit/tinyunit.py +0 -0
  75. {tinybird-0.0.1.dev91 → tinybird-0.0.1.dev92}/tinybird/tb/modules/tinyunit/tinyunit_lib.py +0 -0
  76. {tinybird-0.0.1.dev91 → tinybird-0.0.1.dev92}/tinybird/tb/modules/token.py +0 -0
  77. {tinybird-0.0.1.dev91 → tinybird-0.0.1.dev92}/tinybird/tb/modules/watch.py +0 -0
  78. {tinybird-0.0.1.dev91 → tinybird-0.0.1.dev92}/tinybird/tb/modules/workspace.py +0 -0
  79. {tinybird-0.0.1.dev91 → tinybird-0.0.1.dev92}/tinybird/tb/modules/workspace_members.py +0 -0
  80. {tinybird-0.0.1.dev91 → tinybird-0.0.1.dev92}/tinybird/tb_cli.py +0 -0
  81. {tinybird-0.0.1.dev91 → tinybird-0.0.1.dev92}/tinybird/tb_cli_modules/auth.py +0 -0
  82. {tinybird-0.0.1.dev91 → tinybird-0.0.1.dev92}/tinybird/tb_cli_modules/branch.py +0 -0
  83. {tinybird-0.0.1.dev91 → tinybird-0.0.1.dev92}/tinybird/tb_cli_modules/cicd.py +0 -0
  84. {tinybird-0.0.1.dev91 → tinybird-0.0.1.dev92}/tinybird/tb_cli_modules/cli.py +0 -0
  85. {tinybird-0.0.1.dev91 → tinybird-0.0.1.dev92}/tinybird/tb_cli_modules/common.py +0 -0
  86. {tinybird-0.0.1.dev91 → tinybird-0.0.1.dev92}/tinybird/tb_cli_modules/config.py +0 -0
  87. {tinybird-0.0.1.dev91 → tinybird-0.0.1.dev92}/tinybird/tb_cli_modules/connection.py +0 -0
  88. {tinybird-0.0.1.dev91 → tinybird-0.0.1.dev92}/tinybird/tb_cli_modules/datasource.py +0 -0
  89. {tinybird-0.0.1.dev91 → tinybird-0.0.1.dev92}/tinybird/tb_cli_modules/exceptions.py +0 -0
  90. {tinybird-0.0.1.dev91 → tinybird-0.0.1.dev92}/tinybird/tb_cli_modules/fmt.py +0 -0
  91. {tinybird-0.0.1.dev91 → tinybird-0.0.1.dev92}/tinybird/tb_cli_modules/job.py +0 -0
  92. {tinybird-0.0.1.dev91 → tinybird-0.0.1.dev92}/tinybird/tb_cli_modules/pipe.py +0 -0
  93. {tinybird-0.0.1.dev91 → tinybird-0.0.1.dev92}/tinybird/tb_cli_modules/regions.py +0 -0
  94. {tinybird-0.0.1.dev91 → tinybird-0.0.1.dev92}/tinybird/tb_cli_modules/tag.py +0 -0
  95. {tinybird-0.0.1.dev91 → tinybird-0.0.1.dev92}/tinybird/tb_cli_modules/telemetry.py +0 -0
  96. {tinybird-0.0.1.dev91 → tinybird-0.0.1.dev92}/tinybird/tb_cli_modules/test.py +0 -0
  97. {tinybird-0.0.1.dev91 → tinybird-0.0.1.dev92}/tinybird/tb_cli_modules/tinyunit/tinyunit.py +0 -0
  98. {tinybird-0.0.1.dev91 → tinybird-0.0.1.dev92}/tinybird/tb_cli_modules/tinyunit/tinyunit_lib.py +0 -0
  99. {tinybird-0.0.1.dev91 → tinybird-0.0.1.dev92}/tinybird/tb_cli_modules/workspace.py +0 -0
  100. {tinybird-0.0.1.dev91 → tinybird-0.0.1.dev92}/tinybird/tb_cli_modules/workspace_members.py +0 -0
  101. {tinybird-0.0.1.dev91 → tinybird-0.0.1.dev92}/tinybird/tornado_template.py +0 -0
  102. {tinybird-0.0.1.dev91 → tinybird-0.0.1.dev92}/tinybird.egg-info/SOURCES.txt +0 -0
  103. {tinybird-0.0.1.dev91 → tinybird-0.0.1.dev92}/tinybird.egg-info/dependency_links.txt +0 -0
  104. {tinybird-0.0.1.dev91 → tinybird-0.0.1.dev92}/tinybird.egg-info/entry_points.txt +0 -0
  105. {tinybird-0.0.1.dev91 → tinybird-0.0.1.dev92}/tinybird.egg-info/requires.txt +0 -0
  106. {tinybird-0.0.1.dev91 → tinybird-0.0.1.dev92}/tinybird.egg-info/top_level.txt +0 -0
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.2
2
2
  Name: tinybird
3
- Version: 0.0.1.dev91
3
+ Version: 0.0.1.dev92
4
4
  Summary: Tinybird Command Line Tool
5
5
  Home-page: https://www.tinybird.co/docs/cli/introduction.html
6
6
  Author: Tinybird
@@ -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__ = '0.0.1.dev91'
8
- __revision__ = 'b965ddf'
7
+ __version__ = '0.0.1.dev92'
8
+ __revision__ = 'd99cccc'
@@ -4,7 +4,7 @@ import sys
4
4
  import time
5
5
  from datetime import datetime
6
6
  from pathlib import Path
7
- from typing import Optional, Union
7
+ from typing import Any, Dict, Optional, Union
8
8
 
9
9
  import click
10
10
  import requests
@@ -330,7 +330,7 @@ def create_deployment(
330
330
  }
331
331
  project: Project = ctx.ensure_object(dict)["project"]
332
332
  client = ctx.ensure_object(dict)["client"]
333
- config = ctx.ensure_object(dict)["config"]
333
+ config: Dict[str, Any] = ctx.ensure_object(dict)["config"]
334
334
  TINYBIRD_API_URL = f"{client.host}/v1/deploy"
335
335
  TINYBIRD_API_KEY = client.token
336
336
 
@@ -62,7 +62,7 @@ def playground(
62
62
  """Build the project in Tinybird Local."""
63
63
  project: Project = ctx.ensure_object(dict)["project"]
64
64
  tb_client: TinyB = ctx.ensure_object(dict)["client"]
65
- config: CLIConfig = ctx.ensure_object(dict)["config"]
65
+ config = CLIConfig.get_project_config()
66
66
  context.disable_template_security_validation.set(True)
67
67
 
68
68
  async def process(filenames: List[str], watch: bool = False):
@@ -5,6 +5,7 @@
5
5
 
6
6
  import difflib
7
7
  import glob
8
+ import os
8
9
  import sys
9
10
  import urllib.parse
10
11
  from pathlib import Path
@@ -75,8 +76,8 @@ async def test_create(ctx: click.Context, name_or_filename: str, prompt: str) ->
75
76
  """
76
77
  project: Project = ctx.ensure_object(dict)["project"]
77
78
  client: TinyB = ctx.ensure_object(dict)["client"]
78
- config: CLIConfig = ctx.ensure_object(dict)["config"]
79
- root_path = Path(project.folder)
79
+ config = CLIConfig.get_project_config()
80
+ root_path = project.path
80
81
  folder = project.folder
81
82
  try:
82
83
  if ".pipe" in name_or_filename:
@@ -85,20 +86,17 @@ async def test_create(ctx: click.Context, name_or_filename: str, prompt: str) ->
85
86
  raise CLIException(FeedbackManager.error(message=f"Pipe {name_or_filename} not found"))
86
87
  else:
87
88
  pipe_folders = ("endpoints", "copies", "materializations", "sinks", "pipes")
88
- try:
89
- pipe_path = next(
90
- root_path / folder / f"{name_or_filename}.pipe"
91
- for folder in pipe_folders
92
- if (root_path / folder / f"{name_or_filename}.pipe").exists()
93
- )
94
- except Exception:
89
+ pipe_path = next(
90
+ root_path / folder / f"{name_or_filename}.pipe"
91
+ for folder in pipe_folders
92
+ if os.path.exists(root_path / folder / f"{name_or_filename}.pipe")
93
+ )
94
+ if not pipe_path:
95
95
  raise CLIException(FeedbackManager.error(message=f"Pipe {name_or_filename} not found"))
96
96
 
97
97
  pipe_name = pipe_path.stem
98
98
  click.echo(FeedbackManager.highlight(message=f"\n» Creating tests for {pipe_name} endpoint..."))
99
- pipe_path = root_path / pipe_path
100
99
  pipe_content = pipe_path.read_text()
101
-
102
100
  pipe = await client._req(f"/v0/pipes/{pipe_name}")
103
101
  parameters = set([param["name"] for node in pipe["nodes"] for param in node["params"]])
104
102
 
@@ -112,7 +110,6 @@ async def test_create(ctx: click.Context, name_or_filename: str, prompt: str) ->
112
110
  raise CLIException(FeedbackManager.error(message="No user token found"))
113
111
 
114
112
  llm = LLM(user_token=user_token, host=config.get_client().host)
115
- click.echo(FeedbackManager.highlight(message=f"\n» Creating test for {pipe_name} endpoint..."))
116
113
  response_llm = llm.ask(system_prompt=system_prompt, prompt=prompt)
117
114
  response_xml = extract_xml(response_llm, "response")
118
115
  tests_content = parse_xml(response_xml, "test")
@@ -216,9 +213,12 @@ async def test_update(ctx: click.Context, pipe: str) -> None:
216
213
  async def run_tests(ctx: click.Context, name: Tuple[str, ...]) -> None:
217
214
  click.echo(FeedbackManager.highlight(message="\n» Running tests"))
218
215
  client: TinyB = ctx.ensure_object(dict)["client"]
216
+ project: Project = ctx.ensure_object(dict)["project"]
219
217
  paths = [Path(n) for n in name]
220
- endpoints = [f"./tests/{p.stem}.yaml" for p in paths]
221
- test_files: List[str] = endpoints if len(endpoints) > 0 else glob.glob("./tests/**/*.y*ml", recursive=True)
218
+ endpoints = [f"{project.path}/tests/{p.stem}.yaml" for p in paths]
219
+ test_files: List[str] = (
220
+ endpoints if len(endpoints) > 0 else glob.glob(f"{project.path}/tests/**/*.y*ml", recursive=True)
221
+ )
222
222
 
223
223
  async def run_test(test_file):
224
224
  test_file_path = Path(test_file)
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.2
2
2
  Name: tinybird
3
- Version: 0.0.1.dev91
3
+ Version: 0.0.1.dev92
4
4
  Summary: Tinybird Command Line Tool
5
5
  Home-page: https://www.tinybird.co/docs/cli/introduction.html
6
6
  Author: Tinybird
File without changes