pingera-cli 0.1.4__tar.gz → 0.1.5__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 (47) hide show
  1. {pingera_cli-0.1.4/pingera_cli.egg-info → pingera_cli-0.1.5}/PKG-INFO +2 -2
  2. {pingera_cli-0.1.4 → pingera_cli-0.1.5}/pingera_cli/__init__.py +1 -1
  3. {pingera_cli-0.1.4 → pingera_cli-0.1.5}/pingera_cli/commands/secrets.py +26 -11
  4. {pingera_cli-0.1.4 → pingera_cli-0.1.5/pingera_cli.egg-info}/PKG-INFO +2 -2
  5. {pingera_cli-0.1.4 → pingera_cli-0.1.5}/pingera_cli.egg-info/requires.txt +1 -1
  6. {pingera_cli-0.1.4 → pingera_cli-0.1.5}/pyproject.toml +1 -1
  7. {pingera_cli-0.1.4 → pingera_cli-0.1.5}/.gitignore +0 -0
  8. {pingera_cli-0.1.4 → pingera_cli-0.1.5}/.replit +0 -0
  9. {pingera_cli-0.1.4 → pingera_cli-0.1.5}/LICENSE +0 -0
  10. {pingera_cli-0.1.4 → pingera_cli-0.1.5}/README.md +0 -0
  11. {pingera_cli-0.1.4 → pingera_cli-0.1.5}/assert +0 -0
  12. {pingera_cli-0.1.4 → pingera_cli-0.1.5}/docs/cli-commands.md +0 -0
  13. {pingera_cli-0.1.4 → pingera_cli-0.1.5}/pingera_cli/__main__.py +0 -0
  14. {pingera_cli-0.1.4 → pingera_cli-0.1.5}/pingera_cli/commands/__init__.py +0 -0
  15. {pingera_cli-0.1.4 → pingera_cli-0.1.5}/pingera_cli/commands/auth.py +0 -0
  16. {pingera_cli-0.1.4 → pingera_cli-0.1.5}/pingera_cli/commands/base.py +0 -0
  17. {pingera_cli-0.1.4 → pingera_cli-0.1.5}/pingera_cli/commands/check_groups.py +0 -0
  18. {pingera_cli-0.1.4 → pingera_cli-0.1.5}/pingera_cli/commands/check_secrets.py +0 -0
  19. {pingera_cli-0.1.4 → pingera_cli-0.1.5}/pingera_cli/commands/checks.py +0 -0
  20. {pingera_cli-0.1.4 → pingera_cli-0.1.5}/pingera_cli/commands/on_demand_checks.py +0 -0
  21. {pingera_cli-0.1.4 → pingera_cli-0.1.5}/pingera_cli/formatters/__init__.py +0 -0
  22. {pingera_cli-0.1.4 → pingera_cli-0.1.5}/pingera_cli/formatters/base_formatter.py +0 -0
  23. {pingera_cli-0.1.4 → pingera_cli-0.1.5}/pingera_cli/formatters/generic_formatter.py +0 -0
  24. {pingera_cli-0.1.4 → pingera_cli-0.1.5}/pingera_cli/formatters/multistep_formatter.py +0 -0
  25. {pingera_cli-0.1.4 → pingera_cli-0.1.5}/pingera_cli/formatters/registry.py +0 -0
  26. {pingera_cli-0.1.4 → pingera_cli-0.1.5}/pingera_cli/formatters/ssl_formatter.py +0 -0
  27. {pingera_cli-0.1.4 → pingera_cli-0.1.5}/pingera_cli/formatters/synthetic_formatter.py +0 -0
  28. {pingera_cli-0.1.4 → pingera_cli-0.1.5}/pingera_cli/formatters/web_formatter.py +0 -0
  29. {pingera_cli-0.1.4 → pingera_cli-0.1.5}/pingera_cli/main.py +0 -0
  30. {pingera_cli-0.1.4 → pingera_cli-0.1.5}/pingera_cli/utils/__init__.py +0 -0
  31. {pingera_cli-0.1.4 → pingera_cli-0.1.5}/pingera_cli/utils/config.py +0 -0
  32. {pingera_cli-0.1.4 → pingera_cli-0.1.5}/pingera_cli/utils/console.py +0 -0
  33. {pingera_cli-0.1.4 → pingera_cli-0.1.5}/pingera_cli.egg-info/SOURCES.txt +0 -0
  34. {pingera_cli-0.1.4 → pingera_cli-0.1.5}/pingera_cli.egg-info/dependency_links.txt +0 -0
  35. {pingera_cli-0.1.4 → pingera_cli-0.1.5}/pingera_cli.egg-info/entry_points.txt +0 -0
  36. {pingera_cli-0.1.4 → pingera_cli-0.1.5}/pingera_cli.egg-info/top_level.txt +0 -0
  37. {pingera_cli-0.1.4 → pingera_cli-0.1.5}/replit.md +0 -0
  38. {pingera_cli-0.1.4 → pingera_cli-0.1.5}/run_tests.py +0 -0
  39. {pingera_cli-0.1.4 → pingera_cli-0.1.5}/setup.cfg +0 -0
  40. {pingera_cli-0.1.4 → pingera_cli-0.1.5}/setup.py +0 -0
  41. {pingera_cli-0.1.4 → pingera_cli-0.1.5}/tests/__init__.py +0 -0
  42. {pingera_cli-0.1.4 → pingera_cli-0.1.5}/tests/conftest.py +0 -0
  43. {pingera_cli-0.1.4 → pingera_cli-0.1.5}/tests/requirements.txt +0 -0
  44. {pingera_cli-0.1.4 → pingera_cli-0.1.5}/tests/test_auth.py +0 -0
  45. {pingera_cli-0.1.4 → pingera_cli-0.1.5}/tests/test_checks.py +0 -0
  46. {pingera_cli-0.1.4 → pingera_cli-0.1.5}/tests/test_config.py +0 -0
  47. {pingera_cli-0.1.4 → pingera_cli-0.1.5}/tests/test_on_demand_checks.py +0 -0
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: pingera-cli
3
- Version: 0.1.4
3
+ Version: 0.1.5
4
4
  Summary: A beautiful Python CLI tool built with typer and rich, distributed via pip and based on Pingera SDK
5
5
  Home-page: https://github.com/pingera/pingera-cli
6
6
  Author: PingeraCLI Team
@@ -31,7 +31,7 @@ Description-Content-Type: text/markdown
31
31
  License-File: LICENSE
32
32
  Requires-Dist: typer[all]>=0.9.0
33
33
  Requires-Dist: rich>=13.0.0
34
- Requires-Dist: pingera-sdk>=1.0.5
34
+ Requires-Dist: pingera-sdk>=1.0.6
35
35
  Requires-Dist: click>=8.0.0
36
36
  Provides-Extra: dev
37
37
  Requires-Dist: pytest>=6.0; extra == "dev"
@@ -2,7 +2,7 @@
2
2
  Pingera CLI - A beautiful CLI tool for Pingera Platform
3
3
  """
4
4
 
5
- __version__ = "0.1.4"
5
+ __version__ = "0.1.5"
6
6
  __author__ = "Pingera Team"
7
7
  __description__ = "A beautiful Python CLI tool built with typer and rich, distributed via pip and based on Pingera SDK"
8
8
 
@@ -57,33 +57,43 @@ class SecretsCommand(BaseCommand):
57
57
  # Make API call
58
58
  response = secrets_api.v1_secrets_get(page=page, page_size=page_size)
59
59
 
60
+ # Handle named tuple/object response with secrets and pagination attributes
61
+ if hasattr(response, 'secrets'):
62
+ secrets = response.secrets
63
+ pagination = getattr(response, 'pagination', {})
64
+ elif isinstance(response, (list, tuple)) and len(response) >= 2:
65
+ secrets = response[0]
66
+ pagination = response[1] if len(response) > 1 else {}
67
+ else:
68
+ secrets = response
69
+ pagination = {}
70
+
60
71
  # Handle different output formats
61
72
  if self.output_format in ['json', 'yaml']:
62
73
  # Convert to dict for JSON/YAML output
63
74
  secrets_data = {
64
- 'secrets': [secret.to_dict() for secret in response.items],
65
- 'pagination': {
66
- 'page': response.page,
67
- 'page_size': response.page_size,
68
- 'total': response.total,
69
- 'total_pages': response.total_pages
75
+ 'secrets': [secret.to_dict() for secret in secrets],
76
+ 'pagination': pagination if pagination else {
77
+ 'page': page,
78
+ 'page_size': page_size,
79
+ 'total': len(secrets)
70
80
  }
71
81
  }
72
82
  self.output_data(secrets_data)
73
83
  else:
74
84
  # Table format
75
- if not response.items:
85
+ if not secrets:
76
86
  self.display_info("No secrets found")
77
87
  return
78
88
 
79
- table = Table(title=f"Organization Secrets (Page {response.page} of {response.total_pages})")
89
+ table = Table(title="Organization Secrets")
80
90
  table.add_column("ID", style="cyan")
81
91
  table.add_column("Name", style="white")
82
92
  table.add_column("Created At", style="dim")
83
93
  table.add_column("Updated At", style="dim")
84
94
  table.add_column("Created By", style="dim")
85
95
 
86
- for secret in response.items:
96
+ for secret in secrets:
87
97
  table.add_row(
88
98
  secret.id or '',
89
99
  secret.secret_name or '',
@@ -95,8 +105,13 @@ class SecretsCommand(BaseCommand):
95
105
  console.print(table)
96
106
 
97
107
  # Show pagination info
98
- if response.total_pages > 1:
99
- console.print(f"\n[dim]Showing {len(response.items)} of {response.total} secrets[/dim]")
108
+ if pagination and pagination.get('total_pages', 1) > 1:
109
+ current_page = pagination.get('page', page)
110
+ total_pages = pagination.get('total_pages', 1)
111
+ total_items = pagination.get('total_items', len(secrets))
112
+ console.print(f"\n[dim]Page {current_page} of {total_pages} ({total_items} total secrets)[/dim]")
113
+ else:
114
+ console.print(f"\n[dim]Found {len(secrets)} secrets[/dim]")
100
115
 
101
116
  except Exception as e:
102
117
  self.display_error(f"Failed to list secrets: {str(e)}")
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: pingera-cli
3
- Version: 0.1.4
3
+ Version: 0.1.5
4
4
  Summary: A beautiful Python CLI tool built with typer and rich, distributed via pip and based on Pingera SDK
5
5
  Home-page: https://github.com/pingera/pingera-cli
6
6
  Author: PingeraCLI Team
@@ -31,7 +31,7 @@ Description-Content-Type: text/markdown
31
31
  License-File: LICENSE
32
32
  Requires-Dist: typer[all]>=0.9.0
33
33
  Requires-Dist: rich>=13.0.0
34
- Requires-Dist: pingera-sdk>=1.0.5
34
+ Requires-Dist: pingera-sdk>=1.0.6
35
35
  Requires-Dist: click>=8.0.0
36
36
  Provides-Extra: dev
37
37
  Requires-Dist: pytest>=6.0; extra == "dev"
@@ -1,6 +1,6 @@
1
1
  typer[all]>=0.9.0
2
2
  rich>=13.0.0
3
- pingera-sdk>=1.0.5
3
+ pingera-sdk>=1.0.6
4
4
  click>=8.0.0
5
5
 
6
6
  [dev]
@@ -35,7 +35,7 @@ requires-python = ">=3.7"
35
35
  dependencies = [
36
36
  "typer[all]>=0.9.0",
37
37
  "rich>=13.0.0",
38
- "pingera-sdk>=1.0.5",
38
+ "pingera-sdk>=1.0.6",
39
39
  "click>=8.0.0",
40
40
  ]
41
41
 
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes