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

sleek: init at 1.3.1 #225175

Closed
wants to merge 1 commit into from
Closed

sleek: init at 1.3.1 #225175

wants to merge 1 commit into from

Conversation

auroraanna
Copy link
Contributor

@auroraanna auroraanna commented Apr 7, 2023

Description of changes

Added package sleek.

Things done
  • Built on platform(s)
    • x86_64-linux
    • aarch64-linux
    • x86_64-darwin
    • aarch64-darwin
  • For non-Linux: Is sandbox = true set in nix.conf? (See Nix manual)
  • 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/)
  • 23.05 Release Notes (or backporting 22.11 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.

@auroraanna
Copy link
Contributor Author

auroraanna commented Apr 7, 2023

It currently only works if you run do steam-run sleek. If you don't do that it doesn't even tell you what the problem is.

$ ./result/bin/sleek

^ no output

$ ./result/bin/.sleek-wrapped
zsh: no such file or directory: ./result/bin/.sleek-wrapped

@auroraanna auroraanna added the 8.has: package (new) This PR adds a new package label Apr 7, 2023
@auroraanna
Copy link
Contributor Author

auroraanna commented Apr 7, 2023

This is only x86_64-linux for now. I plan to add other platforms later when the above issue has been fixed.

@auroraanna auroraanna added 2.status: work-in-progress This PR isn't done needs_reviewer (old Marvin label, do not use) awaiting_reviewer (old Marvin label, do not use) labels Apr 7, 2023
pkgs/applications/office/sleek/default.nix Outdated Show resolved Hide resolved
pkgs/applications/office/sleek/default.nix Outdated Show resolved Hide resolved
pkgs/applications/office/sleek/default.nix Outdated Show resolved Hide resolved
pkgs/applications/office/sleek/default.nix Outdated Show resolved Hide resolved
pkgs/applications/office/sleek/default.nix Outdated Show resolved Hide resolved
@auroraanna auroraanna force-pushed the sleek branch 2 times, most recently from a366f19 to 27f9a51 Compare April 9, 2023 11:21
@auroraanna
Copy link
Contributor Author

Due to using nixpkgs electron every issue but that electron_18 is EOL has been fixed.

@auroraanna
Copy link
Contributor Author

ransome1/sleek#481

@auroraanna
Copy link
Contributor Author

I don't understand why ofborg fails.

@auroraanna
Copy link
Contributor Author

ransome1/sleek#482 related to the Exec=sleek %U in the .desktop file.

@auroraanna auroraanna added the 2.status: blocked by pr/issue Another PR or issue is preventing this from being completed label Apr 9, 2023
@auroraanna
Copy link
Contributor Author

Another issue, bitwarden and jitsi-meet-electron put --add-flags "\''${NIXOS_OZONE_WL:+\''${WAYLAND_DISPLAY:+--ozone-platform-hint=auto --enable-features=WaylandWindowDecorations}}" in their makeWrapper command but I tried those programs on sway and xeyes tells me they are still running on Xorg. How to run on wayland?

@auroraanna
Copy link
Contributor Author

Should this be moved to nodePackages?

@SuperSandro2000
Copy link
Member

Should this be moved to nodePackages?

No, updating nodePackages is a pain.

, lib
}:

mkYarnPackage rec {
Copy link
Member

Choose a reason for hiding this comment

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

I think mkYarnPackage is missing its package.json.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

But the package.json is in the src, it's even being patched successfully. What do you mean it's missing?

Copy link
Member

Choose a reason for hiding this comment

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

I think that is triggering IFD which is forbidden in nixpkgs

Copy link
Contributor Author

Choose a reason for hiding this comment

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

I'm missing context. Why is it triggering IFD?

Copy link
Member

Choose a reason for hiding this comment

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

mkYarnPackage falls internally back to IFD. We should probably disable that for nixpkgs. Please see other packages how to provide the package.json.

Copy link
Member

Choose a reason for hiding this comment

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

ofborg eval still fails with the following error which means IFD is used

nix-env failed:
error:
       … while evaluating call site

       at «none»:0: (source not available)

       … while calling anonymous lambda

       at /var/lib/ofborg/checkout/repo/38dca4e3aa6bca43ea96d2fcc04e8229/mr-est/ofborg-evaluator-2/.gc-of-borg-outpaths.nix:47:12:

           46|   tweak = lib.mapAttrs
           47|     (name: val:
             |            ^
           48|       if name == "recurseForDerivations" then true

       … while evaluating call site

       at «none»:0: (source not available)

       … while calling 'g'

       at /var/lib/ofborg/checkout/repo/38dca4e3aa6bca43ea96d2fcc04e8229/mr-est/ofborg-evaluator-2/lib/attrsets.nix:595:19:

          594|           g =
          595|             name: value:
             |                   ^
          596|             if isAttrs value && cond value

       … while evaluating call site

       at «none»:0: (source not available)

       … while calling anonymous lambda

       at /var/lib/ofborg/checkout/repo/38dca4e3aa6bca43ea96d2fcc04e8229/mr-est/ofborg-evaluator-2/pkgs/top-level/release-lib.nix:148:38:

          147|      set of meta.platforms values. */
          148|   packagePlatforms = mapAttrs (name: value:
             |                                      ^
          149|       if isDerivation value then

       … while evaluating the attribute 'meta.hydraPlatforms'

       at /var/lib/ofborg/checkout/repo/38dca4e3aa6bca43ea96d2fcc04e8229/mr-est/ofborg-evaluator-2/pkgs/stdenv/generic/make-derivation.nix:558:13:

          557|      inherit passthru overrideAttrs;
          558|      inherit meta;
             |             ^
          559|    } //

       … while evaluating call site

       at /var/lib/ofborg/checkout/repo/38dca4e3aa6bca43ea96d2fcc04e8229/mr-est/ofborg-evaluator-2/pkgs/stdenv/generic/make-derivation.nix:505:10:

          504|
          505|   meta = checkMeta.commonMeta { inherit validity attrs pos references; };
             |          ^
          506|   validity = checkMeta.assertValidity { inherit meta attrs; };

       … while calling 'commonMeta'

       at /var/lib/ofborg/checkout/repo/38dca4e3aa6bca43ea96d2fcc04e8229/mr-est/ofborg-evaluator-2/pkgs/stdenv/generic/check-meta.nix:401:16:

          400|   #   validity = checkMeta.assertValidity { inherit meta attrs; };
          401|   commonMeta = { validity, attrs, pos ? null, references ? [ ] }:
             |                ^
          402|     let

       … while evaluating the attribute 'meta'

       at /var/lib/ofborg/checkout/repo/38dca4e3aa6bca43ea96d2fcc04e8229/mr-est/ofborg-evaluator-2/pkgs/development/tools/yarn2nix-moretea/yarn2nix/default.nix:391:7:

          390|
          391|       meta = {
             |       ^
          392|         inherit (nodejs.meta) platforms;

       … while evaluating call site

       at /var/lib/ofborg/checkout/repo/38dca4e3aa6bca43ea96d2fcc04e8229/mr-est/ofborg-evaluator-2/pkgs/development/tools/yarn2nix-moretea/yarn2nix/default.nix:393:12:

          392|         inherit (nodejs.meta) platforms;
          393|       } // lib.optionalAttrs (package ? description) { inherit (package) description; }
             |            ^
          394|         // lib.optionalAttrs (package ? homepage) { inherit (package) homepage; }

       … while calling 'optionalAttrs'

       at /var/lib/ofborg/checkout/repo/38dca4e3aa6bca43ea96d2fcc04e8229/mr-est/ofborg-evaluator-2/lib/attrsets.nix:675:5:

          674|     # The attribute set to return if `cond` is `true`.
          675|     as:
             |     ^
          676|     if cond then as else {};

       … while evaluating call site

       at /var/lib/ofborg/checkout/repo/38dca4e3aa6bca43ea96d2fcc04e8229/mr-est/ofborg-evaluator-2/pkgs/development/tools/yarn2nix-moretea/yarn2nix/default.nix:269:17:

          268|     let
          269|       package = lib.importJSON packageJSON;
             |                 ^
          270|       pname = package.name;

       … while calling 'importJSON'

       at /var/lib/ofborg/checkout/repo/38dca4e3aa6bca43ea96d2fcc04e8229/mr-est/ofborg-evaluator-2/lib/trivial.nix:312:16:

          311|   */
          312|   importJSON = path:
             |                ^
          313|     builtins.fromJSON (builtins.readFile path);

       … while realising the context of path '/nix/store/mbhbjyk01mlpakmwlzh673hkyi6lhxar-source/package.json'

       at /var/lib/ofborg/checkout/repo/38dca4e3aa6bca43ea96d2fcc04e8229/mr-est/ofborg-evaluator-2/lib/trivial.nix:313:24:

          312|   importJSON = path:
          313|     builtins.fromJSON (builtins.readFile path);
             |                        ^
          314|

       error: path '/nix/store/nj2j3nn03j2p5zwv7yb8d29rihhkhdjq-source.drv' is not valid

Copy link
Contributor Author

@auroraanna auroraanna May 19, 2023

Choose a reason for hiding this comment

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

oh, IFD is used because it's converting the JSON to nix and then IFDing that. I don't know how else to specify the package.json though. A lot of other node programs do that.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

the entire package.json would have to be converted to nix and then inlined into the default.nix

Copy link
Contributor Author

Choose a reason for hiding this comment

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

which sounds unnecessarily complex.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

/me is looking at more other yarn packages

@auroraanna
Copy link
Contributor Author

Should this be moved to nodePackages?

No, updating nodePackages is a pain.

But, should it be moved there at some point when updating nodePackages is not a pain anymore?

@SuperSandro2000
Copy link
Member

But, should it be moved there at some point when updating nodePackages is not a pain anymore?

I don't think there are plans for that right now. nodePackages would need to be redone with a different tool or the tool would need major improvements.

@auroraanna
Copy link
Contributor Author

auroraanna commented Apr 12, 2023

ransome1/sleek#481

It seems to work perfectly fine with electron 23 though. If none responds to that issue, should this package just use electron 23? Else this package is marked as insecure, which is annoying when installing.

@auroraanna
Copy link
Contributor Author

I added the update script.

@auroraanna
Copy link
Contributor Author

The checkPhase fails and I don't understand the error.

Co-authored-by: Sandro <sandro.jaeckel@gmail.com>
@DamienCassou
Copy link
Contributor

Any update on that?

@auroraanna
Copy link
Contributor Author

superseded by #271676

@auroraanna auroraanna closed this Dec 2, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
2.status: blocked by pr/issue Another PR or issue is preventing this from being completed 2.status: work-in-progress This PR isn't done 8.has: package (new) This PR adds a new package awaiting_reviewer (old Marvin label, do not use) needs_reviewer (old Marvin label, do not use)
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants