Skip to content

0.0.2#2

Merged
pomponchik merged 11 commits intomainfrom
develop
Apr 14, 2026
Merged

0.0.2#2
pomponchik merged 11 commits intomainfrom
develop

Conversation

@pomponchik
Copy link
Copy Markdown
Contributor

@pomponchik pomponchik commented Apr 13, 2026

A little but useful update:

  • Added arguments class to capture positional and keyword arguments for benchmarked functions. Exported it from the package along with a short alias a.
  • Added median as a @cached_property to BenchmarkResult, consistent with p95/p99.
  • Updated Scenario constructor: name is now optional and auto-derived from function.__name__; arguments object replaces the old positional args parameter.
  • Expanded CLI output to include call:, doc:, runs:, median:, p95 mean:, p99 mean: lines, and a FAIL: message when --max-mean is exceeded.
  • Rewrote all tests from class-based to function-based style. Added new unit, CLI, documentation, and typing tests to cover all the new behaviour.
  • Added printo as an explicit package dependency so it is installed in all environments.
  • Fixed coverage failure on Python 3.13/Linux by adding direct unit tests for the OSError fallback path in _fn_call_str, which is unreachable on that platform due to a difference in how getsources signals source-retrieval errors.
  • Fixed typing test failure on Python 3.8 where mypy formats optional types as Optional[X] instead of X | None. Replaced the full expected message with just [arg-type] so the match is version-independent.

@pomponchik pomponchik merged commit 5a877a8 into main Apr 14, 2026
36 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant