When using the onion architecture, you need to consider the dependencies (actions depend on calculations), but also you need to consider the semantic dependencies (the domain should not know about the database).
See All 242 Episodes of "Thoughts on Functional Programming Podcast by Eric Normand"