Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

flatpak: 1.6.3 → 1.8.1 #93771

Merged
merged 4 commits into from Jul 26, 2020
Merged

flatpak: 1.6.3 → 1.8.1 #93771

merged 4 commits into from Jul 26, 2020

Conversation

jtojnar
Copy link
Contributor

@jtojnar jtojnar commented Jul 24, 2020

Motivation for this change

Changes:

Commits:
flatpak/flatpak@1.6.3...1.7.1
flatpak/flatpak@1.7.1...1.8.1

Notable packaging changes:

  • Flatpak now ships a sysusers.d file for allowing systemd to create the required users.
    flatpak/flatpak@4df0190
  • Completion support for fish shell
  • If an app has filesystem access, the host /lib is accessible as /run/host/lib, etc.
  • New filesystem permission "host-etc" and "host-os" give access to system /usr and /etc.
    flatpak/flatpak@fe2536b
  • We now always expose the host timezone data, allowing us the expose the host /etc/localtime in a way that works better, fixing several apps that had timezone issues.
    flatpak/flatpak@dc4e198
  • We now ship a systemd unit (not installed by default) to automatically detect plugged in usb sticks with sideload repos.
  • By default we no longer install the gdm env.d file, as the systemd generators work better
    flatpak/flatpak@7c3a85b
  • Use variant-schema-compiler for some GVariant code
    Use variant-schema-compiler for some GVariant code flatpak/flatpak#3366
  • zstd compression for oci deltas:
    flatpak/flatpak@bfa71e2

Additionally:

  • Remove glibcLocales which is not used since 1.4 bump because glibc contains a locale archive with C.UTF-8
    1728bc8
  • Stop using aliases for docbook-xsl-nons and pkg-config packages
  • Stop using autoreconfHook, the autogen.sh script contains some extra that are necessary when building from git.
  • Increase disk space for installed tests, they were running out.
  • Enable building developer documentation.

Also fix installed test.

Things done
  • Tested using sandboxing (nix.useSandbox on NixOS, or option sandbox in nix.conf on non-NixOS linux)
  • Built on platform(s)
    • NixOS
    • macOS
    • other Linux distributions
  • Tested via one or more NixOS test(s)
    • flatpak.tests passed with the test fixes before updating to 1.8.1 (took 80 min)
    • flatpak.tests passed with the test fixes after updating to 1.8.1 (took 63 min)
  • Tested compilation of all pkgs that depend on this change using nix-shell -p nixpkgs-review --run "nixpkgs-review wip"
  • Tested execution of all binary files (usually in ./result/bin/)
  • Determined the impact on package closure size (by running nix path-info -S before and after)
  • Ensured that relevant documentation is up to date
  • Fits CONTRIBUTING.md.

Flatpak’s installed tests build Flatpak runtimes, among other things.
Upstream code does this by copying some programs on `PATH`
as well as some possible dependencies from host’s /usr.
We patch the code to use `nix-store --query --requisites`
to make the dependency discovery easier.

The Flatpak’s installed tests add `socat` to `PATH` and later run
`nix-store --query --requisites` on its location but it was failing with

    error: path '/nix/store/qcyf7nq5vvfw32967sv4j6z190inrbrc-socat-1.7.3.4' is not valid

The issue occurred because, while the host Nix store is bind mounted into the test VM,
the VM’s store uses its own database that only contains the packages in the VM’s closure.
Since the test commands are not actually part of the VM but only passed through PTY,
the `flatpak.installedTests` derivation was not part of the VM’s closure, so `nix-store`
in the VM could not get information about its dependency `socat`.

Let’s make the `installedTests` of the tested package part of the test VM’s closure
by passing it as a global environment variable. This will also have the added benefit
that user no longer has to type the path when running the installed tests manually in the VM;
they can just use `gnome-desktop-testing-runner -d $TESTED_PACKAGE_INSTALLED_TESTS`,
which is much more conducive to tab completion.
Along with the `socat` fix in the parent commit, this makes
the Flatpak’s installed tests finally pass again.

The tests seem to need slightly over 2G of disk space,
and it appears that the test suite was ported to Python 3 in 1.5.1:
flatpak/flatpak@2b66415
@jtojnar
Copy link
Contributor Author

jtojnar commented Jul 24, 2020

After 62 minutes, just the two new tests are failing so quite nice:

vm-test-run-flatpak> SUMMARY: total=32; passed=30; skipped=0; failed=2; user=820.8s; system=589.3s; maxrss=445132
vm-test-run-flatpak> FAIL: flatpak/test-oci-registry@user.wrap.test (Child process exited with code 1)
vm-test-run-flatpak> FAIL: flatpak/test-oci-registry@system.wrap.test (Child process exited with code 1)

@jtojnar
Copy link
Contributor Author

jtojnar commented Jul 24, 2020

That is weird, there are no errors other than error: The name org.flatpak.Authenticator.Oci was not provided by any .service files and D-Feet can see the service:

image

Full log: test-oci-registry@system.wrap.test.log

Changes:
* https://github.com/flatpak/flatpak/releases/tag/1.7.1
* https://github.com/flatpak/flatpak/releases/tag/1.7.2
* https://github.com/flatpak/flatpak/releases/tag/1.7.3
* https://github.com/flatpak/flatpak/releases/tag/1.8.0
* https://github.com/flatpak/flatpak/releases/tag/1.8.1

Commits:
flatpak/flatpak@1.6.3...1.7.1
flatpak/flatpak@1.7.1...1.8.1

Notable packaging changes:
* Flatpak now ships a sysusers.d file for allowing systemd to create the required users.
  flatpak/flatpak@4df0190
* Completion support for fish shell
* If an app has filesystem access, the host /lib is accessible as /run/host/lib, etc.
* New filesystem permission "host-etc" and "host-os" give access to system /usr and /etc.
  flatpak/flatpak@fe2536b
* We now always expose the host timezone data, allowing us the expose the host /etc/localtime in a way that works better, fixing several apps that had timezone issues.
  flatpak/flatpak@dc4e198
* We now ship a systemd unit (not installed by default) to automatically detect plugged in usb sticks with sideload repos.
* By default we no longer install the gdm env.d file, as the systemd generators work better
  flatpak/flatpak@7c3a85b
* Use variant-schema-compiler for some GVariant code
  flatpak/flatpak#3366
* zstd compression for oci deltas:
  flatpak/flatpak@bfa71e2

Additionally:
* Remove glibcLocales which is not used since 1.4 bump because glibc contains a locale archive with C.UTF-8
  NixOS@1728bc8
* Stop using aliases for docbook-xsl-nons and pkg-config packages
* Stop using autoreconfHook, the autogen.sh script contains some extra that are necessary when building from git.
* Increase disk space for installed tests, they were running out.
* Enable building developer documentation.
@jtojnar jtojnar marked this pull request as ready for review July 24, 2020 17:42
@jtojnar
Copy link
Contributor Author

jtojnar commented Jul 24, 2020

Turns out it was a flatpak bug, opened flatpak/flatpak#3762 with a fix.

@jtojnar jtojnar requested review from zowoq and worldofpeace and removed request for zowoq July 24, 2020 17:42
GNOME is not necessary. Portals probably are not either,
but the NixOS module requires them.

Not sure why it did not work without GNOME before.
@jtojnar jtojnar added the 8.has: upstream changes reviewed Reviewer checked the changelogs/commit logs associated with the release and did not find any issues. label Jul 24, 2020
@jtojnar jtojnar closed this Jul 26, 2020
@jtojnar jtojnar reopened this Jul 26, 2020
@jtojnar jtojnar merged commit a86f411 into NixOS:master Jul 26, 2020
@jtojnar jtojnar deleted the flatpak-1.8 branch July 26, 2020 11:56
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

1 participant