Azure / Azure/azure-sdk-for-python

[pylint] Importing public name into public module from another public module prohibit

Open
#40,020 0 comments 0 reactions 1 assignee Claimed by @l0lawrence View on GitHub
pylint
Dominant language
Python
Stars
5.6k
Forks
3.4k
Avg merge
1d 21h
Merged PRs (30d)
193

Description

![Image](https://github.com/user-attachments/assets/3f791f3a-a2b5-49f6-8ba1-b2bf216c7b20)

- azure/core/tracing/common.py has the definition and implementation of change_context.
- azure/core/tracing/decorator.py has an import like from .common import change_context, so this import makes azure.core.tracing.decorator.change_context a public API.
- Ideally we'd want this to be imported as from .common import change_context as _change_context
- This is only a problem with public modules/namespaces. If there is an underscore-prefix anywhere in the module name, (i.e. azure.core._internal.utils, then this shouldn't apply.

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.