Skip to content

profiling.sampling (Tachyon) gecko output: Only source file basename is shown #160976

Description

@laundmo

Bug report

When using the --gecko exporter for profiling.sampling, only the basename for source files is shown.

This means that to distinguish, for example, samples from __init__.py, the function name and surrounding context has to be read, which is rather unfortunate.

Related source lines:

filename_idx = self._intern_string(os.path.basename(filename))

resource_name = (
os.path.basename(filename) if "/" in filename else filename
)

Tested on 3.15, but gecko exporter source code matches.

CPython versions tested on:

3.15

Operating systems tested on:

Linux

Linked PRs

Activity

  1. makwana-akshat commented on Oct 30, 2026

    @makwana-akshat

    i would like to solve this issue. assign/

  2. added a commit that references this issue on Oct 30, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    stdlibStandard Library Python modules in the Lib/ directorytopic-profilingtype-bugAn unexpected behavior, bug, or error

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions

      ⌂ Proxy