Hacktoberfest 2026: the issues maintainers tagged for October, open and beginner-friendly. Browse Hacktoberfest issues

Decorator for basic enter and exit logging for functions.

Open
#241 2 comments 3 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Assessment

Difficulty
4/5
Estimated time
3-5 days
Newbie friendliness
25/100
Issue type
Feature
Clarity
Mostly clear
Activity status
Stale
Tech stack
python
Domain
backend

Research direction

The issue describes a decorator that logs function parameters and bound variables on entry, then the return value on exit; it names no files or tests. Start by reading the project’s decorator and context binding APIs to find where this feature could fit. Done means entry and exit logs include the requested values and bindings can be set, reset, or updated.

Written by the indexing model from the issue text.

Description

A decorator that creates a log statement with bound variables at entry and exit of the decorated functions. The bound variables can be set, reset or updated, so every log statement from inside the function can use these.

On entry, the decorator will print the passed passed parameters along with bound variables, and upon exit it will print the returned value if any in the exit log message.

This approach helps in removing the redundant log statements for entry and exit.
The binding of default values unrelated to the context of function in decorator also helps in achieving separation of concerns.

Thanks for the great library.

Dominant language
Python
Stars
5k
Forks
302
Avg merge
17m
Merged PRs (30d)
4

Getting set up

This project ships no dev container, Dockerfile or contributing guide, so setting up is up to you: start from its README, and see our first-contribution guide for the general steps.

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.

More from hynek/structlog

All issues in hynek/structlog

Similar issues

More Python issues

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.