[05:13] morning [05:57] 'morning! [06:06] mardy: hey [06:15] morning [06:35] pstolowski: hey === zyga_ is now known as zyga [07:11] good morning :) [07:11] * zyga braces for 34C today [07:11] ufff [07:12] hey zyga [07:49] * pstolowski physio [08:24] pedronis: on the mount interface: I guess that when removing a snap, we should unmount all the mounts created by the snap, right? Or is it the snap's responsibility to do so? [08:24] mardy: no, we should do that === zyga_ is now known as zyga [08:26] mardy, perdronis: would a snap disable also unmount those? [08:26] it's a tricky question, because it carries into what happens when the snap refreshes, would those mounts go away ? [08:28] pedronis: OK. Any hints on where in the code we should do it? [08:28] zyga: I would expect that disable would simply disable the mount unit, without doing the unmount [08:29] given the use case I suspect that we would do something heavy ended only on remove [08:29] for the rest it would be up the snap to do things from the hooks [08:30] *handed [08:36] mardy: that's interesting but also not what snapd does historically [08:36] pedronis: yeah, I think this is more practical [08:52] re [08:54] I still don't know where I should hook into the removal process to do the unmount... I see that Repository.DisconnectSnap() calls disconnect(), which just calls delete(). [08:55] mardy: so about that [08:56] mardy: is mount-control going to use a new interface backend? [08:56] mardy: or is it going to define something entirely new? [08:56] mardy: historically all of the interface woo woo was going on in interfaces/*.Backend type [08:57] mardy: like the mount backend writing our special .fstab files and calling snap-update-ns [08:57] mardy: what is your plan for the mount control interface? [09:02] zyga: nope, it's just a new interface, using the existing backends [09:02] let me push what I have so far [09:03] mardy: hmm [09:03] mardy: but none of the existing backends can create system-level mount units, unless you count the systemd interface which is only used by gpio [09:04] zyga: https://github.com/snapcore/snapd/pull/10473 [09:04] zyga: the mounts are not created by the interface itself, but by a new snapctl subcommand [09:05] mardy, looking [09:06] mardy, what's the mount::%s thing? [09:08] zyga: in parseStringList(), the %s can be either "options" or "type" (if I understood your question :-)) [09:10] pstolowski: I re-reviewed https://github.com/snapcore/snapd/pull/10515 thanks for the work there [09:10] mardy, I meant the double colon [09:11] zyga: ah, I guess it's a sign I've been writing C++ for too long :-) [09:11] ah, haha [09:11] no worries, I was just curious [09:11] pedronis: ty! [09:14] zyga: so, the interface itself does very little: it verifies the attributes (which show what are the allowed mount options) and sets up the apparmor snippet, so that the snap could call mount itself as long as it matches the declared attributes [09:14] yeah, I see [09:14] hold on, let me read the rest [09:15] zyga: then we have a snapctl mount command, which can do the mount, and if --persistent is given, sets up a mount unit [09:18] pedronis: i've updated https://github.com/snapcore/snapd/pull/10510 the tests inflate the diffstat a bit [09:18] i should probably come up with more tests for the error path [09:20] mardy, yeah, so it's not like a typical interface for sure [09:20] I left two random comments towards the bottom [09:20] mardy, and your question on lifecycle stands [09:23] zyga: thanks! [09:24] so, interfaces don't have a method which gets called when plugs and sockets get disconnected? [09:30] mborzecki: thx, it's in my queue, I'll see when I can look at it, lots of meetings today [09:30] pedronis: that's ok, thanks! [09:48] mardy, they do [09:48] mardy, it's just not that direct [09:48] mardy, what gets called is backend methods [09:48] mardy, what you connect impacts a backend specification [09:48] mardy, and in the end backend spec is used to tell the backend what to do [09:49] mardy, the final call is backend.Setup and Remove calls [09:49] mardy, everything in the middle just feeds the system [09:54] mardy, since snapctl doesn't really change the interface system, it doesn't seem that you can rely on this mechanism here for mount-control [09:54] mardy, but I may have missed something [09:58] zyga: what about the "auto-disconnect" event? Could I add a handler for it, which does the unmount? (assuming that you can have more than one handler) [09:58] mardy, auto-disconnect is when the interface is disconnected due to snap removal _I think_ [09:58] I mean [09:58] don't get me wrong [09:58] you _can_ hook to something [09:58] in the snap remove flow for sure [09:59] my point was that it's not for free by changing the mount backend [10:15] mardy: you are going through wrappers to create the mount units? we can probably add somethign there to deal with this. Anyway because how mount units are named, we probably need to add markers anyway. We have to do that for some other kinds of files like for dbus [10:16] pedronis, oh that's a good point [10:16] there's no way to auto-detect snap mount units [10:16] because their name is decided and cannot contain a specific marker [10:17] yes, we have a similar problem with dbus activation files [10:19] mardy: you might want to look at wrappers/dbus.go , especially RemoveSnapDBusActivationFiles for some inspiration [10:19] that one is called much more often, but we can have a similar helper called more precisely/rarely [10:26] should "snap logout" not force me to use sudo for snap install/remove ? https://forum.snapcraft.io/t/sudo-less-snap-commands/25441 [10:36] ogra, I _guess_ so [11:26] pedronis: can you land https://github.com/snapcore/snapd/pull/10511 ? unrelated failures, including deltas [11:34] pstolowski: done [11:37] thanks [12:19] <_moep_> Hello! how is it possible to install via snap a package and deploy the content from .config/ to /snap/bla/current/.config/? When I don't start the snap, /snap/…/.config doesn't exist. Do you have any suggestions? [12:30] pedronis: the method to create mount units is in systemd/systemd.go; do you think I should create a wrapper for it under wrappers/ instead (maybe wrappers/services.go)? Or is it fine to use it from where it is? [12:33] mardy: as I said we probably need to extra markers, I think it probably needs to be in wrappers calling something in systemd for symmetry [12:40] _moep_, no, because all the content in /snap/bla/$number is not a bunch of files you can modify but an entire file system that was mounted [12:49] _moep_: if you need something from .config that is specific to your app , you can ask a personal-file access for it and add code to one of the installation hooks to copy it when the snap gets installed [13:28] <_moep_> pedronis: thx and how can I do this? [13:40] _moep_, you add a personal-files interface entry to your snapcraft.yaml, upload to the store (this goes into manual review) and file a forum post in the "store-requests" category at forum.snapcraft.io ... take a look at exsiting requests in there [13:43] <_moep_> ok thx [13:45] pedronis: it looks like there is a marker already: https://github.com/snapcore/snapd/blob/master/systemd/systemd.go#L1052 [13:55] damn it's hot [14:02] mardy: well we probably need to change those description for this new units, that description is meant to indicate the mount of the snap itself [14:02] *these [14:32] mborzecki: I made a pass on https://github.com/snapcore/snapd/pull/10510 [14:33] pedronis: thanks, yeah had a bit of hard time picking the right name for post finish, nothing fit reasonably well [14:55] pedronis: tried to answer the question about recovery system and errors there, perhaps we need to make sure that GoundDeviceContext() is always the one with the old model, which I think will not be the case now once set device runs [14:56] although the state won't be updated until unlock, so it should be ok if we reboot before that point, and the contexts will be correct [14:57] mborzecki: sorry, I don't understand your comment [14:58] pedronis: quick chat? [14:58] mborzecki: I don't think my question is about recover in that sense. I mean about the recovery system recover [14:58] mborzecki: I have meetings [14:58] mborzecki: I mean, what happens if reboot and and do a system action recover [14:59] pedronis: as in by running `snap recover`? or picking a recovery system from boot list? [14:59] picking from the boot list [15:00] but either really [15:00] the rules are the same afair [15:00] I'm not too picky if we have an error, which system we can recover with, as long as there is one. My worry is that neither works [15:01] perhaps [15:01] does the question make sense? [15:01] I think the test should check something about this [15:01] *tests [15:01] pedronis: afaiu one of them works, depending on the state the reboot happens [15:01] mborzecki: that's fine, would be good to check [15:02] pedronis: if the reboot happens after we swap the models, just the new one works, if it happens before but after try model is set, then it's either of the systems, if even before that, then just the old system [15:03] mborzecki: can we add checks in tests about this? [15:03] pedronis: you mean a spread test? [15:03] mborzecki: whatever makes sense [15:04] I'm fine to check in the integrationy unit tests if it's trustable enough [15:04] the unit tests already verify which model is present in modeenv and which model is on the disk [15:04] pedronis: a spread test, i.e. trying to boot the system, is the only way to make sure it works [15:07] mborzecki: my question is because of how currentSeededSystem is defined, I think there is something off [15:08] pedronis: we've only had one until now, so it's likely picking the first one is not quite what we want there [15:08] mborzecki: we should probably discuss tomorrow, I'm a bit confused about this [15:09] pedronis: ok, let me schedule something in the morning [15:12] pedronis: added soemthig before desktop sync, let me know if we should try another time slot [15:13] mborzecki, ijohnson[m] pr #10409 is fixed, when you have a time could you please take a look? [15:23] mborzecki: sounds fine [16:04] cachio: sure, I'll take a look, also you mentioned some test was still failing somewhere and that I should take another look ? [16:04] what test was that? [16:05] ijohnson[m], not on this pr [16:05] there are some random errors related to timeouts trying to connect to uc20 instances [16:05] I couldn't reproduce it yet [16:06] but I saw that in some github action logs [16:06] cachio: is that what was discussed about using the wrong machine type with GCE that might be fixed with one of your pr's to spread ? [16:11] ijohnson[m], there are 2 errors [16:12] that one [16:12] and something new [16:12] I saw some connections timeout [16:12] on uc20 [16:12] and the logs I reviewed didnt show errors [16:15] ijohnson[m], I also see this error https://github.com/snapcore/snapd/pull/10409/checks?check_run_id=3068339849#step:5:184 [16:17] hmm that last one you sent is new, I haven't seen that before, it seems like the machine just got stuck and froze [16:19] ijohnson[m]: is a squash merge of 10522 okay? for easier cherry-picking? [16:19] let me look [16:19] mvo: yeah that's fine [16:19] mvo: did we decide if we need security review on this ? [16:19] ijohnson[m], https://github.com/snapcore/snapd/pull/10409/checks?check_run_id=3068339849#step:5:1756 [16:20] this test also failed [16:20] ijohnson[m]: let me quickly look at it [16:20] huh that's interesting [16:20] it is where we are installing 2.45 [16:21] perhaps it is rebooting [16:21] for refresh [16:22] ijohnson[m], I'll try to reproduce it locally [16:28] ijohnson[m]: looks good, added one question [16:29] mvo: do you want me to fix that typo in the PR before squash merging ? [16:30] ijohnson[m]: would be nice, but not super important. if you do it, make sure to add skip-spread to avoid a full run [16:30] mvo: ah well too late I already pushed it [16:30] also does skip-spread work if we already opened the PR without skip-spread ? [16:30] I thought skip-spread is like run-nested in that it has to be closed and re-opened [16:30] ijohnson[m]: I think so but only before you push [16:31] ijohnson[m]: but maybe I'm wrong, I'm a bit out of touch [16:31] hmm interesting, I'll have to give it a try sometime [16:31] mvo: do you want me to cancel the run and add the label and re-try ? [16:32] ijohnson[m]: it's fine [16:32] ijohnson[m]: we are not in a rush I think(?) [16:32] ijohnson[m]: do we have a deadline for the interface? [16:32] ijohnson[m]: (again, sorry for not being on top of this :/) [16:34] mvo yeah I think TPE needs it rather urgently unfortunately [16:34] So sooner it's in beta the better [16:34] Not sure if you were planning to start a release today or not [16:35] mvo see MM [16:36] ta [16:43] ijohnson[m], https://paste.ubuntu.com/p/YmMbJ2t4fZ/ [16:43] there is an auto-refresh on the vm [16:50] cachio: ah interesting [16:50] Is it ok to force refresh.hold in this scenario? [16:50] cachio: yeah probably [16:50] ok, I0'll try that [17:38] ijohnson[m], so [17:38] still fails [17:38] auto-refresh is happening [17:39] perhaps the way is to update default config for pc gadget [18:04] cachio: ah yeah that makes sense, do you remember how to do that? [18:04] there are other nested tests which modify gadgets too [18:07] yes, I'll try to reuse that [18:09] ijohnson[m], I am not sure if it is gonna work [18:09] but I am gonna try [18:10] because the core is 2.45 and the pc gadget is the current [18:10] but it the images builds ok now it means it should work [18:10] hmm [18:11] cachio: could you instead unpack and repack the core snap before building the image such that it doesn't have the same hash and thus won't be refreshable since it will be installed dangerously? [18:12] sure [18:12] that is easied [18:12] easier [18:33] ijohnson[m], pushed the fix [18:33] tested and tests are passing [18:40] <_moep_> what is a good default value for refreshing snaps? (at a stable branch and no bleading edge) [20:26] cachio: ack I'll take a look in a little bit, prepping 2.51.3 right now [20:26] _moep_: what do you mean? default value of what ? [20:35] ijohnson[m], which changes are included in .3? [20:35] is it a bug fix? [20:36] cachio: just a change for http response header timeouts from pawel and the sd-control interface which TPE needs very urgently [20:36] it's a very small release [20:36] ijohnson[m], ok [20:37] I'll make sure the validation is done overnight [20:37] cachio: it's probably fine for you to start tomorrow, no need to rush to get it started tonight [20:37] cachio: I can only assume that the core snap is going to get stuck in review because it always does [20:38] but maybe the snapd snap should be ready earlier [20:38] ijohnson[m], sure [20:38] thanks cachio I'll ping you when the snaps are in the beta channel [20:39] ijohnson[m], nice, thanks [21:33] cachio: approved #10409, some followup material but otherwise lgtm [21:33] nice, thanks [22:31] cachio: snapd snap 2.51.3 is now in beta [23:25] ijohnson[m], nice, tests are starting now [23:27] Great thanks