    # File lib/chef/provider/package/rubygems.rb, line 371
            def candidate_version
              @candidate_version ||= begin
                if target_version_already_installed?
                  nil
                elsif source_is_remote?
                  @gem_env.candidate_version_from_remote(gem_dependency, *gem_sources).to_s
                else
                  @gem_env.candidate_version_from_file(gem_dependency, @new_resource.source).to_s
                end
              end
            end