Skip to content

Commit

Permalink
Merge pull request #588 from garden-io/fix-watch-mode-module-version
Browse files Browse the repository at this point in the history
fix: ensure module is up to date in watch handler
  • Loading branch information
eysi09 authored Mar 4, 2019
2 parents e46de97 + 44e8871 commit fac9473
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion garden-service/src/process.ts
Original file line number Diff line number Diff line change
Expand Up @@ -161,7 +161,11 @@ export async function processModules(
// Update the config graph
graph = await garden.getConfigGraph()

await Bluebird.map(changeHandler!(graph, changedModule), (task) => garden.addTask(task))
// Make sure the module's version is up to date.
const refreshedModule = await graph.getModule(changedModule.name)
modulesByName[event.name] = refreshedModule

await Bluebird.map(changeHandler!(graph, refreshedModule), (task) => garden.addTask(task))
await garden.processTasks()
})
})
Expand Down

0 comments on commit fac9473

Please sign in to comment.