You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
When creating a token using influxdb_auth, providing a permissions[].resource.name in addition to permissions[].resource.type, it fails with the following errors:
Error: Error in get call: undefined method `<<' for {:params=>{:name=>"bucketname"}}:Hash
Did you mean? <
Error: /opt/puppetlabs/puppet/cache/lib/puppet_x/puppetlabs/influxdb/influxdb.rb:91:in `influx_get' /opt/puppetlabs/puppet/cache/lib/puppet/provider/influxdb_auth/influxdb_auth.rb:74:in `block in create' /opt/puppetlabs/puppet/cache/lib/puppet/provider/influxdb_auth/influxdb_auth.rb:70:in `map' /opt/puppetlabs/puppet/cache/lib/puppet/provider/influxdb_auth/influxdb_auth.rb:70:in `create' /opt/puppetlabs/puppet/lib/ruby/vendor_gems/gems/puppet-resource_api-1.9.0/lib/puppet/resource_api/simple_provider.rb:41:in `block (2 levels) in set' /opt/puppetlabs/puppet/lib/ruby/vendor_gems/gems/puppet-resource_api-1.9.0/lib/puppet/resource_api/base_context.rb:67:in `block (2 levels) in <class:BaseContext>' /opt/puppetlabs/puppet/lib/ruby/vendor_gems/gems/puppet-resource_api-1.9.0/lib/puppet/resource_api/simple_provider.rb:40:in `block in set' /opt/puppetlabs/puppet/lib/ruby/vendor_gems/gems/puppet-resource_api-1.9.0/lib/puppet/resource_api/simple_provider.rb:13:in `each' /opt/puppetlabs/puppet/lib/ruby/vendor_gems/gems/puppet-resource_api-1.9.0/lib/puppet/resource_api/simple_provider.rb:13:in `set' /opt/puppetlabs/puppet/lib/ruby/vendor_gems/gems/puppet-resource_api-1.9.0/lib/puppet/resource_api.rb:342:in `flush' /opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/transaction/resource_harness.rb:25:in `evaluate' /opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/transaction.rb:267:in `apply' /opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/transaction.rb:288:in `eval_resource' /opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/transaction.rb:191:in `call' /opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/transaction.rb:191:in `block (2 levels) in evaluate' /opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/util.rb:567:in `block in thinmark' /opt/puppetlabs/puppet/lib/ruby/2.7.0/benchmark.rb:308:in `realtime' /opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/util.rb:566:in `thinmark' /opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/transaction.rb:191:in `block in evaluate' /opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/graph/relationship_graph.rb:122:in `traverse' /opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/transaction.rb:178:in `evaluate' /opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/resource/catalog.rb:238:in `block (2 levels) in apply' /opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/util.rb:567:in `block in thinmark' /opt/puppetlabs/puppet/lib/ruby/2.7.0/benchmark.rb:308:in `realtime' /opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/util.rb:566:in `thinmark' /opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/resource/catalog.rb:237:in `block in apply' /opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/util/log.rb:165:in `with_destination' /opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/transaction/report.rb:151:in `as_logging_destination' /opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/resource/catalog.rb:236:in `apply' /opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/configurer.rb:286:in `block (2 levels) in apply_catalog' /opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/util.rb:567:in `block in thinmark' /opt/puppetlabs/puppet/lib/ruby/2.7.0/benchmark.rb:308:in `realtime' /opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/util.rb:566:in `thinmark' /opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/configurer.rb:285:in `block in apply_catalog' /opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/util.rb:245:in `block in benchmark' /opt/puppetlabs/puppet/lib/ruby/2.7.0/benchmark.rb:308:in `realtime' /opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/util.rb:244:in `benchmark' /opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/configurer.rb:284:in `apply_catalog' /opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/configurer.rb:500:in `run_internal' /opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/configurer.rb:339:in `run' /opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/agent.rb:83:in `block (6 levels) in run' /opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/context.rb:62:in `override' /opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet.rb:289:in `override' /opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/agent.rb:82:in `block (5 levels) in run' /opt/puppetlabs/puppet/lib/ruby/2.7.0/timeout.rb:95:in `block in timeout' /opt/puppetlabs/puppet/lib/ruby/2.7.0/timeout.rb:105:in `timeout' /opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/agent.rb:81:in `block (4 levels) in run' /opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/agent/locker.rb:21:in `lock' /opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/agent.rb:71:in `block (3 levels) in run' /opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/agent.rb:162:in `with_client' /opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/agent.rb:67:in `block (2 levels) in run' /opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/agent.rb:127:in `run_in_fork' /opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/agent.rb:66:in `block in run' /opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/application.rb:172:in `controlled_run' /opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/agent.rb:47:in `run' /opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/application/agent.rb:433:in `onetime' /opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/application/agent.rb:393:in `block in run_command' /opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/context.rb:62:in `override' /opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet.rb:289:in `override' /opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/application/agent.rb:390:in `run_command' /opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/application.rb:421:in `block in run' /opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/util.rb:756:in `exit_on_fail' /opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/application.rb:421:in `run' /opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/util/command_line.rb:143:in `run' /opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/util/command_line.rb:77:in `execute' /opt/puppetlabs/puppet/bin/puppet:5:in `<main>'
Error: influxdb_auth[tokenname]: Creating: Error creating auth state: undefined method `key?' for []:Array
Error: influxdb_auth[tokenname]: Creating: ["/opt/puppetlabs/puppet/cache/lib/puppet/provider/influxdb_auth/influxdb_auth.rb:75:in `block in create'", "/opt/puppetlabs/puppet/cache/lib/puppet/provider/influxdb_auth/influxdb_auth.rb:70:in `map'", "/opt/puppetlabs/puppet/cache/lib/puppet/provider/influxdb_auth/influxdb_auth.rb:70:in `create'", "/opt/puppetlabs/puppet/lib/ruby/vendor_gems/gems/puppet-resource_api-1.9.0/lib/puppet/resource_api/simple_provider.rb:41:in `block (2 levels) in set'", "/opt/puppetlabs/puppet/lib/ruby/vendor_gems/gems/puppet-resource_api-1.9.0/lib/puppet/resource_api/base_context.rb:67:in `block (2 levels) in <class:BaseContext>'", "/opt/puppetlabs/puppet/lib/ruby/vendor_gems/gems/puppet-resource_api-1.9.0/lib/puppet/resource_api/simple_provider.rb:40:in `block in set'", "/opt/puppetlabs/puppet/lib/ruby/vendor_gems/gems/puppet-resource_api-1.9.0/lib/puppet/resource_api/simple_provider.rb:13:in `each'", "/opt/puppetlabs/puppet/lib/ruby/vendor_gems/gems/puppet-resource_api-1.9.0/lib/puppet/resource_api/simple_provider.rb:13:in `set'", "/opt/puppetlabs/puppet/lib/ruby/vendor_gems/gems/puppet-resource_api-1.9.0/lib/puppet/resource_api.rb:342:in `flush'", "/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/transaction/resource_harness.rb:25:in `evaluate'", "/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/transaction.rb:267:in `apply'", "/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/transaction.rb:288:in `eval_resource'", "/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/transaction.rb:191:in `call'", "/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/transaction.rb:191:in `block (2 levels) in evaluate'", "/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/util.rb:567:in `block in thinmark'", "/opt/puppetlabs/puppet/lib/ruby/2.7.0/benchmark.rb:308:in `realtime'", "/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/util.rb:566:in `thinmark'", "/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/transaction.rb:191:in `block in evaluate'", "/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/graph/relationship_graph.rb:122:in `traverse'", "/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/transaction.rb:178:in `evaluate'", "/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/resource/catalog.rb:238:in `block (2 levels) in apply'", "/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/util.rb:567:in `block in thinmark'", "/opt/puppetlabs/puppet/lib/ruby/2.7.0/benchmark.rb:308:in `realtime'", "/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/util.rb:566:in `thinmark'", "/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/resource/catalog.rb:237:in `block in apply'", "/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/util/log.rb:165:in `with_destination'", "/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/transaction/report.rb:151:in `as_logging_destination'", "/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/resource/catalog.rb:236:in `apply'", "/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/configurer.rb:286:in `block (2 levels) in apply_catalog'", "/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/util.rb:567:in `block in thinmark'", "/opt/puppetlabs/puppet/lib/ruby/2.7.0/benchmark.rb:308:in `realtime'", "/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/util.rb:566:in `thinmark'", "/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/configurer.rb:285:in `block in apply_catalog'", "/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/util.rb:245:in `block in benchmark'", "/opt/puppetlabs/puppet/lib/ruby/2.7.0/benchmark.rb:308:in `realtime'", "/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/util.rb:244:in `benchmark'", "/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/configurer.rb:284:in `apply_catalog'", "/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/configurer.rb:500:in `run_internal'", "/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/configurer.rb:339:in `run'", "/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/agent.rb:83:in `block (6 levels) in run'", "/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/context.rb:62:in `override'", "/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet.rb:289:in `override'", "/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/agent.rb:82:in `block (5 levels) in run'", "/opt/puppetlabs/puppet/lib/ruby/2.7.0/timeout.rb:95:in `block in timeout'", "/opt/puppetlabs/puppet/lib/ruby/2.7.0/timeout.rb:105:in `timeout'", "/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/agent.rb:81:in `block (4 levels) in run'", "/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/agent/locker.rb:21:in `lock'", "/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/agent.rb:71:in `block (3 levels) in run'", "/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/agent.rb:162:in `with_client'", "/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/agent.rb:67:in `block (2 levels) in run'", "/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/agent.rb:127:in `run_in_fork'", "/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/agent.rb:66:in `block in run'", "/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/application.rb:172:in `controlled_run'", "/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/agent.rb:47:in `run'", "/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/application/agent.rb:433:in `onetime'", "/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/application/agent.rb:393:in `block in run_command'", "/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/context.rb:62:in `override'", "/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet.rb:289:in `override'", "/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/application/agent.rb:390:in `run_command'", "/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/application.rb:421:in `block in run'", "/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/util.rb:756:in `exit_on_fail'", "/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/application.rb:421:in `run'", "/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/util/command_line.rb:143:in `run'", "/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/util/command_line.rb:77:in `execute'", "/opt/puppetlabs/puppet/bin/puppet:5:in `<main>'"]
Expected Behavior
The token gets created with the assigned permissions
Steps to Reproduce
Steps to reproduce the behavior:
Use this puppet module to manage influxdb, creating org my_org and bucket bucketname
Describe the Bug
When creating a token using
influxdb_auth
, providing apermissions[].resource.name
in addition topermissions[].resource.type
, it fails with the following errors:Expected Behavior
The token gets created with the assigned permissions
Steps to Reproduce
Steps to reproduce the behavior:
my_org
and bucketbucketname
Environment
Additional Context
This probably became a bug with c195e50. I'm creating a pull request, although I'm not currently able to learn how to include a proper test case.
The text was updated successfully, but these errors were encountered: