Talks

Dependency Injection in Python with Pydantic and Hydra

Sunday, May 18th, 2025 1:45 p.m.–2:15 p.m. in Hall C

Presented by

Pascal Tomecek

Experience Level:

Some experience

Description

Abstract

Dependency Injection (DI) is a technique that allows for the flexible construction of nested object hierarchies through configuration, with the goal of reducing coupling between objects and enabling more run-time flexibility in applications.

This talk aims to illustrate how the popular open source packages Pydantic and Hydra can be combined (with a little extra work) to provide a powerful dependency injection framework for python. This session will provide an introduction to these tools, illustrate their integration, and highlight their benefits in managing configurations and dependencies. Attendees will gain insights into building flexible and extensible Python applications by leveraging the ability to register and reuse Pydantic models from Hydra based configurations.

Target Audience

This talk is designed for Python developers, software engineers, and architects interested in improving their application architecture through dependency injection. Attendees should have a basic understanding of Python and software design principles.

Prerequisites

No prior experience with Pydantic or Hydra is required.

Search