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

error installing from CPAN #176

Open
joenio opened this issue Jan 11, 2021 · 2 comments
Open

error installing from CPAN #176

joenio opened this issue Jan 11, 2021 · 2 comments
Milestone

Comments

@joenio
Copy link
Member

joenio commented Jan 11, 2021

many CPANTESTER error as can be checked below.

(1) CPANTESTER report error: http://www.cpantesters.org/cpan/report/74597ace-4f9d-11eb-adcb-77821f24ea8f

# Failed test 'In Then the output must match "[NAME|N^HNA^HAM^HME^HE]\s+analizo-graph"'
# at /opt/perl-5.30.3/lib/site_perl/5.30.3/Test/BDD/Cucumber/Executor.pm line 675.
#   in step at t/features/manpage-on-help.feature line 8.
#     ok - Starting to execute step: the output must match "[NAME|N^HNA^HAM^HME^HE]\s+analizo-graph"
#     not ok 1
#     #   Failed test at /home/cpansand/.cpan/build/2021010521/Analizo-1.25.1-7/t/features/step_definitions/analizo_steps.pl line 47.
#     #                   ''
#     #     doesn't match '(?^u:[NAME|N^HNA^HAM^HME^HE]\s+analizo-graph|\[NAME\|N\^HNA\^HAM\^HME\^HE\]\\s\+analizo\-graph)'
#     1..2
#     # Looks like you failed 1 test of 2.
Can't locate object method "todo_skip" via package "Test2::API::Context" at /opt/perl-5.30.3/lib/site_perl/5.30.3/Test/BDD/Cucumber/Harness/TAP.pm line 89.
A context appears to have been destroyed without first calling release().
Based on $@ it does not look like an exception was thrown (this is not always
a reliable test)

This is a problem because the global error variables ($!, $@, and $?) will
not be restored. In addition some release callbacks will not work properly from
inside a DESTROY method.

Here are the context creation details, just in case a tool forgot to call
release():
  File: /opt/perl-5.30.3/lib/site_perl/5.30.3/Test/BDD/Cucumber/Executor.pm
  Line: 806
  Tool: Test::BDD::Cucumber::Harness::TAP::step_done

Here is a trace to the code that caused the context to be destroyed, this could
be an exit(), a goto, or simply the end of a scope:
Context destroyed at /opt/perl-5.30.3/lib/site_perl/5.30.3/Test/BDD/Cucumber/Harness/TAP.pm line 89.
	eval {...} called at /opt/perl-5.30.3/lib/site_perl/5.30.3/Test/BDD/Cucumber/Harness/TAP.pm line 89
	Test::BDD::Cucumber::Harness::TAP::step_done(Test::BDD::Cucumber::Harness::TAP=HASH(0x55e3e9fc27e8), Test::BDD::Cucumber::StepContext=HASH(0x55e3eae9d060), Test::BDD::Cucumber::Model::Result=HASH(0x55e3e992a0b8)) called at /opt/perl-5.30.3/lib/site_perl/5.30.3/Test/BDD/Cucumber/Executor.pm line 806
	Test::BDD::Cucumber::Executor::skip_step(Test::BDD::Cucumber::Executor=HASH(0x55e3e9d643d8), Test::BDD::Cucumber::StepContext=HASH(0x55e3eae9d060), "pending", "Short-circuited from previous tests", 0) called at /opt/perl-5.30.3/lib/site_perl/5.30.3/Test/BDD/Cucumber/Executor.pm line 512
	Test::BDD::Cucumber::Executor::find_and_dispatch(Test::BDD::Cucumber::Executor=HASH(0x55e3e9d643d8), Test::BDD::Cucumber::StepContext=HASH(0x55e3eae9d060), 1, 0) called at /opt/perl-5.30.3/lib/site_perl/5.30.3/Test/BDD/Cucumber/Executor.pm line 338
	Test::BDD::Cucumber::Executor::_execute_steps(Test::BDD::Cucumber::Executor=HASH(0x55e3e9d643d8), HASH(0x55e3eae3d988)) called at /opt/perl-5.30.3/lib/site_perl/5.30.3/Test/BDD/Cucumber/Executor.pm line 436
	Test::BDD::Cucumber::Executor::execute_scenario(Test::BDD::Cucumber::Executor=HASH(0x55e3e9d643d8), HASH(0x55e3eaca5670)) called at /opt/perl-5.30.3/lib/site_perl/5.30.3/Test/BDD/Cucumber/Executor.pm line 256
	Test::BDD::Cucumber::Executor::execute_outline(Test::BDD::Cucumber::Executor=HASH(0x55e3e9d643d8), HASH(0x55e3eaca56a0)) called at /opt/perl-5.30.3/lib/site_perl/5.30.3/Test/BDD/Cucumber/Executor.pm line 175
	Test::BDD::Cucumber::Executor::execute(Test::BDD::Cucumber::Executor=HASH(0x55e3e9d643d8), Test::BDD::Cucumber::Model::Feature=HASH(0x55e3eacf6178), Test::BDD::Cucumber::Harness::TAP=HASH(0x55e3e9fc27e8)) called at t/features.t line 27

(2) CPANTESTER report error: http://www.cpantesters.org/cpan/report/206e0078-4f9e-11eb-8314-098f1f24ea8f

# Failed test 'In Then the output must match "I: Processed c."'
# at /opt/perl-5.16.3/lib/site_perl/5.16.3/Test/BDD/Cucumber/Executor.pm line 673.
#   in step at t/features/metrics-batch.feature line 9.
#     ok - Starting to execute step: the output must match "I: Processed c."
#     not ok 1
#     #   Failed test at /home/cpansand/.cpan/build/2021010521/Analizo-1.25.1-2/t/features/step_definitions/analizo_steps.pl line 47.
#     #                   ''
#     #     doesn't match '(?^u:I: Processed c.|I\:\ Processed\ c\.)'
#     1..2
#     # Looks like you failed 1 test of 2.
Can't locate object method "todo_skip" via package "Test2::API::Context" at /opt/perl-5.16.3/lib/site_perl/5.16.3/Test/BDD/Cucumber/Harness/TAP.pm line 89.
A context appears to have been destroyed without first calling release().
Based on $@ it does not look like an exception was thrown (this is not always
a reliable test)

This is a problem because the global error variables ($!, $@, and $?) will
not be restored. In addition some release callbacks will not work properly from
inside a DESTROY method.

Here are the context creation details, just in case a tool forgot to call
release():
  File: /opt/perl-5.16.3/lib/site_perl/5.16.3/Test/BDD/Cucumber/Executor.pm
  Line: 804
  Tool: Test::BDD::Cucumber::Harness::TAP::step_done

Here is a trace to the code that caused the context to be destroyed, this could
be an exit(), a goto, or simply the end of a scope:
Context destroyed at /opt/perl-5.16.3/lib/site_perl/5.16.3/Test/BDD/Cucumber/Harness/TAP.pm line 89.
	eval {...} called at /opt/perl-5.16.3/lib/site_perl/5.16.3/Test/BDD/Cucumber/Harness/TAP.pm line 89


Cleaning up the CONTEXT stack...
# Tests were run but no plan was declared and done_testing() was not seen.
# Looks like your test exited with 25 just after 3.
t/features.t ............................................................. 
Dubious, test returned 25 (wstat 6400, 0x1900)
Failed 1/3 subtests 

Test Summary Report
-------------------
t/features.t                                                           (Wstat: 6400 Tests: 3 Failed: 1)
  Failed test:  3
  Non-zero exit status: 25
  Parse errors: No plan found in TAP output

more CPANTESTER error related:

but going dive into this error it is possible to find the real problem that is on ChangeCost metric calculation, error below when running metrics-history:

cd t/samples/hello_world/
../../../bin/analizo metrics-history -p 2 -o ../parallel.csv

analizo metrics-history return the error below:

Can't locate object method "vertices" via package "Graph::TransitiveClosure::Matrix" at /home/vagrant/analizo/Analizo-1.25.1/lib/Analizo/GlobalMetric/ChangeCost.pm line 50.

It seems something related with new version 0.9716 of Graph module that changed the interface to build transitive matrix, but it needs more investigation to find the root of the problem...

@joenio joenio added this to the 1.25.2 milestone Jan 11, 2021
@joenio joenio self-assigned this Jan 11, 2021
joenio added a commit that referenced this issue Jul 20, 2022
it fixes the error below:
   Can't locate object method "vertices" via package "Graph::TransitiveClosure::Matrix"
   at /home/joenio/src/pkg-perl/packages/analizo/lib/Analizo/GlobalMetric/ChangeCost.pm line 56.

issue #########176
@joenio joenio modified the milestones: 1.25.2, 1.26.0 Aug 20, 2022
@joenio joenio removed their assignment Aug 21, 2023
@LeaoLuciano
Copy link
Contributor

It appears that different versions of the OS produce different tests to fail (http://matrix.cpantesters.org/?dist=Analizo%201.25.4;perl=5.39.2;reports=1):

OS version: 6.2.0-26-generic
Failing tests:
image

OS version: 5.4.0-155-generic
Failing tests:
image

I've managed to create a Dockerfile (Dockerfile.zip) that produces similar tests to fail when running cpan report . :
image
But I haven't figured out what is going wrong yet ( but it's probably caused by missing or wrong version of dependencies).

@joenio
Copy link
Member Author

joenio commented Sep 22, 2023

Thanks @LeaoLuciano, I'll take a look on the Dockerfile to reproduce the error here in my side, that would help a lot to debug the issue.

@joenio joenio modified the milestones: 1.26.0, 1.27.0 Mar 8, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants