Skip to content

Python templates: Add dev setup (linter, type checker, tests) #725

@vdusek

Description

@vdusek

Context

In the context of AI-assisted development, a fast feedback loop is essential for coding agents. When an agent writes code, it needs immediate signals about correctness — type errors, lint violations, test failures — to iterate effectively.

JS/TS Actor templates already provide this through dev dependencies: type checking, linting, etc. Python templates currently lack any dev setup, partly because they only use a plain requirements.txt with no concept of dev dependencies.

Goal

Add a proper development setup to Python Actor templates, including:

  • Linter — e.g. Ruff (covers both linting and formatting)
  • Type checkerty (from the Astral ecosystem, pairs well with Ruff)
  • Configurationpyproject.toml with sensible defaults for all tools
  • Test setup — basic pytest configuration so users (and agents) can write and run tests out of the box

This would bring Python templates closer to parity with JS/TS templates in terms of developer experience and make them significantly more useful in AI-assisted workflows.

Notes

Parent issue

Sub-issue of https://github.com/apify/apify-core/issues/25871

Metadata

Metadata

Assignees

Labels

t-toolingIssues with this label are in the ownership of the tooling team.

Type

No type
No fields configured for issues without a type.

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions