Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Python 3.12 - AttributeError: module 'pathlib' has no attribute '_Flavour' #150

Open
shenxianpeng opened this issue Oct 7, 2024 · 0 comments

Comments

@shenxianpeng
Copy link

shenxianpeng commented Oct 7, 2024

Successfully installed PyJWT-2.9.0 artifactory-cleanup-1.0.12 attrs-24.2.0 dohq-artifactory-0.10.1 hurry.filesize-0.9 plumbum-1.9.0 prettytable-3.11.0 pydash-8.0.3 python-dateutil-2.9.0.post0 teamcity-messages-1.32 treelib-1.7.0 typing-extensions-4.12.2 wcwidth-0.2.13
+ python3 cleanup.py --destroy --user test --password **** --artifactory-server https://artifactory.myorg.com/artifactory --config cleanup.py
Traceback (most recent call last):
  File "/mv/workspace/Infra/artifactory-repo-cleanup/happybee/artifactory/cleanup.py", line 1, in <module>
    from artifactory_cleanup import CleanupPolicy, rules
  File "/home/blwmv/.local/lib/python3.12/site-packages/artifactory_cleanup/__init__.py", line 1, in <module>
    from artifactory_cleanup.cli import ArtifactoryCleanupCLI  # noqa
    ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/home/blwmv/.local/lib/python3.12/site-packages/artifactory_cleanup/cli.py", line 13, in <module>
    from artifactory_cleanup.artifactorycleanup import (
  File "/home/blwmv/.local/lib/python3.12/site-packages/artifactory_cleanup/artifactorycleanup.py", line 9, in <module>
    from artifactory_cleanup.rules.base import ArtifactsList, CleanupPolicy, ArtifactDict
  File "/home/blwmv/.local/lib/python3.12/site-packages/artifactory_cleanup/rules/__init__.py", line 3, in <module>
    from artifactory_cleanup.rules.docker import *  # noqa
    ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/home/blwmv/.local/lib/python3.12/site-packages/artifactory_cleanup/rules/docker.py", line 7, in <module>
    from artifactory import ArtifactoryPath
  File "/home/blwmv/.local/lib/python3.12/site-packages/artifactory.py", line 425, in <module>
    class _ArtifactoryFlavour(pathlib._Flavour):
                              ^^^^^^^^^^^^^^^^
AttributeError: module 'pathlib' has no attribute '_Flavour'

This issue was caused by the upstream project issue devopshq/artifactory#430

@allburov allburov changed the title AttributeError: module 'pathlib' has no attribute '_Flavour' Python 3.12 - AttributeError: module 'pathlib' has no attribute '_Flavour' Oct 8, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Development

No branches or pull requests

1 participant