Skip to content

gdtoolkit_4: init at 4.2.2#291040

Merged
kirillrdy merged 3 commits intoNixOS:masterfrom
squarepear:gdtoolkit-4
Jun 8, 2024
Merged

gdtoolkit_4: init at 4.2.2#291040
kirillrdy merged 3 commits intoNixOS:masterfrom
squarepear:gdtoolkit-4

Conversation

@squarepear
Copy link
Member

Description of changes

Rename gdtoolkit to gdtoolkit_3
Init gdtoolkit_4 at v4.2.2
Update gdtoolkit_3 to v3.5.0

Tested and seems to be working fine.

Resolves #267249

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.05 Release Notes (or backporting 23.05 and 23.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.

Add a 👍 reaction to pull requests you find important.

@ofborg ofborg bot added 8.has: clean-up This PR removes packages or removes other cruft 8.has: package (new) This PR adds a new package labels Feb 24, 2024
@ofborg ofborg bot requested review from hesiod and shiryel February 24, 2024 02:36
@ofborg ofborg bot added 10.rebuild-darwin: 1-10 This PR causes between 1 and 10 packages to rebuild on Darwin. 10.rebuild-linux: 1-10 This PR causes between 1 and 10 packages to rebuild on Linux. labels Feb 24, 2024
@kirillrdy
Copy link
Member

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

2 packages failed to build:
  • gdtoolkit_4
  • gdtoolkit_4.dist
2 packages built:
  • gdtoolkit_3
  • gdtoolkit_3.dist

logs

=============================== warnings summary ===============================
gdtoolkit/parser/parser.py:8
  /build/source/gdtoolkit/parser/parser.py:8: DeprecationWarning: pkg_resources is deprecated as an API. See https://setuptools.pypa.io/en/latest/pkg_resources.html
    import pkg_resources

-- Docs: https://docs.pytest.org/en/stable/how-to/capture-warnings.html
=========================== short test summary info ============================
FAILED tests/generated/test_expression_parsing.py::test_expression_formatting - gdtoolkit.formatter.exceptions.TreeInvariantViolation: TreeInvariantViolati...
===== 1 failed, 497 passed, 307 skipped, 2 deselected, 1 warning in 44.31s =====

@kirillrdy
Copy link
Member

it build the second time :-)

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

4 packages built:
  • gdtoolkit_3
  • gdtoolkit_3.dist
  • gdtoolkit_4
  • gdtoolkit_4.dist

@squarepear
Copy link
Member Author

I just had the same issue when running on GitHub actions, it was fine the second time I ran it? I'll look into it, but it's a bit difficult since it doesn't happen locally or even consistently.

Some quick research makes me think it is something to do with setuptools, maybe it should be somewhere else rather than propagatedBuildInputs? Still very strange that it isn't always an issue.

@squarepear squarepear force-pushed the gdtoolkit-4 branch 4 times, most recently from 2c60700 to ec195a2 Compare March 7, 2024 22:18
@squarepear
Copy link
Member Author

I've been using the package for the past week or so without running in to the issue. setuptools had been updated in nixpkgs since creating this PR, so I updated the branch. I believe there was an issue with that specific version of setuptools that has since been fixed.

I think this PR is ready to merge!

Copy link
Member

Choose a reason for hiding this comment

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

https://github.com/NixOS/nixpkgs/blob/master/pkgs/README.md#package-naming

The pname attribute should be identical to the upstream package name.

Copy link
Member Author

Choose a reason for hiding this comment

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

Since both versions of gdtoolkit may be in use, I followed what was chosen for Godot 3 and 4. There may be a better way to do this that I am missing, so please let me know if that is the case!


Copy link
Member

Choose a reason for hiding this comment

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

version will be appended, so you can have both installed name=godot-3.3.1 and name=godot-4.4.2

I am not aware of any issues or reasons for changing pname

Copy link
Member Author

Choose a reason for hiding this comment

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

Hmm, I originally thought that as well, but wanted to keep it similar to Godot. I'll check to see if I can find an issue/PR where that was discussed to see why that was chosen.

Copy link
Member

Choose a reason for hiding this comment

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

Choose a reason for hiding this comment

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

It seems the names should be without an _ then? That's what godot itself is doing, and seems nice to have it consistent.

The docs do indeed say The pname attribute should be identical to the upstream package name. (as linked above) but should is key here, and this feels like a valid reason for the extra number.

Copy link
Member

Choose a reason for hiding this comment

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

whats the justification for now having this toplevel attribute ?

Copy link
Member Author

Choose a reason for hiding this comment

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

Like with the package name, I followed how this was implemented for Godot 3 and 4.

godot = throw "godot has been renamed to godot3 to distinguish from version 4"; # Added 2023-07-16

Copy link

@TheOddler TheOddler left a comment

Choose a reason for hiding this comment

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

Tested and works for me. Code seems good. Do see my comment below about the naming, I'm happy to approve already and leave it up to your best judgement with the name.

Choose a reason for hiding this comment

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

It seems the names should be without an _ then? That's what godot itself is doing, and seems nice to have it consistent.

The docs do indeed say The pname attribute should be identical to the upstream package name. (as linked above) but should is key here, and this feels like a valid reason for the extra number.

@squarepear
Copy link
Member Author

That's fair, I can get that updated! The whole naming scheme with Godot is a bit odd, godot3 vs godot_4, but it makes sense to match the pnames.

@TheOddler
Copy link

Yea, I got confused looking into the naming too, the Godot packages don't seem consistent, and they changed it for godot 3 but not for godot 4 at some point, idk. A bit messy, so I guess best you can do is not add to the mess?

@kirillrdy
Copy link
Member

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

2 packages failed to build:
  • gdtoolkit_4
  • gdtoolkit_4.dist
2 packages built:
  • gdtoolkit_3
  • gdtoolkit_3.dist

@TheOddler
Copy link

Oh, I only tested by actually running it as part of my system (actually using it). Also tried nixpkgs-review now, and it fails some tests:

❯ nix-shell -p nixpkgs-review --run "nixpkgs-review pr 291040"
[...]
error: builder for '/nix/store/9s9kzlm9vj39inkznyb64i5hhaamj94j-gdtoolkit-4.2.2.drv' failed with exit code 1;
       last 10 log lines:
       > gdtoolkit/parser/parser.py:8
       >   /build/source/gdtoolkit/parser/parser.py:8: DeprecationWarning: pkg_resources is deprecated as an API. See https://setuptools.pypa.io/en/latest/pkg_resources.html
       >     import pkg_resources
       >
       > -- Docs: https://docs.pytest.org/en/stable/how-to/capture-warnings.html
       > =========================== short test summary info ============================
       > FAILED tests/generated/test_expression_parsing.py::test_expression_parsing - hypothesis.errors.InvalidArgument: Undefined terminals ['_DEDENT', '_INDENT...
       > FAILED tests/generated/test_expression_parsing.py::test_expression_formatting - hypothesis.errors.InvalidArgument: Undefined terminals ['_DEDENT', '_INDENT...
       > ===== 2 failed, 496 passed, 307 skipped, 2 deselected, 1 warning in 11.69s =====
       > /nix/store/xfhkjnpqjwlf6hlk1ysmq3aaq80f3bjj-stdenv-linux/setup: line 1579: pop_var_context: head of shell_variables not a function context
       For full logs, run 'nix log /nix/store/9s9kzlm9vj39inkznyb64i5hhaamj94j-gdtoolkit-4.2.2.drv'.
error: 1 dependencies of derivation '/nix/store/7jxp9pnzc5r05b8bizxxa6aqcnx56czv-review-shell.drv' failed to build

Link to currently reviewing PR:
https://github.com/NixOS/nixpkgs/pull/291040

2 packages failed to build:
gdtoolkit_4 gdtoolkit_4.dist

2 packages built:
gdtoolkit_3 gdtoolkit_3.dist

@ArtixBTW
Copy link
Contributor

ArtixBTW commented Jun 6, 2024

Oh, I only tested by actually running it as part of my system (actually using it). Also tried nixpkgs-review now, and it fails some tests:

❯ nix-shell -p nixpkgs-review --run "nixpkgs-review pr 291040"
[...]
error: builder for '/nix/store/9s9kzlm9vj39inkznyb64i5hhaamj94j-gdtoolkit-4.2.2.drv' failed with exit code 1;
       last 10 log lines:
       > gdtoolkit/parser/parser.py:8
       >   /build/source/gdtoolkit/parser/parser.py:8: DeprecationWarning: pkg_resources is deprecated as an API. See https://setuptools.pypa.io/en/latest/pkg_resources.html
       >     import pkg_resources
       >
       > -- Docs: https://docs.pytest.org/en/stable/how-to/capture-warnings.html
       > =========================== short test summary info ============================
       > FAILED tests/generated/test_expression_parsing.py::test_expression_parsing - hypothesis.errors.InvalidArgument: Undefined terminals ['_DEDENT', '_INDENT...
       > FAILED tests/generated/test_expression_parsing.py::test_expression_formatting - hypothesis.errors.InvalidArgument: Undefined terminals ['_DEDENT', '_INDENT...
       > ===== 2 failed, 496 passed, 307 skipped, 2 deselected, 1 warning in 11.69s =====
       > /nix/store/xfhkjnpqjwlf6hlk1ysmq3aaq80f3bjj-stdenv-linux/setup: line 1579: pop_var_context: head of shell_variables not a function context
       For full logs, run 'nix log /nix/store/9s9kzlm9vj39inkznyb64i5hhaamj94j-gdtoolkit-4.2.2.drv'.
error: 1 dependencies of derivation '/nix/store/7jxp9pnzc5r05b8bizxxa6aqcnx56czv-review-shell.drv' failed to build

Link to currently reviewing PR:
https://github.com/NixOS/nixpkgs/pull/291040

2 packages failed to build:
gdtoolkit_4 gdtoolkit_4.dist

2 packages built:
gdtoolkit_3 gdtoolkit_3.dist

I've been using this locally and worked around this by just disabling tests for these.

+  disabledTestPaths = [
+    "tests/generated/test_expression_parsing.py"
+    "tests/gdradon/test_executable.py"
+  ];

What I find odd though is that if I do multiple rebuilds these tests sometimes don't fail and sometimes do, quite odd, also not quite sure why disabledTests isn't disabling the individual tests that seem to be failing.

@TheOddler
Copy link

I've been using this locally

This is what I've been doing as well, and it works well so far, no problems.

worked around this by just disabling tests for these

I did not have to disable any tests. I'm not sure what your setup is, but I added github:squarepear/nixpkgs/gdtoolkit-4 as an input to my nixos config inputs (I'm using flakes), added it as an overlay to my channels, and then included gdtoolkit_4 in my system packages. Didn't have to do anything else like disabling tests.

@squarepear
Copy link
Member Author

I've been using this locally and worked around this by just disabling tests for these.

+  disabledTestPaths = [
+    "tests/generated/test_expression_parsing.py"
+    "tests/gdradon/test_executable.py"
+  ];

It seems to be working for me, but the inconsistency makes it difficult to tell. Hopefully everything is good now, but if anyone still has issues, let me know!

Copy link
Member

@kirillrdy kirillrdy left a comment

Choose a reason for hiding this comment

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

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

4 packages built:
  • gdtoolkit_3
  • gdtoolkit_3.dist
  • gdtoolkit_4
  • gdtoolkit_4.dist

@kirillrdy kirillrdy merged commit 6919189 into NixOS:master Jun 8, 2024
@nixos-discourse
Copy link

This pull request has been mentioned on NixOS Discourse. There might be relevant details there:

https://discourse.nixos.org/t/how-to-introduce-a-breaking-version-bump/46746/2

@Thiago-Assis-T
Copy link

Hello, this seemed to break my system upgrade, on unstable-small, even though i don't use godot...

it spits out on the upgrade:

         at /nix/store/ab6iajix47qdm2v098dcdaqis6094300-source/pkgs/top-level/aliases.nix:38:20:

           37|   # Make sure that we are not shadowing something from all-packages.nix.
           38|   checkInPkgs = n: alias:
             |                    ^
           39|     if builtins.hasAttr n super

       error: gdtoolkit has been renamed to gdtoolkit_3 to distinguish from version 4

this host is a media server, running jellyfin, radarr, deluge... nothing with godot or games, or game dev... not even a gui.

here is the config: https://github.com/Thiago-Assis-T/.nixos and the hostname is ThiagoServer, i tried show trace and mentioned the issue on discourse

@nixos-discourse
Copy link

This pull request has been mentioned on NixOS Discourse. There might be relevant details there:

https://discourse.nixos.org/t/package-name-changed-gdtoolkit-gdtoolkit-3-but-i-dont-use-that-package-directly-and-was-unable-to-identify-what-it-is-a-dep-of/46761/3

@squarepear squarepear deleted the gdtoolkit-4 branch June 9, 2024 13:13
@squarepear squarepear restored the gdtoolkit-4 branch June 9, 2024 13:13
@squarepear
Copy link
Member Author

Hello, this seemed to break my system upgrade, on unstable-small, even though i don't use godot...

it spits out on the upgrade:

         at /nix/store/ab6iajix47qdm2v098dcdaqis6094300-source/pkgs/top-level/aliases.nix:38:20:

           37|   # Make sure that we are not shadowing something from all-packages.nix.
           38|   checkInPkgs = n: alias:
             |                    ^
           39|     if builtins.hasAttr n super

       error: gdtoolkit has been renamed to gdtoolkit_3 to distinguish from version 4

this host is a media server, running jellyfin, radarr, deluge... nothing with godot or games, or game dev... not even a gui.

here is the config: Thiago-Assis-T/.nixos and the hostname is ThiagoServer, i tried show trace and mentioned the issue on discourse

That's very strange. I have a bit of time this morning, I'll look into it and see if I can find anything!

My first complete guess would be something like nvim or similar using it as a formatter, but it doesn't make much sense that you would have the gdtoolkit formatter in your config.

@Thiago-Assis-T
Copy link

AAAAA yess, i'm using nixvim, with all ts grammars... perhaps thats it? i dont have as formatter or as linter though, never messed with godot, so never added it...

@squarepear
Copy link
Member Author

Wow, guess seems to have been correct! It looks like it is an issue with nixvim

nix-community/nixvim#1660
nix-community/nixvim#1659

@squarepear
Copy link
Member Author

AAAAA yess, i'm using nixvim, with all ts grammars... perhaps thats it? i dont have as formatter or as linter though, never messed with godot, so never added it...

Yep 😄

@Thiago-Assis-T
Copy link

thank you @squarepear

@nixos-discourse
Copy link

This pull request has been mentioned on NixOS Discourse. There might be relevant details there:

https://discourse.nixos.org/t/package-name-changed-gdtoolkit-gdtoolkit-3-but-i-dont-use-that-package-directly-and-was-unable-to-identify-what-it-is-a-dep-of/46761/4

@squarepear squarepear deleted the gdtoolkit-4 branch June 11, 2024 23:06
nbw added a commit to nbw/nixvim that referenced this pull request Jun 23, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

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-linux: 1-10 This PR causes between 1 and 10 packages to rebuild on Linux.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Update request: gdtoolkit 3.3.1 → 4.1.0

6 participants

Comments