Skip to content

BUG: Module pandas._libs.json has incorrect __name__ attribute #52898

Closed
@shwina

Description

@shwina

Pandas version checks

  • I have checked that this issue has not already been reported.

  • I have confirmed this bug exists on the latest version of pandas.

  • I have confirmed this bug exists on the main branch of pandas.

Reproducible Example

>>> import pandas as pd
pd>>> pd.__version__
'2.0.0'
>>> pd._libs.json.__name__
'_libjson'
>>> pd._libs.missing.__name__
'pandas._libs.missing'

Issue Description

The __name__ attribute for the pandas._libs.json is set to _libjson here.

The Python docs say that __name__ should be set to the fully qualified name of the module, which I would expect to be 'pandas._libs.json'.

In the code example above, you can see that other Pandas C-extensions like pd._libs.missing have the correct __name__ attribute set.

Expected Behavior

__name__ should be set to the fully qualified name of the module, which I would expect to be 'pandas._libs.json'.

Installed Versions

2

Metadata

Metadata

Assignees

No one assigned

    Labels

    BugIO JSONread_json, to_json, json_normalize

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions