audeering / audbackend

Manage file storage on different backends
https://audeering.github.io/audbackend/
Other
3 stars 0 forks source link

Add backend method open() and close() #199

Closed hagenw closed 5 months ago

hagenw commented 6 months ago

Copied from https://github.com/audeering/audbackend/issues/197#issuecomment-2017517185

[...] it is very common to open and close connections to a storage drive. So maybe we should actually introduce both functions, e.g.:

backend = audbackend.backend.MyBackend(host, repo)
backend.open()
# do something with the backend
backend.close()

or alternatively:

with audbackend.backend.MyBackend(host, repo) as backend:
     # do something with the backend
hagenw commented 6 months ago

@frankenjoe I will continue working on #197, so I assign this to you (see also https://github.com/audeering/audbackend/pull/200#issuecomment-2024981522)

hagenw commented 5 months ago

Solved by #204