charisma-cli 0.6.0__tar.gz → 0.6.1__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 (39) hide show
  1. {charisma_cli-0.6.0 → charisma_cli-0.6.1}/PKG-INFO +1 -1
  2. {charisma_cli-0.6.0 → charisma_cli-0.6.1}/pyproject.toml +1 -1
  3. {charisma_cli-0.6.0 → charisma_cli-0.6.1}/src/charisma_cli/__init__.py +1 -1
  4. {charisma_cli-0.6.0 → charisma_cli-0.6.1}/src/charisma_cli/main.py +10 -4
  5. {charisma_cli-0.6.0 → charisma_cli-0.6.1}/src/charisma_cli/watcher.py +3 -2
  6. {charisma_cli-0.6.0 → charisma_cli-0.6.1}/tests/test_silent_mode.py +16 -1
  7. {charisma_cli-0.6.0 → charisma_cli-0.6.1}/tests/test_watcher.py +5 -0
  8. {charisma_cli-0.6.0 → charisma_cli-0.6.1}/.gitignore +0 -0
  9. {charisma_cli-0.6.0 → charisma_cli-0.6.1}/README.md +0 -0
  10. {charisma_cli-0.6.0 → charisma_cli-0.6.1}/src/charisma_cli/config.py +0 -0
  11. {charisma_cli-0.6.0 → charisma_cli-0.6.1}/src/charisma_cli/launch_url.py +0 -0
  12. {charisma_cli-0.6.0 → charisma_cli-0.6.1}/src/charisma_cli/models.py +0 -0
  13. {charisma_cli-0.6.0 → charisma_cli-0.6.1}/src/charisma_cli/parser.py +0 -0
  14. {charisma_cli-0.6.0 → charisma_cli-0.6.1}/src/charisma_cli/read_client.py +0 -0
  15. {charisma_cli-0.6.0 → charisma_cli-0.6.1}/src/charisma_cli/read_models.py +0 -0
  16. {charisma_cli-0.6.0 → charisma_cli-0.6.1}/src/charisma_cli/retry.py +0 -0
  17. {charisma_cli-0.6.0 → charisma_cli-0.6.1}/src/charisma_cli/subprocess_mgr.py +0 -0
  18. {charisma_cli-0.6.0 → charisma_cli-0.6.1}/src/charisma_cli/uploader.py +0 -0
  19. {charisma_cli-0.6.0 → charisma_cli-0.6.1}/tests/__init__.py +0 -0
  20. {charisma_cli-0.6.0 → charisma_cli-0.6.1}/tests/conftest.py +0 -0
  21. {charisma_cli-0.6.0 → charisma_cli-0.6.1}/tests/test_bamboo_labels.py +0 -0
  22. {charisma_cli-0.6.0 → charisma_cli-0.6.1}/tests/test_cli.py +0 -0
  23. {charisma_cli-0.6.0 → charisma_cli-0.6.1}/tests/test_config.py +0 -0
  24. {charisma_cli-0.6.0 → charisma_cli-0.6.1}/tests/test_integration.py +0 -0
  25. {charisma_cli-0.6.0 → charisma_cli-0.6.1}/tests/test_launch_url.py +0 -0
  26. {charisma_cli-0.6.0 → charisma_cli-0.6.1}/tests/test_models.py +0 -0
  27. {charisma_cli-0.6.0 → charisma_cli-0.6.1}/tests/test_open_launch_payload.py +0 -0
  28. {charisma_cli-0.6.0 → charisma_cli-0.6.1}/tests/test_parser.py +0 -0
  29. {charisma_cli-0.6.0 → charisma_cli-0.6.1}/tests/test_read_client.py +0 -0
  30. {charisma_cli-0.6.0 → charisma_cli-0.6.1}/tests/test_read_client_attachments.py +0 -0
  31. {charisma_cli-0.6.0 → charisma_cli-0.6.1}/tests/test_read_client_integration.py +0 -0
  32. {charisma_cli-0.6.0 → charisma_cli-0.6.1}/tests/test_read_client_launches.py +0 -0
  33. {charisma_cli-0.6.0 → charisma_cli-0.6.1}/tests/test_read_client_pagination.py +0 -0
  34. {charisma_cli-0.6.0 → charisma_cli-0.6.1}/tests/test_read_client_results.py +0 -0
  35. {charisma_cli-0.6.0 → charisma_cli-0.6.1}/tests/test_read_client_single_result.py +0 -0
  36. {charisma_cli-0.6.0 → charisma_cli-0.6.1}/tests/test_retry.py +0 -0
  37. {charisma_cli-0.6.0 → charisma_cli-0.6.1}/tests/test_subprocess_mgr.py +0 -0
  38. {charisma_cli-0.6.0 → charisma_cli-0.6.1}/tests/test_testplan_cmd.py +0 -0
  39. {charisma_cli-0.6.0 → charisma_cli-0.6.1}/tests/test_uploader.py +0 -0
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.5
2
2
  Name: charisma-cli
3
- Version: 0.6.0
3
+ Version: 0.6.1
4
4
  Summary: CLI tool that watches allure-results and streams test results + attachments to Charisma.
5
5
  Author: Charisma Team
6
6
  License-Expression: MIT
@@ -5,7 +5,7 @@ build-backend = "hatchling.build"
5
5
 
6
6
  [project]
7
7
  name = "charisma-cli"
8
- version = "0.6.0"
8
+ version = "0.6.1"
9
9
  description = "CLI tool that watches allure-results and streams test results + attachments to Charisma."
10
10
  readme = "README.md"
11
11
  license = "MIT"
@@ -4,4 +4,4 @@
4
4
  # is generated from pyproject.toml [project].version, so keeping this literal
5
5
  # equal to pyproject guarantees `--version` reports the published version. The
6
6
  # prepare-commit step owns the PATCH bump — do not hand-bump here.
7
- __version__ = "0.6.0"
7
+ __version__ = "0.6.1"
@@ -138,9 +138,15 @@ def _warn_if_results_unsent(uploader: Uploader, config: Config) -> None:
138
138
  )
139
139
 
140
140
 
141
- def _print_summary(uploader: Uploader) -> None:
142
- """Print the upload summary to stdout."""
141
+ def _print_summary(uploader: Uploader, config: Config) -> None:
142
+ """Print the upload summary to stdout; under --silent also flag skips on stderr."""
143
143
  summary = uploader.summary
144
+ if config.silent and summary.attachments_skipped:
145
+ click.echo(
146
+ f"Warning: {summary.attachments_skipped} attachment(s) skipped; "
147
+ "rerun without --silent to see which.",
148
+ err=True,
149
+ )
144
150
  click.echo(
145
151
  f"Summary: results_sent={summary.results_sent}, "
146
152
  f"results_failed={summary.results_failed}, "
@@ -307,7 +313,7 @@ def watch(
307
313
  uploader._client = None
308
314
 
309
315
  _warn_if_results_unsent(uploader, config)
310
- _print_summary(uploader)
316
+ _print_summary(uploader, config)
311
317
 
312
318
  if not fully_drained:
313
319
  click.echo(
@@ -399,7 +405,7 @@ def upload(
399
405
  uploader.close_launch(variables=_read_launch_variables(config))
400
406
  uploader.stop()
401
407
 
402
- _print_summary(uploader)
408
+ _print_summary(uploader, config)
403
409
 
404
410
  if not fully_drained:
405
411
  click.echo(
@@ -54,11 +54,12 @@ def classify_file(filename: str) -> FileCategory | None:
54
54
  FileCategory.RESULT for *-result.json,
55
55
  FileCategory.CONTAINER for *-container.json,
56
56
  FileCategory.ATTACHMENT for all other valid files,
57
- None for excluded files (dot-prefix or .tmp suffix).
57
+ None for excluded files (dot-prefix, .tmp suffix, or environment.properties,
58
+ which is read separately as launch variables and has no owning result).
58
59
  """
59
60
  if filename.startswith("."):
60
61
  return None
61
- if filename.endswith(".tmp"):
62
+ if filename.endswith(".tmp") or filename == "environment.properties":
62
63
  return None
63
64
  if filename.endswith("-result.json"):
64
65
  return FileCategory.RESULT
@@ -5,10 +5,11 @@ from pathlib import Path
5
5
  from queue import PriorityQueue
6
6
 
7
7
  import httpx
8
+ import pytest
8
9
  import respx
9
10
 
10
11
  from charisma_cli.config import Config
11
- from charisma_cli.models import FileCategory, FileEvent
12
+ from charisma_cli.models import FileCategory, FileEvent, UploadSummary
12
13
  from charisma_cli.uploader import Uploader
13
14
 
14
15
 
@@ -215,3 +216,17 @@ class TestLaunchLifecycle:
215
216
  uploader.close_launch()
216
217
 
217
218
  uploader._client.close()
219
+
220
+
221
+ @pytest.mark.parametrize(("silent", "skipped", "warns"), [(True, 2, True), (True, 0, False), (False, 2, False)])
222
+ def test_silent_summary_warns_on_stderr_only_for_skips(capsys, silent: bool, skipped: int, warns: bool) -> None:
223
+ """--silent still flags skipped attachments on stderr."""
224
+ from types import SimpleNamespace
225
+
226
+ from charisma_cli.main import _print_summary
227
+
228
+ uploader = SimpleNamespace(
229
+ summary=UploadSummary(attachments_skipped=skipped)
230
+ )
231
+ _print_summary(uploader, _make_config(silent=silent))
232
+ assert ("skipped" in capsys.readouterr().err) is warns
@@ -45,6 +45,11 @@ class TestClassifyFileContainerPattern:
45
45
  assert classify_file("session-scope-container.json") == FileCategory.CONTAINER
46
46
 
47
47
 
48
+ def test_environment_properties_is_not_an_attachment() -> None:
49
+ # Regression: it was queued as an ownerless attachment (attachments_skipped=1 on every run).
50
+ assert classify_file("environment.properties") is None
51
+
52
+
48
53
  class TestClassifyFileAttachmentFallback:
49
54
  """All other files are classified as ATTACHMENT."""
50
55
 
File without changes
File without changes