Skip to content

webkitgtk: refactor top-level to deprecate default ABI version#345611

Merged
fabianhjr merged 3 commits intoNixOS:masterfrom
fabianhjr:refactor-webkitgtk
Oct 12, 2024
Merged

webkitgtk: refactor top-level to deprecate default ABI version#345611
fabianhjr merged 3 commits intoNixOS:masterfrom
fabianhjr:refactor-webkitgtk

Conversation

@fabianhjr
Copy link
Member

@fabianhjr fabianhjr commented Sep 30, 2024

Description of changes

This is to avoid breaking things by changing the default version and making dependents more explicit about such dependency

Things done

  • Built on platform(s)
    • x86_64-linux
    • aarch64-linux
    • x86_64-darwin
    • aarch64-darwin
  • For non-Linux: Is sandboxing enabled in nix.conf? (See Nix manual)
    • sandbox = relaxed
    • sandbox = true
  • Tested, as applicable:
  • Tested compilation of all packages that depend on this change using nix-shell -p nixpkgs-review --run "nixpkgs-review rev HEAD". Note: all changes have to be committed, also see nixpkgs-review usage
  • Tested basic functionality of all binary files (usually in ./result/bin/)
  • 24.11 Release Notes (or backporting 23.11 and 24.05 Release notes)
    • (Package updates) Added a release notes entry if the change is major or breaking
    • (Module updates) Added a release notes entry if the change is significant
    • (Module addition) Added a release notes entry if adding a new NixOS module
  • Fits CONTRIBUTING.md.

Add a 👍 reaction to pull requests you find important.

@ofborg ofborg bot added 8.has: package (new) This PR adds a new package 10.rebuild-darwin: 1-10 This PR causes between 1 and 10 packages to rebuild on Darwin. 10.rebuild-darwin: 1 This PR causes 1 package to rebuild on Darwin. 10.rebuild-linux: 1-10 This PR causes between 1 and 10 packages to rebuild on Linux. 10.rebuild-linux: 1 This PR causes 1 package to rebuild on Linux. labels Oct 1, 2024
@fabianhjr fabianhjr requested review from a team, bobby285271 and khaneliman October 2, 2024 21:10
@fabianhjr fabianhjr changed the title webkitgtk: refactor top-level to allow easier change of default version webkitgtk: refactor top-level to remove dependence on default ABI version Oct 2, 2024
@fabianhjr fabianhjr changed the title webkitgtk: refactor top-level to remove dependence on default ABI version webkitgtk: refactor top-level to deprecate default ABI version Oct 2, 2024
@github-actions github-actions bot added 6.topic: python Python is a high-level, general-purpose programming language. 6.topic: haskell General-purpose, statically typed, purely functional programming language 6.topic: emacs Text editor labels Oct 5, 2024
@fabianhjr fabianhjr force-pushed the refactor-webkitgtk branch 3 times, most recently from 6a1d60f to 5be77d0 Compare October 5, 2024 01:18
@fabianhjr
Copy link
Member Author

1 package added:
webkitgtk_4_0 (init at 2.46.0+abi=4.0)

1 package removed:
webkitgtk (†2.46.0+abi=4.0)

4 packages built:
webkitgtk_4_0 webkitgtk_4_0.debug webkitgtk_4_0.dev webkitgtk_4_0.devdoc

@fabianhjr
Copy link
Member Author

Result of nixpkgs-review pr 345611 run on x86_64-linux 1

4 packages built:
  • webkitgtk_4_0
  • webkitgtk_4_0.debug
  • webkitgtk_4_0.dev
  • webkitgtk_4_0.devdoc

@fabianhjr
Copy link
Member Author

Cleaned up the tree @jtojnar, will wait a bit for feedback but this seems mergeable as is.

@khaneliman
Copy link
Contributor

 error: function 'anonymous lambda' called without required argument 'webkitgtk_4_0-web-process-extension'
       at /ofborg/checkout/2/repo/38dca4e3aa6bca43ea96d2fcc04e8229/mr-est/ofborg-evaluator-1/pkgs/development/haskell-modules/hackage-packages.nix:124272:6:
        124271|   "gi-webkitwebprocessextension" = callPackage
        124272|     ({ mkDerivation, base, bytestring, Cabal, containers, gi-gdk
             |      ^
        124273|      , gi-gio, gi-gobject, gi-gtk, gi-javascriptcore, gi-soup

@fabianhjr fabianhjr marked this pull request as draft October 5, 2024 03:06
@fabianhjr fabianhjr force-pushed the refactor-webkitgtk branch 2 times, most recently from 3f3fabb to 2c69010 Compare October 11, 2024 22:45
@fabianhjr fabianhjr requested a review from jtojnar October 11, 2024 22:48
@fabianhjr
Copy link
Member Author

Working on rebase

Copy link
Member

@jtojnar jtojnar left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks, LGTM now.

sed -i 's/ webkitgtk\b/ webkitgtk_4_0/g' pkgs/**.nix
sed -i 's/(webkitgtk\b/(webkitgtk_4_0/g' pkgs/**.nix
sed -i 's/\.webkitgtk\b/.webkitgtk_4_0/g' pkgs/**.nix

webkitgtk is currently pointing to that specific ABI version but the
alias is going to start warning
@fabianhjr
Copy link
Member Author

nixpkgs-review result

Generated using nixpkgs-review.

Command: nixpkgs-review pr 345611


x86_64-linux

✅ 4 packages built:
  • webkitgtk_4_0
  • webkitgtk_4_0.debug
  • webkitgtk_4_0.dev
  • webkitgtk_4_0.devdoc

Copy link
Member

@RossComputerGuy RossComputerGuy left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Quick skim through, LGTM.

Copy link
Contributor

@K900 K900 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM conceptually, want to see 0 rebuilds confirmed.

@fabianhjr
Copy link
Member Author

Detects the webkitgtk_4_0 as a new package so hasn't reported 0. :c

Labelled as 1 rebuild on previous evals

@fabianhjr
Copy link
Member Author

@ofborg eval

@fabianhjr
Copy link
Member Author

Eval finished as 1 rebuild due to webkitgtk_4_0 being treated as a new package

@fabianhjr fabianhjr merged commit f152a2d into NixOS:master Oct 12, 2024
@fabianhjr fabianhjr deleted the refactor-webkitgtk branch October 12, 2024 06:51
sternenseemann added a commit that referenced this pull request Oct 14, 2024
This commit partially reverts ccec93c.

This will break a lot of packages in haskellPackages (due to a missing
webkitgtk), but at least hackage-packages.nix is reproducible with the
generation shell script again.

Unfortunately, it seems the generated nature of hackage-packages.nix was
ignored when preparing the webkitgtk change:
#345611 (comment)
sternenseemann added a commit to fabianhjr/cabal2nix that referenced this pull request Oct 17, 2024
When we don't know the exact version from the cabal file, we still emit
the generic name that has recently been removed from nixpkgs safe for an
alias (NixOS/nixpkgs#345611) which we can't use
in hackage-packages.nix. This is still the best solution for downstream
expressions generated by cabal2nix, in nixpkgs we'll have to manually
specify the correct version (instead of hackage2nix picking the default
which may not always be correct).

Co-authored-by: sternenseemann <[email protected]>
sternenseemann added a commit to fabianhjr/cabal2nix that referenced this pull request Oct 17, 2024
When we don't know the exact version from the cabal file, we still emit
the generic name that has recently been removed from nixpkgs safe for an
alias (NixOS/nixpkgs#345611) which we can't use
in hackage-packages.nix. This is still the best solution for downstream
expressions generated by cabal2nix, in nixpkgs we'll have to manually
specify the correct version (instead of hackage2nix picking the default
which may not always be correct).

Co-authored-by: sternenseemann <[email protected]>
@fabianhjr fabianhjr mentioned this pull request Jun 12, 2025
13 tasks
fabianhjr added a commit to fabianhjr/nixpkgs that referenced this pull request Jun 12, 2025
Follow up to NixOS#345611 (f152a2d)

Co-authored-by: Jan Tojnar <[email protected]>
Co-authored-by: Aleksana <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

6.topic: emacs Text editor 6.topic: haskell General-purpose, statically typed, purely functional programming language 6.topic: python Python is a high-level, general-purpose programming language. 8.has: clean-up This PR removes packages or removes other cruft 8.has: package (new) This PR adds a new package 10.rebuild-darwin: 1-10 This PR causes between 1 and 10 packages to rebuild on Darwin. 10.rebuild-darwin: 1 This PR causes 1 package to rebuild on Darwin. 10.rebuild-linux: 1-10 This PR causes between 1 and 10 packages to rebuild on Linux. 10.rebuild-linux: 1 This PR causes 1 package to rebuild on Linux.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

6 participants