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

Depend on audbackend>=2.0.0 #90

Merged
merged 5 commits into from
May 15, 2024
Merged

Depend on audbackend>=2.0.0 #90

merged 5 commits into from
May 15, 2024

Conversation

hagenw
Copy link
Member

@hagenw hagenw commented May 2, 2024

Updates the code to use the new API of audbackend 2.0.0.

In addition, it fixes the setting of audb shared cache root in tests/conftests.py.
There we used

audb.config.SHARED_CACHE = cache

instead of the correct

audb.config.SHARED_CACHE_ROOT = cache

@hagenw hagenw marked this pull request as ready for review May 13, 2024 11:37
@hagenw hagenw requested a review from ChristianGeng May 13, 2024 11:37
Copy link
Member

@ChristianGeng ChristianGeng left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This MR adapts the audbcards package to use more recent audbackend releases.
In addition it fixes an issue with cache handling in the tests.

Tests are all green. I have some problems that are starting to arise with newer pathlib / Python versions.

As we cannot solve this issue, I will approve. I have pasted the error log below, just to keep it in mind.

ImportError while loading conftest '/home/cgeng@audeering.local/work/tools-public/audbcards/tests/conftest.py'.
tests/conftest.py:8: in <module>
    import audb
../../.envs/audbcards/lib/python3.12/site-packages/audb/__init__.py:1: in <module>
    from audb import info
../../.envs/audbcards/lib/python3.12/site-packages/audb/info/__init__.py:1: in <module>
    from audb.core.info import attachments
../../.envs/audbcards/lib/python3.12/site-packages/audb/core/info.py:8: in <module>
    from audb.core.api import dependencies
../../.envs/audbcards/lib/python3.12/site-packages/audb/core/api.py:7: in <module>
    import audbackend
../../.envs/audbcards/lib/python3.12/site-packages/audbackend/__init__.py:1: in <module>
    from audbackend import backend
../../.envs/audbcards/lib/python3.12/site-packages/audbackend/backend/__init__.py:6: in <module>
    from audbackend.core.backend.artifactory import Artifactory
../../.envs/audbcards/lib/python3.12/site-packages/audbackend/core/backend/artifactory.py:4: in <module>
    import artifactory
../../.envs/audbcards/lib/python3.12/site-packages/artifactory.py:425: in <module>
    class _ArtifactoryFlavour(pathlib._Flavour):
E   AttributeError: module 'pathlib' has no attribute '_Flavour'
make: *** [Makefile:54: test] Error 4

@hagenw
Copy link
Member Author

hagenw commented May 15, 2024

The error you see is not directly related to Pathlib, but to this issue in the artifactory package: devopshq/artifactory#430.

That's also the reason why we cannot officially support Python 3.12 in audbackend, audb, here, and in a few other packages.

@hagenw hagenw merged commit 44d10a6 into main May 15, 2024
7 checks passed
@hagenw hagenw deleted the audbackend-2.0.0 branch May 15, 2024 07:22
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants