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

perlPackages.NetAsyncHTTP: init at 0.47 #102066

Merged
merged 1 commit into from Oct 30, 2020

Conversation

@zakame
Copy link
Member

@zakame zakame commented Oct 29, 2020

Motivation for this change

https://metacpan.org/pod/Net::Async::HTTP

This pure Perl module allows accessing HTTP using IO::Async, along with accessing HTTPS (when IO::Async::SSL is available.)

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.
@SuperSandro2000
Copy link
Member

@SuperSandro2000 SuperSandro2000 commented Oct 29, 2020

Result of nixpkgs-review pr 102066 run on x86_64-darwin 1

2 packages failed to build:
  • perl530Packages.NetAsyncHTTP
  • perl532Packages.NetAsyncHTTP
@nix { "action": "setPhase", "phase": "unpackPhase" }
unpacking sources
unpacking source archive /nix/store/irdsx7iwmpnpkl90fiaf1jb6qxn2bwjq-Net-Async-HTTP-0.47.tar.gz
source root is Net-Async-HTTP-0.47
setting SOURCE_DATE_EPOCH to timestamp 1589393854 of file Net-Async-HTTP-0.47/t/server.pem
@nix { "action": "setPhase", "phase": "patchPhase" }
patching sources
@nix { "action": "setPhase", "phase": "configurePhase" }
configuring
patching ./t/01request.t...
patching ./t/32remove.t...
patching ./t/00use.t...
patching ./t/70metrics.t...
patching ./t/81cross-https.t...
patching ./t/90rt75616.t...
patching ./t/23local-connect-redir.t...
patching ./t/24local-connect-redir-ssl.t...
patching ./t/91rt102547.t...
patching ./t/15conn-errors.t...
patching ./t/90rt93232.t...
patching ./t/08prepareprocess.t...
patching ./t/90rt75615.t...
patching ./t/18content-coding.t...
patching ./t/80cross-http.t...
patching ./t/14conn-max.t...
patching ./t/02uri.t...
patching ./t/22local-connect-pipeline.t...
patching ./t/19idle.t...
patching ./t/13conn-pipeline.t...
patching ./t/07continue.t...
patching ./t/16max-in-flight.t...
patching ./t/20local-connect.t...
patching ./t/12conn-persistence.t...
patching ./t/06close.t...
patching ./t/31cancel.t...
patching ./t/11response-streaming.t...
patching ./t/30timeout.t...
patching ./t/05redir.t...
patching ./t/40socks.t...
patching ./t/99pod.t...
patching ./t/90rt92904.t...
patching ./t/09cookies.t...
patching ./t/91rt100066.t...
patching ./t/10request-streaming.t...
patching ./t/04fail.t...
patching ./t/21local-connect-ssl.t...
patching ./t/03future.t...
patching ./t/regen-certs.sh...
patching ./t/90rt99142.t...
patching ./t/17on-write.t...
patching ./examples/PUT.pl...
patching ./examples/parallel-put.pl...
patching ./examples/GET.pl...
no configure script, doing nothing
@nix { "action": "setPhase", "phase": "buildPhase" }
building
Created MYMETA.yml and MYMETA.json
Creating new 'Build' script for 'Net-Async-HTTP' version '0.47'
Building Net-Async-HTTP
@nix { "action": "setPhase", "phase": "checkPhase" }
running tests
t/00use.t ...................... 
t/00use.t ...................... 1/? 
                                      
t/00use.t ...................... ok
t/01request.t .................. 
t/01request.t .................. 1/? 
                                        
t/01request.t .................. ok
t/02uri.t ...................... 
t/02uri.t ...................... 1/? 
                                       
t/02uri.t ...................... ok
t/03future.t ................... 
t/03future.t ................... 1/? 
                                      
t/03future.t ................... ok
t/04fail.t ..................... 
t/04fail.t ..................... 1/? 
                                       
t/04fail.t ..................... ok
t/05redir.t .................... 
t/05redir.t .................... 1/? 
t/05redir.t .................... 13/? 
                                       
t/05redir.t .................... ok
t/06close.t .................... 
t/06close.t .................... 1/? 
                                      
t/06close.t .................... ok
t/07continue.t ................. 
t/07continue.t ................. 1/? 
                                      
t/07continue.t ................. ok
t/08prepareprocess.t ........... 
t/08prepareprocess.t ........... 1/? 
                                      
t/08prepareprocess.t ........... ok
t/09cookies.t .................. 
t/09cookies.t .................. 1/? 
                                      
t/09cookies.t .................. ok
t/10request-streaming.t ........ 
t/10request-streaming.t ........ 1/? 
                                      
t/10request-streaming.t ........ ok
t/11response-streaming.t ....... 
t/11response-streaming.t ....... 1/? 
                                       
t/11response-streaming.t ....... ok
t/12conn-persistence.t ......... 
t/12conn-persistence.t ......... 1/? 
                                       
t/12conn-persistence.t ......... ok
t/13conn-pipeline.t ............ 
t/13conn-pipeline.t ............ 1/? 
                                       
t/13conn-pipeline.t ............ ok
t/14conn-max.t ................. 
t/14conn-max.t ................. 1/? 
                                      
t/14conn-max.t ................. ok
t/15conn-errors.t .............. 
t/15conn-errors.t .............. 1/? 
                                      
t/15conn-errors.t .............. ok
t/16max-in-flight.t ............ 
t/16max-in-flight.t ............ 1/? 
                                      
t/16max-in-flight.t ............ ok
t/17on-write.t ................. 
t/17on-write.t ................. 1/? 
                                      
t/17on-write.t ................. ok
t/18content-coding.t ........... # Using optional dependency Compress::Raw::Zlib 2.084

t/18content-coding.t ........... 1/? 
                                       
t/18content-coding.t ........... ok
t/19idle.t ..................... 
t/19idle.t ..................... 1/? 
                                      
t/19idle.t ..................... ok
t/20local-connect.t ............ Test failed early - Operation not permitted at t/20local-connect.t line 56.

                                   
t/20local-connect.t ............ Dubious, test returned 1 (wstat 256, 0x100)
No subtests run 
t/21local-connect-ssl.t ........ 
                                      
t/21local-connect-ssl.t ........ skipped: No IO::Async::SSL
t/22local-connect-pipeline.t ... Test failed early - Operation not permitted at t/22local-connect-pipeline.t line 55.

                                   
t/22local-connect-pipeline.t ... Dubious, test returned 1 (wstat 256, 0x100)
No subtests run 
t/23local-connect-redir.t ...... Test failed early - Operation not permitted at t/23local-connect-redir.t line 65.

                                   
t/23local-connect-redir.t ...... Dubious, test returned 1 (wstat 256, 0x100)
No subtests run 
t/24local-connect-redir-ssl.t .. 
                                      
t/24local-connect-redir-ssl.t .. skipped: No IO::Async::SSL
t/30timeout.t .................. 
t/30timeout.t .................. 1/? 
t/30timeout.t .................. 15/? 
                                       
t/30timeout.t .................. ok
t/31cancel.t ................... 
t/31cancel.t ................... 1/? 
                                      
t/31cancel.t ................... ok
t/32remove.t ................... 
t/32remove.t ................... 1/? 
                                      
t/32remove.t ................... ok
t/40socks.t .................... 
                                      
t/40socks.t .................... skipped: No Net::Async::SOCKS
t/70metrics.t .................. 
t/70metrics.t .................. 1/? 
                                      
t/70metrics.t .................. ok
t/80cross-http.t ............... 
                                      
t/80cross-http.t ............... skipped: Net::Async::HTTP::Server 0.03 is not available
t/81cross-https.t .............. 
                                      
t/81cross-https.t .............. skipped: Net::Async::HTTP::Server 0.06 is not available
t/90rt75615.t .................. Test failed early - Operation not permitted at t/90rt75615.t line 65.

                                   
t/90rt75615.t .................. Dubious, test returned 1 (wstat 256, 0x100)
No subtests run 
t/90rt75616.t .................. Test failed early - Operation not permitted at t/90rt75616.t line 65.

                                   
t/90rt75616.t .................. Dubious, test returned 1 (wstat 256, 0x100)
No subtests run 
t/90rt92904.t .................. 
t/90rt92904.t .................. 1/? 
                                      
t/90rt92904.t .................. ok
t/90rt93232.t .................. Cannot bind() - Operation not permitted
                                   
t/90rt93232.t .................. Dubious, test returned 1 (wstat 256, 0x100)
No subtests run 
t/90rt99142.t .................. 
t/90rt99142.t .................. 1/? 
                                      
t/90rt99142.t .................. ok
t/91rt100066.t ................. 
t/91rt100066.t ................. 1/? 
                                      
t/91rt100066.t ................. ok
t/91rt102547.t ................. 
t/91rt102547.t ................. 1/? 
                                      
t/91rt102547.t ................. ok
t/99pod.t ...................... 
                                      
t/99pod.t ...................... skipped: Test::Pod 1.00 required for testing POD

Test Summary Report
-------------------
t/20local-connect.t          (Wstat: 256 Tests: 0 Failed: 0)
  Non-zero exit status: 1
  Parse errors: No plan found in TAP output
t/22local-connect-pipeline.t (Wstat: 256 Tests: 0 Failed: 0)
  Non-zero exit status: 1
  Parse errors: No plan found in TAP output
t/23local-connect-redir.t    (Wstat: 256 Tests: 0 Failed: 0)
  Non-zero exit status: 1
  Parse errors: No plan found in TAP output
t/90rt75615.t                (Wstat: 256 Tests: 0 Failed: 0)
  Non-zero exit status: 1
  Parse errors: No plan found in TAP output
t/90rt75616.t                (Wstat: 256 Tests: 0 Failed: 0)
  Non-zero exit status: 1
  Parse errors: No plan found in TAP output
t/90rt93232.t                (Wstat: 256 Tests: 0 Failed: 0)
  Non-zero exit status: 1
  Parse errors: No plan found in TAP output
Files=40, Tests=519, 18 wallclock secs ( 0.19 usr  0.12 sys +  8.38 cusr  7.63 csys = 16.32 CPU)
Result: FAIL
Failed 6/40 test programs. 0/519 subtests failed.
@zakame
Copy link
Member Author

@zakame zakame commented Oct 29, 2020

Thanks - so similar issue to #102071 (comment)

I think I'll just disable network tests for here and on NetAsyncWebSocket entirely.

@zakame zakame force-pushed the zakame:contrib/perl-NetAsyncHTTP branch from 542b12b to 943642f Oct 29, 2020
@stigtsp
Copy link
Member

@stigtsp stigtsp commented Oct 30, 2020

I think I'll just disable network tests for here and on NetAsyncWebSocket entirely.

Is there a way to disable the network tests? It is rather nice to have at least some use_ok() tests to catch future breakage. :)

@zakame
Copy link
Member Author

@zakame zakame commented Oct 30, 2020

Maybe with some patching (e.g. plan skip_all unless ... on the test scripts needing network,) not sure how to do that here (yet) though :D

@stigtsp
Copy link
Member

@stigtsp stigtsp commented Oct 30, 2020

Maybe with some patching (e.g. plan skip_all unless ... on the test scripts needing network,) not sure how to do that here (yet) though :D

You can remove files for tests that are failing in t/ for instance:

  preCheck = stdenv.lib.optionalString stdenv.isDarwin ''
    rm t/foo.t t/bar.t
  '';

or, for quick patches, substituteInPlace is quite useful. There are a couple of examples in perl-packages.nix.

@zakame
Copy link
Member Author

@zakame zakame commented Oct 30, 2020

Awesome, let me try that 💪

@zakame zakame force-pushed the zakame:contrib/perl-NetAsyncHTTP branch from 943642f to 489c736 Oct 30, 2020
Copy link
Member

@stigtsp stigtsp left a comment

LGTM

Result of nixpkgs-review pr 102066 1

2 packages built:
  • perl530Packages.NetAsyncHTTP
  • perl532Packages.NetAsyncHTTP
@stigtsp
Copy link
Member

@stigtsp stigtsp commented Oct 30, 2020

@SuperSandro2000 Can you test on your Darwin?

@stigtsp
Copy link
Member

@stigtsp stigtsp commented Oct 30, 2020

@GrahamcOfBorg build perlPackages.NetAsyncHTTP perldevelPackages.NetAsyncHTTP

@SuperSandro2000
Copy link
Member

@SuperSandro2000 SuperSandro2000 commented Oct 30, 2020

Result of nixpkgs-review pr 102066 run on x86_64-darwin 1

2 packages built:
  • perl530Packages.NetAsyncHTTP
  • perl532Packages.NetAsyncHTTP
@stigtsp stigtsp merged commit 685c059 into NixOS:master Oct 30, 2020
19 checks passed
19 checks passed
@github-actions
tests
Details
@github-actions
action
Details
@ofborg
Evaluation Performance Report Evaluator Performance Report
Details
@github-actions
Wait for ofborg
Details
@ofborg
grahamcofborg-eval ^.^!
Details
@ofborg
grahamcofborg-eval-check-maintainers matching changed paths to changed attrs...
Details
@ofborg
grahamcofborg-eval-check-meta config.nix: checkMeta = true
Details
@ofborg
grahamcofborg-eval-darwin nix-instantiate --arg nixpkgs { outPath=./.; revCount=999999; shortRev="489c736"; rev="489c73671ab957fdbb547c9c175d2530fb0d307e"; } ./pkgs/t
Details
@ofborg
grahamcofborg-eval-lib-tests nix-build --arg pkgs import ./. {} ./lib/tests/release.nix
Details
@ofborg
grahamcofborg-eval-nixos nix-instantiate --arg nixpkgs { outPath=./.; revCount=999999; shortRev="489c736"; rev="489c73671ab957fdbb547c9c175d2530fb0d307e"; } ./nixos/
Details
@ofborg
grahamcofborg-eval-nixos-manual nix-instantiate --arg nixpkgs { outPath=./.; revCount=999999; shortRev="489c736"; rev="489c73671ab957fdbb547c9c175d2530fb0d307e"; } ./nixos/
Details
@ofborg
grahamcofborg-eval-nixos-options nix-instantiate --arg nixpkgs { outPath=./.; revCount=999999; shortRev="489c736"; rev="489c73671ab957fdbb547c9c175d2530fb0d307e"; } ./nixos/
Details
@ofborg
grahamcofborg-eval-nixpkgs-manual nix-instantiate --arg nixpkgs { outPath=./.; revCount=999999; shortRev="489c736"; rev="489c73671ab957fdbb547c9c175d2530fb0d307e"; } ./pkgs/t
Details
@ofborg
grahamcofborg-eval-nixpkgs-tarball nix-instantiate --arg nixpkgs { outPath=./.; revCount=999999; shortRev="489c736"; rev="489c73671ab957fdbb547c9c175d2530fb0d307e"; } ./pkgs/t
Details
@ofborg
grahamcofborg-eval-nixpkgs-unstable-jobset nix-instantiate --arg nixpkgs { outPath=./.; revCount=999999; shortRev="489c736"; rev="489c73671ab957fdbb547c9c175d2530fb0d307e"; } ./pkgs/t
Details
@ofborg
grahamcofborg-eval-package-list nix-env -qa --json --file .
Details
@ofborg
grahamcofborg-eval-package-list-no-aliases nix-env -qa --json --file . --arg config { allowAliases = false; }
Details
@ofborg
perlPackages.NetAsyncHTTP, perldevelPackages.NetAsyncHTTP on aarch64-linux Success
Details
@ofborg
perlPackages.NetAsyncHTTP, perldevelPackages.NetAsyncHTTP on x86_64-linux Success
Details
@zakame
Copy link
Member Author

@zakame zakame commented Oct 30, 2020

Thanks! 🎉

@zakame zakame deleted the zakame:contrib/perl-NetAsyncHTTP branch Oct 30, 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

3 participants