ninech / netbox-client-ruby

A ruby client library for Netbox v2.
MIT License
24 stars 21 forks source link

Use new dry-configurable api 'default:' #50

Closed ahmeij closed 2 years ago

ahmeij commented 2 years ago

The dry-configurable gem has been updated with a new preferred API, it is now throwing deprecation warnings like this:

dry-configurable-0.13.0/lib/dry/configurable/dsl.rb:28:in `initialize' [dry-configurable] default value as positional argument to settings is deprecated and will be removed in the next major version
Provide a `default:` keyword argument instead

This pull-request implements the new syntax.

lukassup commented 2 years ago

@thde ping?

thde commented 2 years ago

Wouldn't this make it incompatible to users who are using an older version of dry-configurable? If so the netbox-client-ruby.gemspecwould need to be changed accordingly.

lukassup commented 2 years ago

I think we can pin dependency dry-configurable~>0.13.0 and release a new gem version so users who upgrade would require the updated version

thde commented 2 years ago

I'm happy to merge it, if you find the time to create a PR. Sadly I won't be able to do it myself.

lukassup commented 2 years ago

Whats the release process? Merge this PR to master, then bump Gem version in a separate PR and will it build & release automatically with CI or ...?

thde commented 2 years ago

I can do the release. Just create a MR with the current commits and the change to the netbox-client-ruby.gemspec :).

lukassup commented 2 years ago

@thde are you going to merge this PR first? And then do the release?

thde commented 2 years ago

I won't be able to merge this MR, as it doesn't include the changes to the .gemspec file. If you're willing to create a new one includeing the changes in this MR and to the .gemspec file, I'm happy to merge and release.