Showing 460 of 460 total issues

Similar blocks of code found in 9 locations. Consider refactoring.
Open

  module Compute
    class VcloudDirector
      class Real
        # Retrieve the value of the specified key from disk metadata.
        #
lib/fog/vcloud_director/requests/compute/get_catalog_item_metadata_item_metadata.rb on lines 2..21
lib/fog/vcloud_director/requests/compute/get_catalog_metadata_item_metadata.rb on lines 2..21
lib/fog/vcloud_director/requests/compute/get_media_metadata_item_metadata.rb on lines 2..21
lib/fog/vcloud_director/requests/compute/get_network_metadata_item_metadata.rb on lines 2..21
lib/fog/vcloud_director/requests/compute/get_vapp_metadata_item_metadata.rb on lines 2..21
lib/fog/vcloud_director/requests/compute/get_vapp_template_metadata_item_metadata.rb on lines 2..22
lib/fog/vcloud_director/requests/compute/get_vdc_metadata_item_metadata.rb on lines 2..23
lib/fog/vcloud_director/requests/compute/get_vdc_storage_class_metadata_item_metadata.rb on lines 2..20

Duplicated Code

Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

Tuning

This issue has a mass of 27.

We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

Refactorings

Further Reading

Similar blocks of code found in 9 locations. Consider refactoring.
Open

  module Compute
    class VcloudDirector
      class Real
        # Retrieve the value of the specified key from virtual datacenter
        # metadata.
lib/fog/vcloud_director/requests/compute/get_catalog_item_metadata_item_metadata.rb on lines 2..21
lib/fog/vcloud_director/requests/compute/get_catalog_metadata_item_metadata.rb on lines 2..21
lib/fog/vcloud_director/requests/compute/get_disk_metadata_item_metadata.rb on lines 2..21
lib/fog/vcloud_director/requests/compute/get_media_metadata_item_metadata.rb on lines 2..21
lib/fog/vcloud_director/requests/compute/get_network_metadata_item_metadata.rb on lines 2..21
lib/fog/vcloud_director/requests/compute/get_vapp_metadata_item_metadata.rb on lines 2..21
lib/fog/vcloud_director/requests/compute/get_vapp_template_metadata_item_metadata.rb on lines 2..22
lib/fog/vcloud_director/requests/compute/get_vdc_storage_class_metadata_item_metadata.rb on lines 2..20

Duplicated Code

Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

Tuning

This issue has a mass of 27.

We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

Refactorings

Further Reading

Similar blocks of code found in 2 locations. Consider refactoring.
Open

          begin
            response = @connection.request(params)
          rescue Excon::Errors::HTTPStatusError => error
            raise case error
            when Excon::Errors::NotFound
Severity: Minor
Found in lib/fog/bare_metal_cloud/compute.rb and 1 other location - About 20 mins to fix
lib/fog/dnsmadeeasy/dns.rb on lines 104..114

Duplicated Code

Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

Tuning

This issue has a mass of 27.

We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

Refactorings

Further Reading

Similar blocks of code found in 2 locations. Consider refactoring.
Open

          begin
            response = @connection.request(params)

          rescue Excon::Errors::HTTPStatusError => error
            raise case error
Severity: Minor
Found in lib/fog/dnsmadeeasy/dns.rb and 1 other location - About 20 mins to fix
lib/fog/bare_metal_cloud/compute.rb on lines 77..86

Duplicated Code

Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

Tuning

This issue has a mass of 27.

We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

Refactorings

Further Reading

Similar blocks of code found in 9 locations. Consider refactoring.
Open

  module Compute
    class VcloudDirector
      class Real
        # Retrieve the value of the specified key from catalog item metadata.
        #
lib/fog/vcloud_director/requests/compute/get_catalog_metadata_item_metadata.rb on lines 2..21
lib/fog/vcloud_director/requests/compute/get_disk_metadata_item_metadata.rb on lines 2..21
lib/fog/vcloud_director/requests/compute/get_media_metadata_item_metadata.rb on lines 2..21
lib/fog/vcloud_director/requests/compute/get_network_metadata_item_metadata.rb on lines 2..21
lib/fog/vcloud_director/requests/compute/get_vapp_metadata_item_metadata.rb on lines 2..21
lib/fog/vcloud_director/requests/compute/get_vapp_template_metadata_item_metadata.rb on lines 2..22
lib/fog/vcloud_director/requests/compute/get_vdc_metadata_item_metadata.rb on lines 2..23
lib/fog/vcloud_director/requests/compute/get_vdc_storage_class_metadata_item_metadata.rb on lines 2..20

Duplicated Code

Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

Tuning

This issue has a mass of 27.

We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

Refactorings

Further Reading

Similar blocks of code found in 9 locations. Consider refactoring.
Open

  module Compute
    class VcloudDirector
      class Real
        # Retrieve the value of the specified key from network metadata.
        #
lib/fog/vcloud_director/requests/compute/get_catalog_item_metadata_item_metadata.rb on lines 2..21
lib/fog/vcloud_director/requests/compute/get_catalog_metadata_item_metadata.rb on lines 2..21
lib/fog/vcloud_director/requests/compute/get_disk_metadata_item_metadata.rb on lines 2..21
lib/fog/vcloud_director/requests/compute/get_media_metadata_item_metadata.rb on lines 2..21
lib/fog/vcloud_director/requests/compute/get_vapp_metadata_item_metadata.rb on lines 2..21
lib/fog/vcloud_director/requests/compute/get_vapp_template_metadata_item_metadata.rb on lines 2..22
lib/fog/vcloud_director/requests/compute/get_vdc_metadata_item_metadata.rb on lines 2..23
lib/fog/vcloud_director/requests/compute/get_vdc_storage_class_metadata_item_metadata.rb on lines 2..20

Duplicated Code

Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

Tuning

This issue has a mass of 27.

We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

Refactorings

Further Reading

Similar blocks of code found in 9 locations. Consider refactoring.
Open

  module Compute
    class VcloudDirector
      class Real
        # Retrieve the value of the specified key from media object metadata.
        #
lib/fog/vcloud_director/requests/compute/get_catalog_item_metadata_item_metadata.rb on lines 2..21
lib/fog/vcloud_director/requests/compute/get_catalog_metadata_item_metadata.rb on lines 2..21
lib/fog/vcloud_director/requests/compute/get_disk_metadata_item_metadata.rb on lines 2..21
lib/fog/vcloud_director/requests/compute/get_network_metadata_item_metadata.rb on lines 2..21
lib/fog/vcloud_director/requests/compute/get_vapp_metadata_item_metadata.rb on lines 2..21
lib/fog/vcloud_director/requests/compute/get_vapp_template_metadata_item_metadata.rb on lines 2..22
lib/fog/vcloud_director/requests/compute/get_vdc_metadata_item_metadata.rb on lines 2..23
lib/fog/vcloud_director/requests/compute/get_vdc_storage_class_metadata_item_metadata.rb on lines 2..20

Duplicated Code

Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

Tuning

This issue has a mass of 27.

We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

Refactorings

Further Reading

Similar blocks of code found in 9 locations. Consider refactoring.
Open

  module Compute
    class VcloudDirector
      class Real
        # Retrieve metadata associated with the vDC storage profile.
        #
lib/fog/vcloud_director/requests/compute/get_catalog_item_metadata_item_metadata.rb on lines 2..21
lib/fog/vcloud_director/requests/compute/get_catalog_metadata_item_metadata.rb on lines 2..21
lib/fog/vcloud_director/requests/compute/get_disk_metadata_item_metadata.rb on lines 2..21
lib/fog/vcloud_director/requests/compute/get_media_metadata_item_metadata.rb on lines 2..21
lib/fog/vcloud_director/requests/compute/get_network_metadata_item_metadata.rb on lines 2..21
lib/fog/vcloud_director/requests/compute/get_vapp_metadata_item_metadata.rb on lines 2..21
lib/fog/vcloud_director/requests/compute/get_vapp_template_metadata_item_metadata.rb on lines 2..22
lib/fog/vcloud_director/requests/compute/get_vdc_metadata_item_metadata.rb on lines 2..23

Duplicated Code

Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

Tuning

This issue has a mass of 27.

We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

Refactorings

Further Reading

Similar blocks of code found in 9 locations. Consider refactoring.
Open

  module Compute
    class VcloudDirector
      class Real
        # Retrieve the value of the specified key from vApp template or VM
        # metadata.
lib/fog/vcloud_director/requests/compute/get_catalog_item_metadata_item_metadata.rb on lines 2..21
lib/fog/vcloud_director/requests/compute/get_catalog_metadata_item_metadata.rb on lines 2..21
lib/fog/vcloud_director/requests/compute/get_disk_metadata_item_metadata.rb on lines 2..21
lib/fog/vcloud_director/requests/compute/get_media_metadata_item_metadata.rb on lines 2..21
lib/fog/vcloud_director/requests/compute/get_network_metadata_item_metadata.rb on lines 2..21
lib/fog/vcloud_director/requests/compute/get_vapp_metadata_item_metadata.rb on lines 2..21
lib/fog/vcloud_director/requests/compute/get_vdc_metadata_item_metadata.rb on lines 2..23
lib/fog/vcloud_director/requests/compute/get_vdc_storage_class_metadata_item_metadata.rb on lines 2..20

Duplicated Code

Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

Tuning

This issue has a mass of 27.

We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

Refactorings

Further Reading

Similar blocks of code found in 9 locations. Consider refactoring.
Open

  module Compute
    class VcloudDirector
      class Real
        # Retrieve the value of the specified key from vApp or VM metadata.
        #
lib/fog/vcloud_director/requests/compute/get_catalog_item_metadata_item_metadata.rb on lines 2..21
lib/fog/vcloud_director/requests/compute/get_catalog_metadata_item_metadata.rb on lines 2..21
lib/fog/vcloud_director/requests/compute/get_disk_metadata_item_metadata.rb on lines 2..21
lib/fog/vcloud_director/requests/compute/get_media_metadata_item_metadata.rb on lines 2..21
lib/fog/vcloud_director/requests/compute/get_network_metadata_item_metadata.rb on lines 2..21
lib/fog/vcloud_director/requests/compute/get_vapp_template_metadata_item_metadata.rb on lines 2..22
lib/fog/vcloud_director/requests/compute/get_vdc_metadata_item_metadata.rb on lines 2..23
lib/fog/vcloud_director/requests/compute/get_vdc_storage_class_metadata_item_metadata.rb on lines 2..20

Duplicated Code

Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

Tuning

This issue has a mass of 27.

We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

Refactorings

Further Reading

Similar blocks of code found in 9 locations. Consider refactoring.
Open

  module Compute
    class VcloudDirector
      class Real
        # Retrieve the value of the specified key from catalog metadata.
        #
lib/fog/vcloud_director/requests/compute/get_catalog_item_metadata_item_metadata.rb on lines 2..21
lib/fog/vcloud_director/requests/compute/get_disk_metadata_item_metadata.rb on lines 2..21
lib/fog/vcloud_director/requests/compute/get_media_metadata_item_metadata.rb on lines 2..21
lib/fog/vcloud_director/requests/compute/get_network_metadata_item_metadata.rb on lines 2..21
lib/fog/vcloud_director/requests/compute/get_vapp_metadata_item_metadata.rb on lines 2..21
lib/fog/vcloud_director/requests/compute/get_vapp_template_metadata_item_metadata.rb on lines 2..22
lib/fog/vcloud_director/requests/compute/get_vdc_metadata_item_metadata.rb on lines 2..23
lib/fog/vcloud_director/requests/compute/get_vdc_storage_class_metadata_item_metadata.rb on lines 2..20

Duplicated Code

Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

Tuning

This issue has a mass of 27.

We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

Refactorings

Further Reading

Similar blocks of code found in 4 locations. Consider refactoring.
Open

      class Real
        # Retrieve a media object.
        #
        # @param [String] id Object identifier of the media object.
        # @return [Excon::Response]
Severity: Minor
Found in lib/fog/vcloud_director/requests/compute/get_media.rb and 3 other locations - About 15 mins to fix
lib/fog/vcloud_director/requests/compute/get_catalog.rb on lines 4..24
lib/fog/vcloud_director/requests/compute/get_organization.rb on lines 4..24
lib/fog/vcloud_director/requests/compute/get_vapp.rb on lines 4..22

Duplicated Code

Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

Tuning

This issue has a mass of 26.

We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

Refactorings

Further Reading

Similar blocks of code found in 2 locations. Consider refactoring.
Open

          if options[:rage4_url]
            uri = URI.parse(options[:rage4_url])
            options[:host]    = uri.host
            options[:port]    = uri.port
            options[:scheme]  = uri.scheme
Severity: Minor
Found in lib/fog/rage4/dns.rb and 1 other location - About 15 mins to fix
lib/fog/dreamhost/dns.rb on lines 46..50

Duplicated Code

Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

Tuning

This issue has a mass of 26.

We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

Refactorings

Further Reading

Similar blocks of code found in 4 locations. Consider refactoring.
Open

      class Real
        # Retrieve a catalog.
        #
        # @param [String] id Object identifier of the catalog.
        # @return [Excon::Response]
Severity: Minor
Found in lib/fog/vcloud_director/requests/compute/get_catalog.rb and 3 other locations - About 15 mins to fix
lib/fog/vcloud_director/requests/compute/get_media.rb on lines 4..24
lib/fog/vcloud_director/requests/compute/get_organization.rb on lines 4..24
lib/fog/vcloud_director/requests/compute/get_vapp.rb on lines 4..22

Duplicated Code

Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

Tuning

This issue has a mass of 26.

We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

Refactorings

Further Reading

Similar blocks of code found in 3 locations. Consider refactoring.
Open

      class Real
        # Retrieve a question being asked by a VM.
        #
        # @param [String] id Object identifier of the VM.
        # @return [Excon::Response]
lib/fog/vcloud_director/requests/compute/get_vapp_metadata.rb on lines 4..22
lib/fog/vcloud_director/requests/compute/get_vms_disk_attached_to.rb on lines 4..22

Duplicated Code

Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

Tuning

This issue has a mass of 26.

We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

Refactorings

Further Reading

Similar blocks of code found in 2 locations. Consider refactoring.
Open

  module DNS
    class DNSMadeEasy
      class Real
        # Modifies a secondary entry with the specified name. Returns errors if name is not valid or conflicts with another domain.
        #
Severity: Minor
Found in lib/fog/dnsmadeeasy/requests/dns/update_secondary.rb and 1 other location - About 15 mins to fix
lib/fog/dnsmadeeasy/requests/dns/create_secondary.rb on lines 2..28

Duplicated Code

Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

Tuning

This issue has a mass of 26.

We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

Refactorings

Further Reading

Similar blocks of code found in 2 locations. Consider refactoring.
Open

      class Mock
        def linode_disk_create(linode_id, name, type, size)
          response = Excon::Response.new
          response.status = 200
          response.body = {
Severity: Minor
Found in lib/fog/linode/requests/compute/linode_disk_create.rb and 1 other location - About 15 mins to fix
lib/fog/linode/requests/compute/linode_disk_createfromdistribution.rb on lines 21..31

Duplicated Code

Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

Tuning

This issue has a mass of 26.

We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

Refactorings

Further Reading

Similar blocks of code found in 3 locations. Consider refactoring.
Open

      class Real
        # List all linodes user has access or delete to
        #
        # ==== Parameters
        # * linodeId<~Integer>: Limit the list to the specified LinodeID
Severity: Minor
Found in lib/fog/linode/requests/compute/linode_list.rb and 2 other locations - About 15 mins to fix
lib/fog/linode/requests/compute/avail_distributions.rb on lines 4..23
lib/fog/linode/requests/dns/domain_list.rb on lines 4..35

Duplicated Code

Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

Tuning

This issue has a mass of 26.

We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

Refactorings

Further Reading

Similar blocks of code found in 2 locations. Consider refactoring.
Open

  module DNS
    class DNSMadeEasy
      class Real
        # Creates a secondary entry with the specified name. Returns errors if name is not valid or conflicts with another domain.
        #
Severity: Minor
Found in lib/fog/dnsmadeeasy/requests/dns/create_secondary.rb and 1 other location - About 15 mins to fix
lib/fog/dnsmadeeasy/requests/dns/update_secondary.rb on lines 2..28

Duplicated Code

Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

Tuning

This issue has a mass of 26.

We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

Refactorings

Further Reading

Similar blocks of code found in 2 locations. Consider refactoring.
Open

            xml += "<ovf:Property ovf:userConfigurable='#{section[:user_configurable]}' ovf:type='#{section[:type]}' ovf:password='#{section[:password]}' ovf:key='#{section[:id]}' ovf:value='#{section[:value]}'>"
lib/fog/vcloud_director/generators/compute/disks.rb on lines 157..162

Duplicated Code

Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

Tuning

This issue has a mass of 26.

We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

Refactorings

Further Reading

Severity
Category
Status
Source
Language