dboehmer / Dancer2-Plugin-Swagger2

A Dancer2 plugin for creating routes from a Swagger2 spec
https://metacpan.org/pod/Dancer2::Plugin::Swagger2
3 stars 4 forks source link

Cannot build #13

Open cliveeisen opened 1 year ago

cliveeisen commented 1 year ago

I am trying to build and I get into a circular dependance hell I get as far (perl 5.16.3 have also tried later) as

Building and testing Mojolicious-Plugin-OpenAPI-3.41

(not sure why we need Mojolicious for Dancer2 but..)

Building and testing Mojolicious-Plugin-OpenAPI-3.41
! Installing JSON::Validator::OpenAPI::Mojolicious failed
PERL_DL_NONLAZY=1 "/usr/bin/perl" "-MExtUtils::Command::MM" "-MTest::Harness" "-e" "undef *Test::Harness::Switches; test_harness(0, 'blib/lib', 'blib/arch')" t/*.t
t/00-basic.t ........................... ok
Can't locate object method "_resolve" via package "JSON::Validator::OpenAPI::Mojolicious" at /root/.cpanm/work/1675010955.60704/Mojolicious-Plugin-OpenAPI-3.41/blib/lib/JSON/Validator/OpenAPI/Mojolicious.pm line 39.
t/basic-404-501.t ......................
Dubious, test returned 255 (wstat 65280, 0xff00)
No subtests run
Can't locate object method "_resolve" via package "JSON::Validator::OpenAPI::Mojolicious" at /root/.cpanm/work/1675010955.60704/Mojolicious-Plugin-OpenAPI-3.41/blib/lib/JSON/Validator/OpenAPI/Mojolicious.pm line 39.
t/basic-autorender.t ...................
Dubious, test returned 255 (wstat 65280, 0xff00)
No subtests run

#   Failed test 'bundled schema is valid'
#   at t/basic-bundle.t line 15.
#          got: 'Can't locate object method "_resolve" via package "JSON::Validator::OpenAPI::Mojolicious" at /root/.cpanm/work/1675010955.60704/Mojolicious-Plugin-OpenAPI-3.41/blib/lib/JSON/Validator/OpenAPI/Mojolicious.pm line 39.
# '
#     expected: ''
# Looks like you failed 1 test of 1.

Any ideas?

dboehmer commented 1 year ago

Sorry for the late reply. I have no definite answer but I should tell you what I know.

I built this module back in 2016 as part of a proof of concept for $work and since then I’ve done a bad job of keeping it up to date. To my defence you are the first external user to ever comment on this repo.

JSON::Validator which is a dependency of this module has made HUGE and breaking changes since then. You can try to build a JSON-Validator in a version from 2016 to get it working. https://metacpan.org/dist/JSON-Validator/changes

If you have demand for this module and current CPAN modules I might invest time into making a new version based on current JSON-Validator.

cliveeisen commented 1 year ago

Many thanks for the reply - I will give it another go with an older version of Validator.

I will let you know how it goes.

Regards,

— Clive Eisen GPG: 3818B5F1

On 26 Feb 2023, at 12:53, Daniel Böhmer @.***> wrote:

Sorry for the late reply. I have no definite answer but I should tell you what I know.

I built this module back in 2016 as part of a proof of concept for $work and since then I’ve done a bad job of keeping it up to date. To my defence you are the first external user to ever comment on this repo.

JSON::Validator which is a dependency of this module has made HUGE and breaking changes since then. You can try to build a JSON-Validator in a version from 2016 to get it working. https://metacpan.org/dist/JSON-Validator/changes

If you have demand for this module and current CPAN modules I might invest time into making a new version based on current JSON-Validator.

— Reply to this email directly, view it on GitHub https://github.com/dboehmer/Dancer2-Plugin-Swagger2/issues/13#issuecomment-1445354132, or unsubscribe https://github.com/notifications/unsubscribe-auth/AALSESQJ2JGPNQEFIOI6BNDWZNG3HANCNFSM6AAAAAAUKLFJ2A. You are receiving this because you authored the thread.

cliveeisen commented 1 year ago

Hi,

I gave it a good try but you end up gettingmore and more requirements that have changed over time

For example the 2016 version of Validator relies on Mojo::Util::slurp which does not now exit.

And I cant even download the version from back then that does. And I have no doubt that there will be many other issues.

If and when you find time to bring it up to date please let me know because I would love to use it.

If you don’t I completely understand how this all works ;-)

Regards,

— Clive Eisen GPG: 3818B5F1

On 26 Feb 2023, at 12:53, Daniel Böhmer @.***> wrote:

Sorry for the late reply. I have no definite answer but I should tell you what I know.

I built this module back in 2016 as part of a proof of concept for $work and since then I’ve done a bad job of keeping it up to date. To my defence you are the first external user to ever comment on this repo.

JSON::Validator which is a dependency of this module has made HUGE and breaking changes since then. You can try to build a JSON-Validator in a version from 2016 to get it working. https://metacpan.org/dist/JSON-Validator/changes

If you have demand for this module and current CPAN modules I might invest time into making a new version based on current JSON-Validator.

— Reply to this email directly, view it on GitHub https://github.com/dboehmer/Dancer2-Plugin-Swagger2/issues/13#issuecomment-1445354132, or unsubscribe https://github.com/notifications/unsubscribe-auth/AALSESQJ2JGPNQEFIOI6BNDWZNG3HANCNFSM6AAAAAAUKLFJ2A. You are receiving this because you authored the thread.