Showing 212 of 460 total issues

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

          if filter[:id].nil?
            netpool.info!(-2,-1,-1)
          elsif filter[:id]
            filter[:id] = filter[:id].to_i if filter[:id].is_a?(String)
            netpool.info!(-2, filter[:id], filter[:id])
Severity: Minor
Found in lib/fog/opennebula/requests/compute/list_networks.rb and 1 other location - About 40 mins to fix
lib/fog/opennebula/requests/compute/template_pool.rb on lines 36..41

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 37.

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

        def get_vapp_owner(id)

          type = 'application/vnd.vmware.vcloud.owner+xml'

          unless vapp = data[:vapps][id]
Severity: Minor
Found in lib/fog/vcloud_director/requests/compute/get_vapp_owner.rb and 1 other location - About 35 mins to fix
lib/fog/vcloud_director/requests/compute/get_lease_settings_section_vapp.rb on lines 26..40

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 36.

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

        def get_lease_settings_section_vapp(id)

          type = 'application/vnd.vmware.vcloud.leaseSettingsSection+xml'

          unless vapp = data[:vapps][id]
lib/fog/vcloud_director/requests/compute/get_vapp_owner.rb on lines 25..39

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 36.

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 11 locations. Consider refactoring.
Open

                  {:OperatingSystemId=>"54",
                   :DefaultHardDiskAdapterType=>"3",
                   :MinimumHardDiskSizeGigabytes=>"8",
                   :MinimumMemoryMegabytes=>"32",
                   :Name=>"Other Linux (64-bit)",
lib/fog/vcloud_director/requests/compute/get_supported_systems_info.rb on lines 36..52
lib/fog/vcloud_director/requests/compute/get_supported_systems_info.rb on lines 53..69
lib/fog/vcloud_director/requests/compute/get_supported_systems_info.rb on lines 70..86
lib/fog/vcloud_director/requests/compute/get_supported_systems_info.rb on lines 90..106
lib/fog/vcloud_director/requests/compute/get_supported_systems_info.rb on lines 107..123
lib/fog/vcloud_director/requests/compute/get_supported_systems_info.rb on lines 124..140
lib/fog/vcloud_director/requests/compute/get_supported_systems_info.rb on lines 141..157
lib/fog/vcloud_director/requests/compute/get_supported_systems_info.rb on lines 175..191
lib/fog/vcloud_director/requests/compute/get_supported_systems_info.rb on lines 195..211
lib/fog/vcloud_director/requests/compute/get_supported_systems_info.rb on lines 212..228

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 35.

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 11 locations. Consider refactoring.
Open

                  {:OperatingSystemId=>"3",
                   :DefaultHardDiskAdapterType=>"4",
                   :MinimumHardDiskSizeGigabytes=>"40",
                   :MinimumMemoryMegabytes=>"512",
                   :Name=>"Microsoft Windows Server 2008 R2 (64-bit)",
lib/fog/vcloud_director/requests/compute/get_supported_systems_info.rb on lines 36..52
lib/fog/vcloud_director/requests/compute/get_supported_systems_info.rb on lines 70..86
lib/fog/vcloud_director/requests/compute/get_supported_systems_info.rb on lines 90..106
lib/fog/vcloud_director/requests/compute/get_supported_systems_info.rb on lines 107..123
lib/fog/vcloud_director/requests/compute/get_supported_systems_info.rb on lines 124..140
lib/fog/vcloud_director/requests/compute/get_supported_systems_info.rb on lines 141..157
lib/fog/vcloud_director/requests/compute/get_supported_systems_info.rb on lines 158..174
lib/fog/vcloud_director/requests/compute/get_supported_systems_info.rb on lines 175..191
lib/fog/vcloud_director/requests/compute/get_supported_systems_info.rb on lines 195..211
lib/fog/vcloud_director/requests/compute/get_supported_systems_info.rb on lines 212..228

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 35.

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 11 locations. Consider refactoring.
Open

                  {:OperatingSystemId=>"47",
                   :DefaultHardDiskAdapterType=>"3",
                   :MinimumHardDiskSizeGigabytes=>"8",
                   :MinimumMemoryMegabytes=>"64",
                   :Name=>"Ubuntu Linux (32-bit)",
lib/fog/vcloud_director/requests/compute/get_supported_systems_info.rb on lines 36..52
lib/fog/vcloud_director/requests/compute/get_supported_systems_info.rb on lines 53..69
lib/fog/vcloud_director/requests/compute/get_supported_systems_info.rb on lines 70..86
lib/fog/vcloud_director/requests/compute/get_supported_systems_info.rb on lines 90..106
lib/fog/vcloud_director/requests/compute/get_supported_systems_info.rb on lines 124..140
lib/fog/vcloud_director/requests/compute/get_supported_systems_info.rb on lines 141..157
lib/fog/vcloud_director/requests/compute/get_supported_systems_info.rb on lines 158..174
lib/fog/vcloud_director/requests/compute/get_supported_systems_info.rb on lines 175..191
lib/fog/vcloud_director/requests/compute/get_supported_systems_info.rb on lines 195..211
lib/fog/vcloud_director/requests/compute/get_supported_systems_info.rb on lines 212..228

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 35.

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 11 locations. Consider refactoring.
Open

                 [{:OperatingSystemId=>"85",
                   :DefaultHardDiskAdapterType=>"4",
                   :MinimumHardDiskSizeGigabytes=>"40",
                   :MinimumMemoryMegabytes=>"512",
                   :Name=>"Microsoft Windows Server 2012 (64-bit)",
lib/fog/vcloud_director/requests/compute/get_supported_systems_info.rb on lines 53..69
lib/fog/vcloud_director/requests/compute/get_supported_systems_info.rb on lines 70..86
lib/fog/vcloud_director/requests/compute/get_supported_systems_info.rb on lines 90..106
lib/fog/vcloud_director/requests/compute/get_supported_systems_info.rb on lines 107..123
lib/fog/vcloud_director/requests/compute/get_supported_systems_info.rb on lines 124..140
lib/fog/vcloud_director/requests/compute/get_supported_systems_info.rb on lines 141..157
lib/fog/vcloud_director/requests/compute/get_supported_systems_info.rb on lines 158..174
lib/fog/vcloud_director/requests/compute/get_supported_systems_info.rb on lines 175..191
lib/fog/vcloud_director/requests/compute/get_supported_systems_info.rb on lines 195..211
lib/fog/vcloud_director/requests/compute/get_supported_systems_info.rb on lines 212..228

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 35.

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 11 locations. Consider refactoring.
Open

                  {:OperatingSystemId=>"4",
                   :DefaultHardDiskAdapterType=>"4",
                   :MinimumHardDiskSizeGigabytes=>"40",
                   :MinimumMemoryMegabytes=>"512",
                   :Name=>"Microsoft Windows Server 2008 (32-bit)",
lib/fog/vcloud_director/requests/compute/get_supported_systems_info.rb on lines 36..52
lib/fog/vcloud_director/requests/compute/get_supported_systems_info.rb on lines 53..69
lib/fog/vcloud_director/requests/compute/get_supported_systems_info.rb on lines 90..106
lib/fog/vcloud_director/requests/compute/get_supported_systems_info.rb on lines 107..123
lib/fog/vcloud_director/requests/compute/get_supported_systems_info.rb on lines 124..140
lib/fog/vcloud_director/requests/compute/get_supported_systems_info.rb on lines 141..157
lib/fog/vcloud_director/requests/compute/get_supported_systems_info.rb on lines 158..174
lib/fog/vcloud_director/requests/compute/get_supported_systems_info.rb on lines 175..191
lib/fog/vcloud_director/requests/compute/get_supported_systems_info.rb on lines 195..211
lib/fog/vcloud_director/requests/compute/get_supported_systems_info.rb on lines 212..228

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 35.

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 11 locations. Consider refactoring.
Open

                  {:OperatingSystemId=>"49",
                   :DefaultHardDiskAdapterType=>"3",
                   :MinimumHardDiskSizeGigabytes=>"8",
                   :MinimumMemoryMegabytes=>"32",
                   :Name=>"Other 2.6.x Linux (32-bit)",
lib/fog/vcloud_director/requests/compute/get_supported_systems_info.rb on lines 36..52
lib/fog/vcloud_director/requests/compute/get_supported_systems_info.rb on lines 53..69
lib/fog/vcloud_director/requests/compute/get_supported_systems_info.rb on lines 70..86
lib/fog/vcloud_director/requests/compute/get_supported_systems_info.rb on lines 90..106
lib/fog/vcloud_director/requests/compute/get_supported_systems_info.rb on lines 107..123
lib/fog/vcloud_director/requests/compute/get_supported_systems_info.rb on lines 124..140
lib/fog/vcloud_director/requests/compute/get_supported_systems_info.rb on lines 158..174
lib/fog/vcloud_director/requests/compute/get_supported_systems_info.rb on lines 175..191
lib/fog/vcloud_director/requests/compute/get_supported_systems_info.rb on lines 195..211
lib/fog/vcloud_director/requests/compute/get_supported_systems_info.rb on lines 212..228

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 35.

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 11 locations. Consider refactoring.
Open

                 [{:OperatingSystemId=>"68",
                   :DefaultHardDiskAdapterType=>"3",
                   :MinimumHardDiskSizeGigabytes=>"8",
                   :MinimumMemoryMegabytes=>"32",
                   :Name=>"Other (64-bit)",
lib/fog/vcloud_director/requests/compute/get_supported_systems_info.rb on lines 36..52
lib/fog/vcloud_director/requests/compute/get_supported_systems_info.rb on lines 53..69
lib/fog/vcloud_director/requests/compute/get_supported_systems_info.rb on lines 70..86
lib/fog/vcloud_director/requests/compute/get_supported_systems_info.rb on lines 90..106
lib/fog/vcloud_director/requests/compute/get_supported_systems_info.rb on lines 107..123
lib/fog/vcloud_director/requests/compute/get_supported_systems_info.rb on lines 124..140
lib/fog/vcloud_director/requests/compute/get_supported_systems_info.rb on lines 141..157
lib/fog/vcloud_director/requests/compute/get_supported_systems_info.rb on lines 158..174
lib/fog/vcloud_director/requests/compute/get_supported_systems_info.rb on lines 175..191
lib/fog/vcloud_director/requests/compute/get_supported_systems_info.rb on lines 212..228

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 35.

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

              [{"name"=>"Small",
                "price"=>
                 {"pricePerQuantity"=>1,
                  "effectiveDate"=>-1,
                  "rate"=>0.0384,
Severity: Minor
Found in lib/fog/ibm/requests/storage/list_offerings.rb and 1 other location - About 35 mins to fix
lib/fog/ibm/requests/storage/list_offerings.rb on lines 54..66

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 35.

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

               {"name"=>"Small",
                "price"=>
                 {"pricePerQuantity"=>1,
                  "effectiveDate"=>-1,
                  "rate"=>0.0384,
Severity: Minor
Found in lib/fog/ibm/requests/storage/list_offerings.rb and 1 other location - About 35 mins to fix
lib/fog/ibm/requests/storage/list_offerings.rb on lines 41..53

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 35.

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 11 locations. Consider refactoring.
Open

                 [{:OperatingSystemId=>"48",
                   :DefaultHardDiskAdapterType=>"3",
                   :MinimumHardDiskSizeGigabytes=>"8",
                   :MinimumMemoryMegabytes=>"64",
                   :Name=>"Ubuntu Linux (64-bit)",
lib/fog/vcloud_director/requests/compute/get_supported_systems_info.rb on lines 36..52
lib/fog/vcloud_director/requests/compute/get_supported_systems_info.rb on lines 53..69
lib/fog/vcloud_director/requests/compute/get_supported_systems_info.rb on lines 70..86
lib/fog/vcloud_director/requests/compute/get_supported_systems_info.rb on lines 107..123
lib/fog/vcloud_director/requests/compute/get_supported_systems_info.rb on lines 124..140
lib/fog/vcloud_director/requests/compute/get_supported_systems_info.rb on lines 141..157
lib/fog/vcloud_director/requests/compute/get_supported_systems_info.rb on lines 158..174
lib/fog/vcloud_director/requests/compute/get_supported_systems_info.rb on lines 175..191
lib/fog/vcloud_director/requests/compute/get_supported_systems_info.rb on lines 195..211
lib/fog/vcloud_director/requests/compute/get_supported_systems_info.rb on lines 212..228

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 35.

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 11 locations. Consider refactoring.
Open

                  {:OperatingSystemId=>"50",
                   :DefaultHardDiskAdapterType=>"3",
                   :MinimumHardDiskSizeGigabytes=>"8",
                   :MinimumMemoryMegabytes=>"32",
                   :Name=>"Other 2.6.x Linux (64-bit)",
lib/fog/vcloud_director/requests/compute/get_supported_systems_info.rb on lines 36..52
lib/fog/vcloud_director/requests/compute/get_supported_systems_info.rb on lines 53..69
lib/fog/vcloud_director/requests/compute/get_supported_systems_info.rb on lines 70..86
lib/fog/vcloud_director/requests/compute/get_supported_systems_info.rb on lines 90..106
lib/fog/vcloud_director/requests/compute/get_supported_systems_info.rb on lines 107..123
lib/fog/vcloud_director/requests/compute/get_supported_systems_info.rb on lines 141..157
lib/fog/vcloud_director/requests/compute/get_supported_systems_info.rb on lines 158..174
lib/fog/vcloud_director/requests/compute/get_supported_systems_info.rb on lines 175..191
lib/fog/vcloud_director/requests/compute/get_supported_systems_info.rb on lines 195..211
lib/fog/vcloud_director/requests/compute/get_supported_systems_info.rb on lines 212..228

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 35.

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 11 locations. Consider refactoring.
Open

                  {:OperatingSystemId=>"67",
                   :DefaultHardDiskAdapterType=>"3",
                   :MinimumHardDiskSizeGigabytes=>"8",
                   :MinimumMemoryMegabytes=>"32",
                   :Name=>"Other (32-bit)",
lib/fog/vcloud_director/requests/compute/get_supported_systems_info.rb on lines 36..52
lib/fog/vcloud_director/requests/compute/get_supported_systems_info.rb on lines 53..69
lib/fog/vcloud_director/requests/compute/get_supported_systems_info.rb on lines 70..86
lib/fog/vcloud_director/requests/compute/get_supported_systems_info.rb on lines 90..106
lib/fog/vcloud_director/requests/compute/get_supported_systems_info.rb on lines 107..123
lib/fog/vcloud_director/requests/compute/get_supported_systems_info.rb on lines 124..140
lib/fog/vcloud_director/requests/compute/get_supported_systems_info.rb on lines 141..157
lib/fog/vcloud_director/requests/compute/get_supported_systems_info.rb on lines 158..174
lib/fog/vcloud_director/requests/compute/get_supported_systems_info.rb on lines 175..191
lib/fog/vcloud_director/requests/compute/get_supported_systems_info.rb on lines 195..211

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 35.

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 11 locations. Consider refactoring.
Open

                  {:OperatingSystemId=>"53",
                   :DefaultHardDiskAdapterType=>"3",
                   :MinimumHardDiskSizeGigabytes=>"8",
                   :MinimumMemoryMegabytes=>"32",
                   :Name=>"Other Linux (32-bit)",
lib/fog/vcloud_director/requests/compute/get_supported_systems_info.rb on lines 36..52
lib/fog/vcloud_director/requests/compute/get_supported_systems_info.rb on lines 53..69
lib/fog/vcloud_director/requests/compute/get_supported_systems_info.rb on lines 70..86
lib/fog/vcloud_director/requests/compute/get_supported_systems_info.rb on lines 90..106
lib/fog/vcloud_director/requests/compute/get_supported_systems_info.rb on lines 107..123
lib/fog/vcloud_director/requests/compute/get_supported_systems_info.rb on lines 124..140
lib/fog/vcloud_director/requests/compute/get_supported_systems_info.rb on lines 141..157
lib/fog/vcloud_director/requests/compute/get_supported_systems_info.rb on lines 158..174
lib/fog/vcloud_director/requests/compute/get_supported_systems_info.rb on lines 195..211
lib/fog/vcloud_director/requests/compute/get_supported_systems_info.rb on lines 212..228

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 35.

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

module Fog
  module Compute
    class IBM
      class Images < Fog::Collection
        model Fog::Compute::IBM::Image
Severity: Major
Found in lib/fog/ibm/models/compute/images.rb and 3 other locations - About 35 mins to fix
lib/fog/ibm/models/compute/locations.rb on lines 4..18
lib/fog/ibm/models/compute/servers.rb on lines 4..18
lib/fog/ibm/models/storage/volumes.rb on lines 4..18

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 34.

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

module Fog
  module Compute
    class IBM
      class Locations < Fog::Collection
        model Fog::Compute::IBM::Location
Severity: Major
Found in lib/fog/ibm/models/compute/locations.rb and 3 other locations - About 35 mins to fix
lib/fog/ibm/models/compute/images.rb on lines 4..18
lib/fog/ibm/models/compute/servers.rb on lines 4..18
lib/fog/ibm/models/storage/volumes.rb on lines 4..18

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 34.

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

module Fog
  module Compute
    class IBM
      class Servers < Fog::Collection
        model Fog::Compute::IBM::Server
Severity: Major
Found in lib/fog/ibm/models/compute/servers.rb and 3 other locations - About 35 mins to fix
lib/fog/ibm/models/compute/images.rb on lines 4..18
lib/fog/ibm/models/compute/locations.rb on lines 4..18
lib/fog/ibm/models/storage/volumes.rb on lines 4..18

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 34.

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

module Fog
  module Storage
    class IBM
      class Volumes < Fog::Collection
        model Fog::Storage::IBM::Volume
Severity: Major
Found in lib/fog/ibm/models/storage/volumes.rb and 3 other locations - About 35 mins to fix
lib/fog/ibm/models/compute/images.rb on lines 4..18
lib/fog/ibm/models/compute/locations.rb on lines 4..18
lib/fog/ibm/models/compute/servers.rb on lines 4..18

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 34.

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