/srv/irclogs.ubuntu.com/2019/08/19/#snappy.txt

mupPR snapd#7272 opened: [PATCH] interfaces/bluez: enable communication between bluetoothd and meshd via dbus <Created by jrigling> <https://github.com/snapcore/snapd/pull/7272>01:18
mborzeckimorning04:56
mborzeckibrb, new kernel05:22
mborzeckire05:23
zygaHejka06:11
mborzeckizyga: hey hey06:18
mborzeckimvo: hey06:42
mvohey mborzecki06:43
mborzeckimvo: anything intersting happened on thu/fri last week?06:43
mborzeckimvo: https://github.com/snapcore/snapd/pull/7257 failed on 14.0406:44
mupPR #7257: packaging: fix symlink for snapd.session-agent.socket <Created by mvo5> <https://github.com/snapcore/snapd/pull/7257>06:45
pedronismvo: hi, did you see my fix for the FindU/Gid spread problem, it was a silly issue06:46
mvopedronis: aha, thanks! I noticed it failing but then had to leave and was a bit puzzled, thanks for sorting it out06:52
mvopedronis: oh fun! now I see the fix, silly indeed06:53
mvopedronis: thanks :)06:54
mvomborzecki: I run it in spread with -debug now06:56
zygare06:58
* zyga looks after PRs from last week06:58
zygathank you for iterating on https://github.com/snapcore/snapd/pull/7254 everyone!07:01
mupPR #7254: cmd/snap-update-ns: fix pair of bugs affecting refresh of snap with layouts <Created by zyga> <Merged by mvo5> <https://github.com/snapcore/snapd/pull/7254>07:01
=== pstolowski|afk is now known as pstolowski
pstolowskimorning07:15
zygahey  :)07:15
mvohey zyga and pstolowski !07:16
mborzeckipstolowski: hey07:17
mborzeckimvo: can you cherry-pick e864cd99affea16b8742a9f3b5257dfb5f65065f to 2.40? it's blocking https://github.com/snapcore/snapd/pull/726407:19
mupPR #7264: packaging/fedora: build on RHEL8 (2.40) <Simple 😃> <Created by bboozzoo> <https://github.com/snapcore/snapd/pull/7264>07:19
mvomborzecki: sure07:21
mvomborzecki: done07:22
mborzeckimvo: thank you07:22
pedronismvo: I merged master into #7124 and gave my +1, but I have a question there, that maybe you can answer too07:22
mupPR #7124: many: create system-usernames user/group if both don't exist <Created by jdstrand> <https://github.com/snapcore/snapd/pull/7124>07:22
mvopedronis: looking now07:23
mupPR snapd#7263 closed: snap: cleanup some tests, clarify some errors <Simple 😃> <Created by pedronis> <Merged by pedronis> <https://github.com/snapcore/snapd/pull/7263>07:31
mvopedronis: I will work on your question about 7124 and push a fix (I think we need one but I double check now)07:32
pedronisthx07:33
pstolowskizyga: can you finish the review of #7081? would be great to land it07:33
mupPR #7081: ifacestate: optimize auto-connect by setting profiles once after all connects <Needs Samuele review> <Created by stolowski> <https://github.com/snapcore/snapd/pull/7081>07:33
zygapstolowski: sure, on it07:33
pstolowskithanks!07:35
mvopedronis: I think we also need to delete the group, i'm checking now07:51
mvopedronis: aha, no, nevermind07:53
mupPR snapd#7267 closed: many: simpler access to snap-seccomp version-info <Created by pedronis> <Merged by pedronis> <https://github.com/snapcore/snapd/pull/7267>08:26
=== mborzeck1 is now known as mborzecki
mborzeckithis is new: 2019-08-19 07:56:22 Cannot allocate google:ubuntu-18.10-64: cannot allocate new Google server for ubuntu-18.10-64: the resource 'projects/ubuntu-os-cloud/global/images/family/ubuntu-1810' was not found08:55
mborzeckiimages are gone or what?08:56
Chipaca1804 just worked for me fwiw08:58
Chipacabah, 09:38:37, 20 minutes ago08:58
jamesh18.10 reached end of life at the end of July08:58
jameshmaybe the official images got pulled to encourage upgrades?08:59
mborzeckiduh08:59
mborzeckithought we copy those images to our project :/08:59
Chipacamborzecki: but we don't have 18.10 in google in our spread.yaml09:00
mborzeckiChipaca: that's a job for 2.40 branch09:00
Chipacaah09:00
mborzeckihm an update neded then? :)09:00
jameshIt's going to be interesting to see what GitHub Actions does to the CI service landscape in the next year09:01
Chipacamborzecki: pull #7127 into 2.4009:01
mupPR #7127: tests: removing support for ubuntu cosmic on spread test suite <Created by sergiocazzolato> <Merged by mvo5> <https://github.com/snapcore/snapd/pull/7127>09:01
Chipacamborzecki: that's f2fa5ce91609d31b8263c92f5f46488d2eedd1f3 if it makes it any easier :)09:02
mborzeckimvo: can you cherry-pick f2fa5ce91609d31b8263c92f5f46488d2eedd1f3 ?09:02
Chipacahehe09:02
mborzeckiChipaca: thanks!09:02
zygamvo: did you see that snapd-master cannot be uploaded?09:23
pstolowskizyga: happy birthday! 🍺 🎁09:24
zygapstolowski: thank you :)09:24
zygamore gray hair to grow I guess :D09:24
pstolowski:)09:25
mvomborzecki: sure, done09:25
mborzeckimvo: thank you09:25
mvozyga: yes, the socket symlink fix will fix this09:25
mvozyga: onces spread is green I think we can merge it09:26
mvozyga: oh? I had no idea - HAPPY BIRTHDAY :-D09:26
zygathank you everyone09:26
mborzeckizyga: 37?09:28
zygayep09:28
pstolowskioh boy, you're young09:29
mborzeckizyga: happy almost-40 :)09:29
zygapstolowski: are you older?09:29
pstolowskizyga: 4209:30
zygapstolowski: you look like 3009:30
pstolowski:D09:43
mborzeckipedronis: hi, the renames we talked about https://github.com/snapcore/snapd/pull/727309:45
mupPR snapd#7273 opened: gadget, overlord/devicestate: rename Position/Layout <Gadget update> <Created by bboozzoo> <https://github.com/snapcore/snapd/pull/7273>09:45
mupPR #7273: gadget, overlord/devicestate: rename Position/Layout <Gadget update> <Created by bboozzoo> <https://github.com/snapcore/snapd/pull/7273>09:45
pedronismborzecki: thx, will look09:47
zygamvo: I found a simpler way to solve the lxd problem https://github.com/snapcore/snapd/pull/727410:03
mupPR snapd#7274 opened: tests: change cgroups so that LXD doesn't have to <Created by zyga> <https://github.com/snapcore/snapd/pull/7274>10:03
mupPR #7274: tests: change cgroups so that LXD doesn't have to <Created by zyga> <https://github.com/snapcore/snapd/pull/7274>10:03
mborzeckidoes the store support searching for snaps by free/non-free license?10:04
mvozyga: nice! good job10:04
Chipacamvo: silly question: where is grub-editenv supposed to be in a core18 system?10:05
mvoChipaca: we may not have it there, we don't need it for snapd, it handles all of this via the internal grubenv code10:06
mvoChipaca: do you need it for tests?10:06
Chipacaahh10:06
Chipacamvo: maybe not10:06
Chipacamaybe i was just being lazy :)10:06
mvoheh, ok10:07
zygapstolowski: I'm still going through10:15
zyganeed a coffee, brb10:15
Chipacahow did one stop initramfs before it pivoted into the real thing?10:57
Chipacasomething-bottom10:57
zygaChipaca: break=bottom or break=top10:57
zygaChipaca: in the kernel command line10:57
Chipacathanks10:57
Chipacamy core18 is coming up mounted weird :)10:57
* Chipaca debugs10:57
mborzeckiChipaca: weird how?10:58
Chipacamborzecki: it's something i broke with my boot changes10:58
Chipacaweird as in not mounted? :)10:59
Chipacabut, mounted10:59
Chipacano home10:59
mborzeckiheisenmount10:59
pedronisare we setting snap_core  wrong ?10:59
Chipacathese are the questions i'm asking myself :)11:00
Chipacathere's some weird dependency that i'm not seeing, so i'm going to go back to plan C and redo this bit by bit11:11
Chipacabut first, a wild lunch appears!11:12
* Chipaca is in the tall grass11:12
mvopedronis: I added some comments to 7124, I think we want some more tests for check_snap.go otherwise just nitpicks. probably fine in a followup. I also broke the spread test - it looks like on arch groupdel is not actually working :/ at least that is what the error indicates11:18
mborzeckimvo: do you have more details about the problem on arch?11:24
mvomborzecki: working on getting details, maybe just some different default11:24
mvomborzecki: USERGROUPS_ENAB seems to be false on e.g. tumbleweed (zyga can you confirm) ? this is set in login.defs11:25
mborzeckimvo: 196:USERGROUPS_ENAB yes11:27
mvomborzecki: ok, I look further11:27
mborzeckimvo: which spread test is that?11:27
zygamvo: checking11:30
zygamvo: USERGROUPS_ENAB is not an option listed in /proc/config.gz11:30
zygaperhaps the configuration has changed and is no longer there?11:30
mvomborzecki: it was in 7124 but I think I made it robust enough now11:31
zygathis is on 5.2.511:31
mborzeckizyga: it's in /etc/login.defs11:31
mvozyga: login.defs11:31
zygaah, sorry11:32
zygait's indeed set to "no"11:33
mvozyga: thanks! I updated the test11:42
mborzeckibtw. do user ids still start at 500 by default in opensuse?11:51
mborzeckizyga: ^^11:51
zygamborzecki: I don't think so11:56
zygamy id is 100011:56
mupPR snapd#7269 closed: tests: add test for services disabled during refresh hook <Created by anonymouse64> <Merged by mvo5> <https://github.com/snapcore/snapd/pull/7269>11:56
zygamborzecki: UID_MIN is 1000 on TW11:57
mupPR snapd#7268 closed: tests: add /var/cache/snapd to the snapd state to prevent error on the store <Created by sergiocazzolato> <Merged by mvo5> <https://github.com/snapcore/snapd/pull/7268>11:57
mupPR snapd#7236 closed: packaging/ubuntu-16.04: provide a way to reset snapd without purging <Created by mwhudson> <Closed by mvo5> <https://github.com/snapcore/snapd/pull/7236>11:59
mborzeckimvo: shall we land https://github.com/snapcore/snapd/pull/7109 ?12:07
mupPR #7109: [RFC] snap-confine: fallback gracefully on a cgroup v2 only system <Created by mvo5> <https://github.com/snapcore/snapd/pull/7109>12:07
mvomborzecki: if it works well enough for fc31 then yes12:10
mvo(IMHO)12:10
mborzeckimvo: with this branch, the list of failing tests is here: https://forum.snapcraft.io/t/snapd-with-unified-cgroup-hierarchy/12528/212:13
=== ricab is now known as ricab|lunch
zygaChipaca: what is 408?12:40
zygahttps://www.irccloud.com/pastebin/2uUquJFw/12:40
Chipacazyga: request timeout12:47
Chipacazyga: https://httpstatusdogs.com/408-request-timeout12:48
Chipacaer12:48
Chipacazyga: https://httpstatusdogs.com/40812:48
Chipacazyga: note it's a _client_ error12:53
Chipacathese days using GPRS you'll hit a lot of 408s12:54
zyga2fa13:01
zygamborzecki: hmm, one test exploded on me on fedora13:22
zygahttps://www.irccloud.com/pastebin/Q9PySGal/13:22
zygait's pretty odd, seems like random corruption and failure13:22
zyga(it didn't fail on the same code before)13:22
zygasudo: unable to execute ./hightest: Permission denied13:22
zygamay be something I broke after all, please ignore me13:24
mborzeckizyga: iirc hightest only checks user id's in high values range13:24
jdstrandmvo: hey, thanks for the updates for 7124, shall I take over now (note, groupdel --force isn't available until newer releases, but I can fix that)13:34
ograjdstrand, https://paste.ubuntu.com/p/TpynTdQv8Z/ ... adding time-control (which is a bit funny given the app doesnt have anything to do with time) makes the environment error go away due to teh explicit denial you added there ... wouldnt it make more sense to put that and the /proc/1/sched denial into some generic place instead ?13:37
ograi assume we never want any snap app to read either anyway13:38
mvojdstrand: lets have a quick sync with samuele - in a meeting right now13:38
mvojdstrand: most of my comments are really just nitpicks13:38
jdstrandmvo: we need to fix the groupdel issue, so I'll fix that and small nits13:43
mvojdstrand: \o/ thank you13:44
jdstrandmvo: and wait for you for other stuff13:44
mvojdstrand: sorry, was not aware that --foce is not there :/13:44
=== ricab|lunch is now known as ricab
mborzeckizyga: isn't that a default umask or sth?13:49
zygaAFK for cooking13:54
mvojdstrand: ok, I just wait for your push and then we can do more stuff in a followup. I am happy to help if you want13:56
mvoijohnson: hey! 7214 is green and has two +1 - can I merge it ?14:08
* ijohnson looks14:08
ijohnsonmvo: I made the changes that jdstrand requested, but I'm not sure if we need jdstrand to re-approve the changes before merging14:09
jdstrandijohnson: I just now approved (for the security policy bits)14:19
ijohnsonthanks jdstrand, then mvo yes I think it's good to be merged14:21
mvota14:22
mupPR snapd#7214 closed: interfaces/network-setup-control: allow dbus netplan apply messages <Created by anonymouse64> <Merged by mvo5> <https://github.com/snapcore/snapd/pull/7214>14:24
ograzyga, i think i found a layouts bug :(14:34
ograzyga, a snap that ises a layout can be installed fine (and teh layout works as expected) ... but if i try to upgrade it i get https://paste.ubuntu.com/p/KnbskvpwQ7/14:36
ogra(and note that there is no /etc/libblockdev anywhere on the host, so the error is bogus)14:36
ogras/ises/uses/14:37
ogranote that snap remove/install works fine as well14:40
zygaogra: hey14:50
zygaogra: it was recently fixed, can you check edge14:50
ograi will ... good to know it is known then14:50
zygaogra: it was bug ....14:50
ograyeah14:50
zygahttps://bugs.launchpad.net/snapd/+bug/180882114:51
mupBug #1808821: snap with layout cannot be updated multiple times <snapd:Fix Committed by zyga> <https://launchpad.net/bugs/1808821>14:51
ograbtw, is there any possible way to layout something in /run ?14:51
zygaogra: no, not to /run AFAIR14:51
zygawe NACK that for security reasons14:51
ograi'm trying to package udisks2 and it tries to write to /run/mount/utab14:51
zygathere's an interface for that14:51
zygabut udisks and utab is a bit of a special case14:52
zygait's complex to get right, I think utab is a bit of a lost case :/14:52
ograwell, the snap uses the udisks interface14:52
ograyeah14:52
zygaI can explain later after lunch, bbl14:52
ograawe dropped the official udisks2 snap and i want to make at least a demo snap for people relying on auto-mounting on core ... so i'm trying my luck here :)14:53
ograit automounts fine already14:53
ograbut sadly it never cleans up /media/root but instead adds dir after dir if utab isnt accessible14:53
ogra(one new one for each plug of a disk)14:53
Chipacareturn fmt.Errorf("no not remove kernel assets: %s", err)15:00
Chipaca"no anything but that"15:00
mvoChipaca: heh15:00
mvoChipaca: where does this one comes from?15:00
Chipacamvo: that's in the old (current master) boot/kernel_os.go's RemoveKernelAssets15:01
pedronis#7135 is ready for reviews15:03
mupPR #7135: image: support prepare-image --classic for snapd snap only images <Created by pedronis> <https://github.com/snapcore/snapd/pull/7135>15:03
mvostgraber: hey, is there any in-cloud lxd images mirror? in our spread tests for snapd (that run in gce) I saw that pulling an image sometimes gets ~60kb/sec download speeds only15:05
jdstrandmvo: just finishing up some unit tests15:05
stgrabermvo: using ubuntu: as image remote? If so, we've been requesting it be served by more than a single machine in London for years...15:07
stgrabermvo: you could use images:ubuntu/bionic which is our community image server that unlike the main Ubuntu one does have multiple distributed servers backing it15:08
pedronisijohnson: I commented briefly on 727015:14
ijohnsonpedronis: but what about for the disable case? if we only save the info in the change and the change gets garbage collected we would lose that info when someone goes to enable a snap15:15
pedronisijohnson: ?15:15
ijohnsonsay someone disables a snap, we save the list of services in the change, they wait for xyz days and the change in state.json disappears15:16
ijohnsondon't changes in state.json disappear?15:16
pedronisijohnson: I'm missing something here15:16
pedroniswhat worries you?15:16
ijohnson(sorry responding to your comment on #7270, figured it would be quicker over IRC)15:16
mupPR #7270: [RFC] overlord: save disabled snap svcs on unlink snap tasks <Created by anonymouse64> <https://github.com/snapcore/snapd/pull/7270>15:16
ijohnsonI'm worried about saving the list of disabled services inside a chance since changes aren't persistent15:17
ijohnson... afaik15:17
pedronisijohnson: you are thinking of code that is not there yet15:17
pedronisin the code is all about the change, no?15:17
pedronisdo you have a case were we need to remember across changes?15:17
ijohnsonsnap install xyz, snap stop --disable xyz.svc; snap disable xyz; sleep 10000000000; snap enable xyz15:18
ijohnsonthe enable and disable of the entire snap are different changes, no?15:18
pedronisyes15:19
ijohnsonso in that case if we saved the disabled services in the change we would lose it when we disable the entire snap and re-enable the snap15:19
ijohnsonit would specifically not be available when we do the enable of the snap15:20
jdstrandmvo: ok, I made the adjustments where it was clear to me what was wanted. I didn't do the bit flags/options struct or invert error message15:22
pedronisijohnson: I see, problem is we don't do anything like that so far15:23
pedronisand there are two approaches to this15:23
jdstrandmvo: I think this is what you had in mind for testing 'passing as expected': https://github.com/snapcore/snapd/pull/7124/commits/047c7bc64062d0938f1d7b152c540170d7e2f71015:24
mupPR #7124: many: create system-usernames user/group if both don't exist <Created by jdstrand> <https://github.com/snapcore/snapd/pull/7124>15:24
pedronisijohnson: we could  remember the state as an "intention" when we actually get the enable/disable command15:24
pedronisignore what is really happening on disk15:24
pedronissorry I mean the enable/disable command for services (not for the snap)15:24
jdstrandmvo: please let me know what else you need15:25
jdstrandarg, a conflict15:25
* jdstrand fixes15:25
pedronisijohnson: that would be more similar to what we do in general15:25
pedronisit means tough we could stomp on the user doing things outside snapd15:26
pedroniswe don't really promise to always support that tough15:26
pedronisijohnson: 2nd approach, we can do what your code is doing, we need to think how to make clear that that state is different from all other state we keep tough15:26
pedroniswhich is the part that confused everybody15:26
pedronisbecause as I said we don't have state like that15:27
pedronisso far15:27
ijohnsonpedronis: hmm so in your first option would we really be "enabling"/"disabling" the service not in the systemd state, but rather inside snapd?15:27
ijohnsonso the systemd unit would always show up as "enabled", but if the user disabled it with --disable, then `snap run the-svc` would never really run the service?15:28
pedronisijohnson: isn't that true with your code as well?15:29
pedroniswe remember exactly what the user did15:29
jdstrandmvo: ok, resolved conflict and merged15:29
ijohnsonno that's different from how I was imagining it, in my case the state of the service is always in systemd, and just while the snap is inactive between revisions we save the disabled services15:30
ijohnsonthen on "link-snap", after generating the systemd services we go through that list and disable them and everything is normal15:30
ijohnsons/everything/everything else/15:30
pedronisijohnson: yes, I understand15:30
pedronisnot sure how it relates to your point tough15:30
ijohnsondo you think we need a meeting to discuss? I can explain my reasoning in a forum post if that would be helpful15:31
mvojdstrand: I love your commit message "don't use --force with groupdel since it is only documented, not implemented" :)15:32
pedronisijohnson: no I think I understand you what you are saying, nothing stop us to show that snapd state and reality have diverged15:32
pedronisthough15:32
zygare15:32
pedronisanyway I'm just trying to make clear that there isn't only one way15:32
zygasorry, kitchen emergency15:32
pedronisto attack this15:32
pedronishaving just one place with state is appealing15:33
ijohnsonhmm15:33
jdstrandmvo: I know right? I had to revert --force in one of my commits on this PR so I learned the hard way15:33
pedronisbut the current code in the PR is confusing15:33
ijohnsonwell from a user perspective I think this would be more confusing because now `snap run the-snap.the-svc` doesn't always actually run the snap15:34
pedronissnap run doesn't work for service like that15:34
pedronisanyway15:34
pedronisijohnson: I mean confusing code wise15:34
pedronis3 people have read and didn't get what was supposed to be going on15:35
ijohnsonI understand that the code proposal was probably not along the same lines of what has done before, I can clean it up, but in the back of my mind it keeps nagging at me that systemd and snapd are no longer in sync with state15:36
jdstrandmvo: so, on later releases, --force doesn't work, but -f does but on earlier releases neither are documented or implemented. anyhoo, no --force for us :)15:37
pedronisijohnson: as I said, right now I'm holding both possiblities as viable15:37
jdstrandmvo: it is surprising with how mature those utilities are, how there are still changes and bugs for simple stuff15:38
pedronisijohnson: the problem with the code is generally SnapState is an absolute truth or intention about the snap15:38
pedronisand the new field you added is neither15:38
ijohnsonwell in my mind, the new field is an absolute truth, but perhaps the name is wrong15:38
ijohnsonthe field is an absolute statement about the state of the services when the snap was unlinked, to be used when we re-link15:39
pedronisijohnson: that's the problem, as named you would think it's true also while that snap is active15:39
pedronisbut that's not true15:39
pedronisit's not even reset15:40
pedronisatm15:40
ijohnsonI have more changes in the link-snap that would reset it, but I hadn't decoupled that from the change that actually fixes the bug with this state15:40
ijohnsonI suppose I could add that change in link-snap to this PR and then rename it to be clear as to what state is being staved in SnapState15:41
pedronisso DisabledServicesAsLastActive might be a better name15:41
pedronisalso it likely belongs to SnapState15:41
pedronisand not the one of the SideInfos15:41
pedroniswe don't let mess much with a disable snap anyway15:42
ijohnsonyeah I wasn't sure which one to put it in, SideInfo was the path of least resistance for me15:42
ijohnsonokay, thanks pedronis I think I'm unblocked on this then I will refactor to make it clearer15:43
pedronisijohnson: basically it belongs close to the Active flag15:45
ijohnsonpedronis: is SnapState saved per-revision? it seems like SnapState is saved only once per snap instance, when the state I need to track is per-revision15:51
pedronisijohnson: is per snap15:51
pedroniswhy do you think you need to track this per revision?15:52
ijohnsonwell, imagine you have a snap that gets refreshed multiple times and you want to revert back to one of the previous revisions15:52
ijohnsoneach revision could hypothetically have different snap service names15:53
ijohnsonthat also at least handles service renames on revert, since if on rev 1 you have "svc1" and on rev 2 it gets renamed to "svc2", when you get to revision 3 you will only have saved "svc2" and lost the name of "svc1"15:54
pedronisyes, but the service picture is only for the current one15:54
ijohnsonwhat do you mean current one? I thought this flag was meant for only non-current snaps?15:54
ijohnsons/snaps/snap revisions/15:54
pedronisI mean  you install a snap with svc1 and svc215:55
pedronisyou refresh it15:55
pedronissame services15:55
pedronisyou disable svc215:55
pedronisyou revert15:55
pedronisyou want to keep svc2 disabled15:55
ijohnsonI guess I didn't think that was a use case we cared about15:55
ijohnsonI was more worried about: you install a snap with svc1 and svc2, svc2 doesn't work well, so you disable it, you refresh and now svc2 works better, you enable it, but then you revert and don't want to re-enable svc2 because it was broken in the previous revision15:57
ijohnsonhmm I guess I'm not sure we can handle both cases automatically without choosing one use case over the other or having some kind of flag15:57
pedronisI think, thinking of disable services as per revision15:58
pedronisis a bit "too much"15:58
ijohnsonI guess from the use case we had on the field team with edgex, it was more important for usability to not automatically re-enable services from previous revisions that were disabled15:58
ijohnsonbecause for example on low power hardware you don't want some of those services running because they are resource intensive15:59
pedroniswell, disable again and revert after15:59
ijohnsonhmm16:00
ijohnsonhow would you handle service renames in that situation? I don't think you could16:00
pedronisif there renames is all up to the snap16:01
pedronisor the admin16:01
pedronisnotice that if there is not admin16:01
pedronisthere is likely no disabled services either16:01
zygaI think for renames the refresh hook should have a chance to control services16:01
ijohnsonat least in the per-revision version, you handle svc renames going backwards in time16:01
ijohnsonzyga: yes the snap will always have post-refresh hook to control services16:02
pedronisthe problem is that is unclear that people expect that behavior16:02
ijohnsonzyga: I just added a spread test to make sure that works/continues to work :-)16:02
pedronisijohnson: to explain, we have similar problem with connections16:02
pedronisbut connections are also not per revision16:02
pedronisslot and plugs can come and go16:02
ijohnsonhmm right I can see that16:02
pedronisand be renamed16:02
ijohnsonI guess my expectation is that the snap's hooks can handle renames going forward in time, but snapd should handle renames going backwards in time16:03
ijohnsonbut that's just my expectation16:03
ijohnsonwhat do we do with connections on disable/enable?16:04
pedronisthey stay16:04
pedronisijohnson: anywway, what we can do is not reset any disable that has no current matching service16:05
pedronis(that's a bit similar to what we do with manual disconnects)16:05
ijohnsonyes in my implementation all service names that don't match a currently existing service it's just ignored and goes on16:05
ijohnsonwas thinking about adding a warning or something16:05
pedronisijohnson: yes, but my point is that we also want to reset the list16:05
pedronisbut we could keep in it16:06
pedronisthose services that didn't match16:06
pedronisso they would be disbaled if we go back to an impl16:06
pedronisthat has them16:06
pedronisneed to be a bit careful though16:06
ijohnsonI guess from a consistency standpoint, services should act like connections16:07
ijohnsonso if that's what's wanted I can make it per-snap, and also handle non-matching service names not disappearing somehow16:07
pedronisyes16:08
pedronisas I said, it would be odd for services and connections to have vastly different16:08
pedronissemantics vs revisions16:08
ijohnsonpedronis: so we currently store connections separate from snaps in data.conns in state.json16:09
pedroniswe do16:10
ijohnsonshould I try to match that more closely with storing services, or should I still try to fit the service states inside SnapState ?16:10
pedronisno strong preferences16:11
pedronisconns are also always there, and they are intentions16:11
pedronisin your case, state is more state that we cannot keep/pass to systemd momentarily16:11
ijohnsonright, yeah I guess connections is also something that snapd explicitly controls16:12
ijohnsonI think I will stick to putting it inside SnapState then16:12
pedronisijohnson: basically, you can think this way, if there's a unit systemd is authoritative about the state, we keep our state when that cannot be16:12
ijohnsonyes16:13
=== pstolowski is now known as pstolowski|afk
* ijohnson lunches17:25
popey_Since when did the output of "snap info" change to no longer show the channel map?17:46
popey_wait, it shows for some but not all my snaps. how odd17:48
popey_oh, it's confusing because I have a file in the current directory the same name as a snap, so it's doing "snap info folder/"17:49
popey_:(17:49
popey_that's gonna break a bunch of snapcrafters builds, as they use "snap info (snapname)" to interrogate the store17:50
zygapopey_: this has been like that for extremely long now18:38
zygapopey_: perhaps it should be tweaked in two ways18:38
zygapopey_: it could say "local file in big bright green text"18:38
zygapopey_: or it could require snap info ./foo to trigger that semantics18:39
popey_zyga: yeah, or perhaps some way to override and say "No, check the store please!"19:11
Aavarso, where does a snap keep it's config files? For example if I install something from apt it creates a config in a .file, but it seems a snap does not do that.20:36
ijohnsonAavar, it depends on the snap, some snaps keep their configuration files in the installation directory $SNAP which resolves to /snap/<name-of-snap>/current/, some keep it in $SNAP_DATA, which is usually /var/snap/<name-of-snap>/current, some keep it in $SNAP_USER_DATA which is $HOME/snap/<name-of-snap>/current20:38
Aavarijohnson, Do you know if it will be purged on removal of the snap?20:48
ijohnsonAavar, $SNAP and $SNAP_DATA will be removed if you do `snap remove <name-of-snap>` (but note you could restore it if you have snapshots enabled) while $SNAP_USER_DATA will persist after removal20:49
Aavarijohnson, thank you :)20:50
ijohnsonAavar you're welcome :-)20:52

Generated by irclog2html.py 2.7 by Marius Gedminas - find it at mg.pov.lt!