psf / psf/pyperf

Improve Type System for `pyperf`

Open
#255 2 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
Python
Stars
962
Forks
106
Avg merge
2d 18h
Merged PRs (30d)
4

Description

Description

  • I recently came across pyperf because I want to do some benchmark testing of my changes which I did on an opensource project named ArchUnitPython which are generally to improve the performance of the library. Initially I wanted to start with inbuilt time module but later I found pyperf which kind of can produce good benchmark by handling things like cold start, number of process spawn, warm benchmark etc. But during coding I found that the type system of pyperf is not good as most of most return type and function parameter have Unknown type which kind of hindering my auto completion and understanding of that function or parameter.
  • Eg;
Image Image
  • Now it might be issue from pyrefly typechecker but the thing is the library on which I contributed and benchmarking my changes have no Unknown (Till now) same for other libraries like FastAPI, PydanticAI and some more.
  • Because of this I am planning to do contribution to the library and improve the type system of pyperf.

If any maintainer could guide me or discuses in this issue, then it would be helpful.

Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start by inspecting pyperf's public APIs and the examples shown in the issue, then reproduce the reported Unknown types with a type checker such as pyrefly. Done means the affected public parameters and return values expose useful, accurate types and the reported autocomplete and type-checking problems are resolved.

Written by the indexing model from the issue text.

Assessment

Tech stack
python
Domain
developer-experience, tooling
Issue type
Refactor
Difficulty
4/5
Estimated time
3-5 days
Activity status
Active
Clarity
Needs clarification
Newbie friendliness
45/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.