Snapd circular dependencies

Boris Rybalkin ribalkin at gmail.com
Fri Dec 9 18:32:00 UTC 2016


Hi,

I am learning snapd code and have found some rather strange place of the
code:

snapstate.go:

var Configure = func(st *state.State, snapName string, patch
map[string]interface{}) *state.TaskSet {
panic("internal error: snapstate.Configure is unset")
}

I tried to understand why would anyone do not want to call directly
Configure function and the only reason I have found so far is 'circular
dependency'.

So I have refactored the code a little bit to remove it and the pull
request is here:

https://github.com/snapcore/snapd/pull/2443

Would you guys consider merging it?
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.ubuntu.com/archives/snapcraft/attachments/20161209/c9fb5067/attachment.html>


More information about the Snapcraft mailing list