Skip to main content

Dagsesh: Airflow DAG Session Manager

Overview

An Apache Airflow session context manager that overrides the default AIRFLOW_HOME path with a random, ephemeral alternate.

Why is this useful? As per the Airflow configuration docs:

The first time you run Airflow, it will create a file called airflow.cfg in your $AIRFLOW_HOME directory (~/airflow by default).

Dagsesh delays the creation of AIRFLOW_HOME using a lazy-loading facility whilst injecting it with a random alternate. Great if you want to create a pristine Airflow environment for repeatable testing.

Dagsesh can be used as a convenient pytest plugin to prime an Airflow environment for testing.

top

Prerequisites

top

Getting Started

Makester is used as the Integrated Developer Platform.

(macOS Users) Upgrading GNU Make

Follow these notes to get GNU make.

Creating the Local Environment

Get the code and change into the top level git project directory:

git clone git@github.com:loum/dagsesh.git && cd dagsesh

NOTE: Run all commands from the top-level directory of the git repository.

For first-time setup, get the Makester project:

git submodule update --init

Initialise the environment:

make init-dev

Local Environment Maintenance

Keep Makester project up-to-date with:

git submodule update --remote --merge

top

Help

There should be a make target to get most things done. Check the help for more information:

make help

top

Running the Test Harness

We use pytest. To run the tests:

make tests

top

Using dagsesh Plugin in your Project's Test Suite

Add the dagsesh package as a dependency to your project's development environment so that the plugin is installed and visible in your PYTHONPATH. dagsesh takes care of the distribution's entry point so that pytest automatically finds the plugin module. Nothing else needs to be done.

NOTE: See Making your plugin installable by others for more information.


top

Release files for dagsesh 0.1.1

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for dagsesh 0.1.1
File Size Uploaded
dagsesh-0.1.1.tar.gz 9.2 kB Details

Built distribution (wheel)

Table of built distributions (wheels) for dagsesh 0.1.1
File Interpreter ABI Platform
dagsesh-0.1.1-py3-none-any.whl Python 3 none any Details

Total release size: 17.0 kB

Release files / dagsesh-0.1.1.tar.gz

Download URL dagsesh-0.1.1.tar.gz
Size 9.2 kB
Tags Source
SHA-256 checksum
How to use checksums
da7a13f1f63dc0af956a0fc2ca078217a7e77516b693ab8cc2c1121d6ed550a3
BLAKE2b-256 checksum
How to use checksums
768a025d0fdc0ac0fb8bd79072566f0f29c7e4c5b72c6baf447448565fbd1a11
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/6.2.0 CPython/3.12.3

Release files / dagsesh-0.1.1-py3-none-any.whl

Download URL dagsesh-0.1.1-py3-none-any.whl
Size 7.7 kB
Tags Python 3
SHA-256 checksum
How to use checksums
b184b500d1d69f991f061ac25d2c42100ebe047761c9738923371f47d3da1263
BLAKE2b-256 checksum
How to use checksums
33afe57a6e352a7ce6a1288cb7c3bb59fbfb53cb94a411c28cfb462834f3d757
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/6.2.0 CPython/3.12.3

Release history Release notifications | RSS feed

This release

0.1.1 This release

2 release files

0.1.0

2 release files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page