The async Task.start pattern was causing DBConnection.Ownership errors when tests finished before the spawned Task could complete its database update. By making the update synchronous in test environment, we ensure the database connection is properly managed within the test process. In production, we still use the async Task.start to avoid blocking requests when updating last_used_at timestamps. Fixes all "owner #PID<...> exited" errors in test suite. |
||
|---|---|---|
| .. | ||
| mix/tasks | ||
| towerops | ||
| towerops_web | ||
| towerops.ex | ||
| towerops_web.ex | ||