)]}'
{"lib/puppet/parser/functions/openstack_resource_id_getter.rb":[{"author":{"_account_id":13617,"name":"Danek Duvall","email":"danek.duvall@oracle.com","username":"dhduvall"},"change_message_id":"d457c858e68d18bb9e8d41712c623baf1d85eae1","unresolved":false,"context_lines":[{"line_number":22,"context_line":"      envhash \u003d argv[1]"},{"line_number":23,"context_line":"      if ! envhash.is_a?(Hash)"},{"line_number":24,"context_line":"        raise(Puppet::Error::OpenstackAuthInputError, \u0027The second argument must be"},{"line_number":25,"context_line":" a has of environment variables to use\u0027)"},{"line_number":26,"context_line":"      end"},{"line_number":27,"context_line":""},{"line_number":28,"context_line":"      if envhash.has_key?(\u0027OS_AUTH_URL\u0027)"}],"source_content_type":"text/x-ruby","patch_set":4,"id":"dada55a8_b992cb9d","line":25,"range":{"start_line":25,"start_character":3,"end_line":25,"end_character":6},"updated":"2016-07-22 17:35:39.000000000","message":"\"has\" should be \"hash\"?","commit_id":"51b6ee0aaa15a4625f4f93014bbefe0741393bc8"},{"author":{"_account_id":7745,"name":"Denis Egorenko","email":"degorenko@mirantis.com","username":"degorenko"},"change_message_id":"e9b46a373c77aa716ea0deed33f7ad6ca3af4a7a","unresolved":false,"context_lines":[{"line_number":3,"context_line":"require \u0027puppet/provider/openstack/credentials\u0027"},{"line_number":4,"context_line":""},{"line_number":5,"context_line":"module Puppet::Parser::Functions"},{"line_number":6,"context_line":"  newfunction(:openstack_resource_id_getter, :type \u003d\u003e :rvalue) do |argv|"},{"line_number":7,"context_line":"    resource_cmd \u003d argv[0]"},{"line_number":8,"context_line":""},{"line_number":9,"context_line":"    extend Puppet::Provider::Openstack::Auth"}],"source_content_type":"text/x-ruby","patch_set":5,"id":"dada55a8_342510c2","line":6,"updated":"2016-07-25 11:33:25.000000000","message":"i guess we can set arity to -2 here, at least one argument (command) should be passed","commit_id":"90a6e753fa5386511f3966ca6a697e95a7e9a8c4"},{"author":{"_account_id":7745,"name":"Denis Egorenko","email":"degorenko@mirantis.com","username":"degorenko"},"change_message_id":"e9b46a373c77aa716ea0deed33f7ad6ca3af4a7a","unresolved":false,"context_lines":[{"line_number":25,"context_line":" a hash of environment variables to use\u0027)"},{"line_number":26,"context_line":"      end"},{"line_number":27,"context_line":""},{"line_number":28,"context_line":"      if envhash.has_key?(\u0027OS_AUTH_URL\u0027)"},{"line_number":29,"context_line":"        @credentials \u003d Puppet::Provider::Openstack::CredentialsV2_0.new"},{"line_number":30,"context_line":"      else"},{"line_number":31,"context_line":"        @credentials \u003d Puppet::Provider::Openstack::CredentialsV3.new"}],"source_content_type":"text/x-ruby","patch_set":5,"id":"dada55a8_e82558ae","line":28,"updated":"2016-07-25 11:33:25.000000000","message":"not sure that it is best indicator for checking auth version,\n\nlet\u0027s use \u0027OS_IDENTITY_API_VERSION\u0027","commit_id":"90a6e753fa5386511f3966ca6a697e95a7e9a8c4"},{"author":{"_account_id":7745,"name":"Denis Egorenko","email":"degorenko@mirantis.com","username":"degorenko"},"change_message_id":"e9b46a373c77aa716ea0deed33f7ad6ca3af4a7a","unresolved":false,"context_lines":[{"line_number":32,"context_line":"      end"},{"line_number":33,"context_line":""},{"line_number":34,"context_line":"      set_credentials(@credentials, envhash)"},{"line_number":35,"context_line":"    end"},{"line_number":36,"context_line":""},{"line_number":37,"context_line":"    unless @credentials.set?"},{"line_number":38,"context_line":"      raise(Puppet::Error::OpenstackAuthInputError, \u0027Insufficient credentials to authenticate\u0027)"}],"source_content_type":"text/x-ruby","patch_set":5,"id":"dada55a8_2809302d","line":35,"updated":"2016-07-25 11:33:25.000000000","message":"also i guess we can add ability to specify openrc file.\n\nFrom my point of view, we can just try to do next:\n\n1) if auth hash is not passed:\n  a) try to auth with auth env;\n  b) try to auth with openrc file;\n2) if auth hash is passed:\n  a) try to auth with auth hash;\n\nThis will follow same approach with additional way (auth hash) as we have for providers.","commit_id":"90a6e753fa5386511f3966ca6a697e95a7e9a8c4"},{"author":{"_account_id":7745,"name":"Denis Egorenko","email":"degorenko@mirantis.com","username":"degorenko"},"change_message_id":"076a7e0ec1119d82cdd2a43c5e7c710816f0148b","unresolved":false,"context_lines":[{"line_number":40,"context_line":"    end"},{"line_number":41,"context_line":""},{"line_number":42,"context_line":"    env \u003d @credentials ? @credentials.to_env : {}"},{"line_number":43,"context_line":"    Puppet::Util.withenv(env) do"},{"line_number":44,"context_line":"      stdout \u003d `openstack #{resource_cmd} -f value -c id`"},{"line_number":45,"context_line":"      return stdout"},{"line_number":46,"context_line":"    end"},{"line_number":47,"context_line":"  end"},{"line_number":48,"context_line":"end"}],"source_content_type":"text/x-ruby","patch_set":6,"id":"dada55a8_50e04f96","line":45,"range":{"start_line":43,"start_character":1,"end_line":45,"end_character":19},"updated":"2016-07-26 12:09:09.000000000","message":"i have no idea how to stub this call in function tests :( may be others have some ideas","commit_id":"bd06e868ed247ef6d3842a9df040c991a3d58a4b"}]}
