Currently the operator allows to set requirement as list that needs to be hard coded.
It would be nice if airflow can support reading from file directly (something similar to how operators read sql file)
airflow/operators/python.py
self,
        *,
        python_callable: Callable,
        op_args: Optional[Collection[Any]] = None,
        op_kwargs: Optional[Mapping[str, Any]] = None,
        templates_dict: Optional[Dict[str, Any]] = None,
        templates_exts: Optional[Sequence[str]] = None,
        show_return_value_in_logs: bool = True,
        **kwargs,
    ) -> None:
        if kwargs.get("provide_context"):
            warnings.warn(
                "provide_context is deprecated as of 2.0 and is no longer required",
                DeprecationWarning,
                stacklevel=2,
            )
            kwargs.pop('provide_context', None)
        super().__init__(**kwargs)
        if not callable(python_callable):
            raise AirflowException('`python_callable` param must be callable')
        self.python_callable = python_callable
        self.op_args = op_args or ()
        self.op_kwargs = op_kwargs or {}
        self.templates_dict = templates_dict
        if templates_exts:
            self.template_ext = templates_exts
        self.show_return_value_in_logs = show_return_value_in_logs
    def execute(self, context: Context) -> Any: