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

tockloader: init at v1.4.0 #80829

Merged
merged 1 commit into from May 22, 2020
Merged

tockloader: init at v1.4.0 #80829

merged 1 commit into from May 22, 2020

Conversation

@mweinelt
Copy link
Member

mweinelt commented Feb 22, 2020

Motivation for this change

Tockloader describes itself as a "Tool for programming Tock onto hardware boards."

Personally I'm trying to get OpenSK (https://github.com/google/OpenSK) running on a Nordic nRF52840 MDK and the deploy process requires among other things tockloader.

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) if existing and applicable for the change (look inside nixos/tests)
  • 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.
@mweinelt mweinelt requested review from FRidh and jonringer as code owners Feb 22, 2020
@mweinelt mweinelt force-pushed the mweinelt:pr/tockloader branch from e1dd613 to 00ca3bc Feb 22, 2020
@ofborg ofborg bot added the 6.topic: python label Feb 22, 2020
@mweinelt
Copy link
Member Author

mweinelt commented Feb 22, 2020

How is the python-packages.nix top-level file sorted?

@jonringer
Copy link
Contributor

jonringer commented Feb 22, 2020

How is the python-packages.nix top-level file sorted?

it's not.

Some additions grouped similar packages. a lot just did lexigraphical sorting.

Right now it's just a "best try"

@mweinelt mweinelt force-pushed the mweinelt:pr/tockloader branch from 00ca3bc to efdd3c1 Apr 20, 2020
@mweinelt
Copy link
Member Author

mweinelt commented Apr 20, 2020

Updated to disable python2 support, which was failing.

Copy link
Contributor

jonringer left a comment

There are no tests included. Please try to checkout from source and check if they have unit tests, and try to run them. Unit tests give a good indication that they package has a high degree of validity and correctness given the python package set.

If tests are not available, then please use pythonImportsCheck to import the most important modules. This isn't as good as unit tests, but will usually give a good indication of run-time errors.


----------------------------------------------------------------------
Ran 0 tests in 0.000s
@mweinelt mweinelt force-pushed the mweinelt:pr/tockloader branch from efdd3c1 to 00f7e47 May 3, 2020
@mweinelt
Copy link
Member Author

mweinelt commented May 3, 2020

I tried importing the TockLoader class, but couldn't properly adress it. I tried tockloader.tockloader.TockLoader (package.file.class).

https://github.com/tock/tockloader/blob/master/tockloader/tockloader.py#L28

So for now I settled for the package import, which isn't very helpful.

@mweinelt
Copy link
Member Author

mweinelt commented May 3, 2020

The package has no test suite and their CI job just tries to call tockloader --version and tockloader list-known-boards.

@mweinelt mweinelt force-pushed the mweinelt:pr/tockloader branch from 00f7e47 to 434441b May 3, 2020
@jonringer
Copy link
Contributor

jonringer commented May 3, 2020

The package has no test suite and their CI job just tries to call tockloader --version and tockloader list-known-boards.

That's.... concerning

Copy link
Contributor

jonringer left a comment

is this only meant to be use as an application? (E.g $ tockloader .... )? If so, then it probably doesn't belong in python-modules. See https://github.com/NixOS/nixpkgs/blob/master/doc/languages-frameworks/python.section.md#buildpythonapplication-function

@mweinelt
Copy link
Member Author

mweinelt commented May 3, 2020

Ah yeah, that is probably the case. Thanks for the link.

@mweinelt mweinelt force-pushed the mweinelt:pr/tockloader branch from 434441b to d74a279 May 8, 2020
@mweinelt mweinelt changed the title pythonPackages.tockloader: init at v1.3.1 tockloader: init at v1.4.0 May 8, 2020
@mweinelt
Copy link
Member Author

mweinelt commented May 8, 2020

Ok, ready for review again.

meta = with lib; {
homepage = "https://github.com/tock/tockloader";
license = licenses.mit;
description = "Tool for programming Tock onto hardware boards.";

This comment has been minimized.

Copy link
@jonringer

jonringer May 9, 2020

Contributor

please add yourself as a maintainer :)

This comment has been minimized.

Copy link
@mweinelt

mweinelt May 9, 2020

Author Member

Fair, done!

@mweinelt mweinelt force-pushed the mweinelt:pr/tockloader branch from d74a279 to 70b9b71 May 9, 2020
Copy link
Contributor

doronbehar left a comment

Works as far as --help is concerned.

@Lassulus Lassulus merged commit fb13a1f into NixOS:master May 22, 2020
16 checks passed
16 checks passed
Evaluation Performance Report Evaluator Performance Report
Details
grahamcofborg-eval ^.^!
Details
grahamcofborg-eval-check-maintainers matching changed paths to changed attrs...
Details
grahamcofborg-eval-check-meta config.nix: checkMeta = true
Details
grahamcofborg-eval-darwin nix-instantiate --arg nixpkgs { outPath=./.; revCount=999999; shortRev="70b9b71"; rev="70b9b715c524152408a3a9f0efbef814960ad369"; } ./pkgs/t
Details
grahamcofborg-eval-lib-tests nix-build --arg pkgs import ./. {} ./lib/tests/release.nix
Details
grahamcofborg-eval-nixos nix-instantiate --arg nixpkgs { outPath=./.; revCount=999999; shortRev="70b9b71"; rev="70b9b715c524152408a3a9f0efbef814960ad369"; } ./nixos/
Details
grahamcofborg-eval-nixos-manual nix-instantiate --arg nixpkgs { outPath=./.; revCount=999999; shortRev="70b9b71"; rev="70b9b715c524152408a3a9f0efbef814960ad369"; } ./nixos/
Details
grahamcofborg-eval-nixos-options nix-instantiate --arg nixpkgs { outPath=./.; revCount=999999; shortRev="70b9b71"; rev="70b9b715c524152408a3a9f0efbef814960ad369"; } ./nixos/
Details
grahamcofborg-eval-nixpkgs-manual nix-instantiate --arg nixpkgs { outPath=./.; revCount=999999; shortRev="70b9b71"; rev="70b9b715c524152408a3a9f0efbef814960ad369"; } ./pkgs/t
Details
grahamcofborg-eval-nixpkgs-tarball nix-instantiate --arg nixpkgs { outPath=./.; revCount=999999; shortRev="70b9b71"; rev="70b9b715c524152408a3a9f0efbef814960ad369"; } ./pkgs/t
Details
grahamcofborg-eval-nixpkgs-unstable-jobset nix-instantiate --arg nixpkgs { outPath=./.; revCount=999999; shortRev="70b9b71"; rev="70b9b715c524152408a3a9f0efbef814960ad369"; } ./pkgs/t
Details
grahamcofborg-eval-package-list nix-env -qa --json --file .
Details
grahamcofborg-eval-package-list-no-aliases nix-env -qa --json --file . --arg config { allowAliases = false; }
Details
tockloader, tockloader.passthru.tests on aarch64-linux Success
Details
tockloader, tockloader.passthru.tests on x86_64-linux Success
Details
@mweinelt mweinelt deleted the mweinelt:pr/tockloader branch May 22, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Linked issues

Successfully merging this pull request may close these issues.

None yet

4 participants
You can’t perform that action at this time.