Azure/azure-sdk-for-ruby

issues with Azure container registry gem

tbugfinder opened this issue · 8 comments

Hi,

could you provide an example on how to get / search / list an Azure container registry within a given resource group?

Thanks

Maybe you can check this file as an example.

I'm also wondering about this difference.

### Compute
irb(main):074:0> Azure::Compute::Profiles::V2018_03_01::Mgmt::Client
=> Azure::Compute::Profiles::V2018_03_01::Mgmt::Client
irb(main):075:0>

## ContainerRegistry
## Tried different versions though, not hitting the appropriate, yet.
irb(main):081:0> Azure::ContainerRegistry::Profiles::V2017_10_01::Mgmt::Client
Traceback (most recent call last):
       16: from /test/ruby/gems/2.6.0/gems/bundler-2.0.1/exe/bundle:30:in `block in <top (required)>'
       15: from /test/ruby/gems/2.6.0/gems/bundler-2.0.1/lib/bundler/cli.rb:18:in `start'
       14: from /test/ruby/gems/2.6.0/gems/bundler-2.0.1/lib/bundler/vendor/thor/lib/thor/base.rb:466:in `start'
       13: from /test/ruby/gems/2.6.0/gems/bundler-2.0.1/lib/bundler/cli.rb:27:in `dispatch'
       12: from /test/ruby/gems/2.6.0/gems/bundler-2.0.1/lib/bundler/vendor/thor/lib/thor.rb:387:in `dispatch'
       11: from /test/ruby/gems/2.6.0/gems/bundler-2.0.1/lib/bundler/vendor/thor/lib/thor/invocation.rb:126:in `invoke_command'
       10: from /test/ruby/gems/2.6.0/gems/bundler-2.0.1/lib/bundler/vendor/thor/lib/thor/command.rb:27:in `run'
        9: from /test/ruby/gems/2.6.0/gems/bundler-2.0.1/lib/bundler/cli.rb:463:in `exec'
        8: from /test/ruby/gems/2.6.0/gems/bundler-2.0.1/lib/bundler/cli/exec.rb:28:in `run'
        7: from /test/ruby/gems/2.6.0/gems/bundler-2.0.1/lib/bundler/cli/exec.rb:74:in `kernel_load'
        6: from /test/ruby/gems/2.6.0/gems/bundler-2.0.1/lib/bundler/cli/exec.rb:74:in `load'
        5: from /home/user/vendor/bundle/ruby/2.6.0/bin/irb:23:in `<top (required)>'
        4: from /home/user/vendor/bundle/ruby/2.6.0/bin/irb:23:in `load'
        3: from /home/user/vendor/bundle/ruby/2.6.0/gems/irb-1.2.7/exe/irb:11:in `<top (required)>'
        2: from (irb):80
        1: from (irb):81:in `rescue in irb_binding'
NameError (uninitialized constant Azure::ContainerRegistry::Profiles::V2017_10_01)
irb(main):082:0>

Hi @myronfanqiu
sorry to bother you once more. Do you have any clue what's wrong here?

I did some search within the repo azure-rest-api-specs.
It looks like not all versions (in API specs) have the method I'm looking for. Some versions in between lack it.
https://github.com/Azure/azure-rest-api-specs/search?q=%22lists+all+the+container+registries+under+the+specified+resource%22
As the latest reference within this Azure::ContainerRegistry in azure-sdk-for-ruby doesn't point to version 2019-05-01 nor uses 2019-12-01-preview the method isn't there.

Would you kindly update the ruby-sdk matching current API specs?

Is it recommended to point latest to a non-stable version?

Anybody could rebuild the code for Azure::ContainerRegistry maybe including updated API versions?
I'm also wondering which patched autorest.ruby version you are using or which options are being used.

Thank you for your interest in Azure SDKs. As detailed in this retirement announcement, this repo is no longer supported as of December 31st 2021. Please find the up-to-date list of languages and services supported with Azure SDKs here: https://aka.ms/azsdk