Skip to content

pageviewapi not working on python 3.10 #7

Closed

Description

@andres-trrs

raceback (most recent call last):
File "c:\Users\User\Desktop\universidad\base de datos\INFO133_2022-main\nlp\demo_wikipedia_2.py", line 2, in
import pageviewapi
File "C:\Users\User\AppData\Local\Packages\PythonSoftwareFoundation.Python.3.10_qbz5n2kfra8p0\LocalCache\local-packages\Python310\site-packages\pageviewapi_init_.py", line 3, in
from pageviewapi.client import (
File "C:\Users\User\AppData\Local\Packages\PythonSoftwareFoundation.Python.3.10_qbz5n2kfra8p0\LocalCache\local-packages\Python310\site-packages\pageviewapi\client.py", line 10, in
from attrdict import AttrDict
File "C:\Users\User\AppData\Local\Packages\PythonSoftwareFoundation.Python.3.10_qbz5n2kfra8p0\LocalCache\local-packages\Python310\site-packages\attrdict_init_.py", line 5, in
from attrdict.mapping import AttrMap
File "C:\Users\User\AppData\Local\Packages\PythonSoftwareFoundation.Python.3.10_qbz5n2kfra8p0\LocalCache\local-packages\Python310\site-packages\attrdict\mapping.py", line 4, in
from collections import Mapping
ImportError: cannot import name 'Mapping' from 'collections' (C:\Program Files\WindowsApps\PythonSoftwareFoundation.Python.3.10_3.10.1520.0_x64__qbz5n2kfra8p0\lib\collections_init_.py)

Activity

  1. jagra26 commented on Mar 25, 2024

    @jagra26

    I made a fork of AttrDict with the changes to run in python 3.10.

    First, run:

    pip install git+https://github.com/jagra26/AttrDict.git
    

    and rerun:

    pip install pageviewapi
    

    pageviewapi works fine again.

  2. PierreSelim commented on May 15, 2026

    @PierreSelim
    Member

    Sorry for the delay, I am in the process of modernizing the library, and drop the support of old python.

    We should soon officially support 3.10+ (we have reproduced the behaviour of AttrDict without using it anymore): #8

    So hopefully this will be closed soon.

  3. PierreSelim commented on May 17, 2026

    @PierreSelim
    Member

    Now the version in master supports Python 3.10+ (and drops former version as they are old). I'll push a release later next week.

  4. self-assigned this
    on May 17, 2026
  5. added this to the v0.5.0 milestone on May 17, 2026
  6. PierreSelim commented on May 18, 2026

    @PierreSelim
    Member

    The v0.5.0 does support Python 3.10 and is available on pypi.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Labels

No labels
No labels

Type

No type

Projects

No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions