Skip to content

is_valid_plugin can no longer be used for unit testing plugins #14285

@soggycactus

Description

@soggycactus

I can no longer use airflow.plugins_manager.is_valid_plugin to write a simple unit test that ensures I can't merge broken plugins to master.

This is because the function no longer accepts a list of plugins that represents existing plugins, and instead references a global variable inside the package (I would really love an explanation as to how this is better).

The global variable plugins is defined as None, and when calling the function locally, it will always fail because a None object is not iterable.

Either this function needs to be fixed or Airflow needs to provide another interface for validating plugins. I was really disappointed to see this as I spent this week researching how to upgrade our Airflow to 2.0, only to find that a lot of the utilities I've built around Airflow have been rendered useless. I'm sticking with 1.10.14 for now

Metadata

Metadata

Assignees

No one assigned

    Labels

    kind:bugThis is a clearly a bug

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions