open-webui / pipelines

Pipelines: Versatile, UI-Agnostic OpenAI-Compatible Plugin Framework
MIT License
997 stars 316 forks source link

Add module to sys.modules after loading for use with @dataclass #289

Open mevatron opened 1 month ago

mevatron commented 1 month ago

I ran into an issue with trying to use @dataclass within a pipeline resulted in an exception with the following:

AttributeError: 'NoneType' object has no attribute '__dict__'.

This PR seems to fix it on my fork!