Skip to content

cURL and StringIO objects in the Opencast adapter are not closed properly #562

@sinhote

Description

@sinhote

This has been around for a while and it bothers me everytime I have to browse through the code: both StringIO and cURL objects used in the Opencast client need to be properly closed, but they are handled in an "unsafe" way (if an error occurs, neither the cURL nor the StringIO object are properly closed).

I know for a fact that older versions of Galicaster would get slower and slower (until they simply malfunctioned) when the active parameter in the [ingest] section was set to true with an incorrect or unreachable URL. I do not know if leaving these objects open when the connection fails does have any noticeable consequences in the stability of Galicaster, but it is bad programming style in any case.

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions