Cloud-CV/EvalAI

View on GitHub

Showing 1,371 of 1,371 total issues

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

Severity: Major
Found in apps/challenges/migrations/0102_challenge_ec2_storage.py and 3 other locations - About 2 hrs to fix
apps/challenges/migrations/0110_challenge_ephemeral_storage.py on lines 0..16
apps/challenges/migrations/0111_alter_challenge_ephemeral_storage_default.py on lines 0..16
apps/challenges/migrations/0112_challenge_sqs_retention_period.py on lines 0..16

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

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

    for participant_email in all_participants_email:
        if participant_email in challenge.banned_email_ids:
            message = "You're a part of {} team and it has been banned from this challenge. \
            Please contact the challenge host.".format(
                participant_team.team_name
Severity: Major
Found in apps/jobs/views.py and 3 other locations - About 2 hrs to fix
apps/jobs/views.py on lines 253..261
apps/jobs/views.py on lines 2775..2782
apps/jobs/views.py on lines 2891..2898

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

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

apps/challenges/migrations/0004_challenge_is_disabled.py on lines 0..16
apps/challenges/migrations/0009_challengephase_is_public.py on lines 0..16
apps/challenges/migrations/0025_added_is_submission_pubblic_field.py on lines 0..16
apps/challenges/migrations/0030_add_boolean_field_in_star_model.py on lines 0..16
apps/challenges/migrations/0053_added_is_registration_open_field.py on lines 0..16
apps/challenges/migrations/0055_add_is_leaderboard_order_descending_in_phase_split_model.py on lines 0..16
apps/challenges/migrations/0064_add_is_restricted_to_select_one_submission_field_in_phase_model.py on lines 0..18
apps/challenges/migrations/0066_added_is_partial_submission_evaluation_enabled_field_in_phase_model.py on lines 0..21
apps/challenges/migrations/0073_add_inform_hosts_field.py on lines 0..18
apps/jobs/migrations/0007_add_is_flagged_field.py on lines 0..16
apps/jobs/migrations/0011_Change_submission_visibility_default_to_public.py on lines 0..16
apps/jobs/migrations/0012_add_baseline_submission.py on lines 0..18
apps/jobs/migrations/0016_add_ignore_submission_boolean_field_in_submission_model.py on lines 0..16
apps/web/migrations/0005_modified_default_attribute_of_visible_field_to_false.py on lines 0..16

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

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

apps/challenges/migrations/0004_challenge_is_disabled.py on lines 0..16
apps/challenges/migrations/0009_challengephase_is_public.py on lines 0..16
apps/challenges/migrations/0025_added_is_submission_pubblic_field.py on lines 0..16
apps/challenges/migrations/0053_added_is_registration_open_field.py on lines 0..16
apps/challenges/migrations/0055_add_is_leaderboard_order_descending_in_phase_split_model.py on lines 0..16
apps/challenges/migrations/0058_add_show_leaderboard_by_latest_submission_field_in_challenge_phase_split_model.py on lines 0..21
apps/challenges/migrations/0064_add_is_restricted_to_select_one_submission_field_in_phase_model.py on lines 0..18
apps/challenges/migrations/0066_added_is_partial_submission_evaluation_enabled_field_in_phase_model.py on lines 0..21
apps/challenges/migrations/0073_add_inform_hosts_field.py on lines 0..18
apps/jobs/migrations/0007_add_is_flagged_field.py on lines 0..16
apps/jobs/migrations/0011_Change_submission_visibility_default_to_public.py on lines 0..16
apps/jobs/migrations/0012_add_baseline_submission.py on lines 0..18
apps/jobs/migrations/0016_add_ignore_submission_boolean_field_in_submission_model.py on lines 0..16
apps/web/migrations/0005_modified_default_attribute_of_visible_field_to_false.py on lines 0..16

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

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

apps/challenges/migrations/0035_add_max_concurrent_submissions_allowed_field.py on lines 0..16
apps/challenges/migrations/0046_add_max_concurrent_submission_evaluation_in_challenge.py on lines 0..18
apps/challenges/migrations/0056_add_leaderboard_decimal_precision_field_in_phase_split_model.py on lines 0..21
apps/web/migrations/0007_add_position_in_team_model.py on lines 0..16

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

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

apps/challenges/migrations/0004_challenge_is_disabled.py on lines 0..16
apps/challenges/migrations/0009_challengephase_is_public.py on lines 0..16
apps/challenges/migrations/0025_added_is_submission_pubblic_field.py on lines 0..16
apps/challenges/migrations/0030_add_boolean_field_in_star_model.py on lines 0..16
apps/challenges/migrations/0053_added_is_registration_open_field.py on lines 0..16
apps/challenges/migrations/0055_add_is_leaderboard_order_descending_in_phase_split_model.py on lines 0..16
apps/challenges/migrations/0058_add_show_leaderboard_by_latest_submission_field_in_challenge_phase_split_model.py on lines 0..21
apps/challenges/migrations/0064_add_is_restricted_to_select_one_submission_field_in_phase_model.py on lines 0..18
apps/challenges/migrations/0073_add_inform_hosts_field.py on lines 0..18
apps/jobs/migrations/0007_add_is_flagged_field.py on lines 0..16
apps/jobs/migrations/0011_Change_submission_visibility_default_to_public.py on lines 0..16
apps/jobs/migrations/0012_add_baseline_submission.py on lines 0..18
apps/jobs/migrations/0016_add_ignore_submission_boolean_field_in_submission_model.py on lines 0..16
apps/web/migrations/0005_modified_default_attribute_of_visible_field_to_false.py on lines 0..16

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

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

apps/challenges/migrations/0033_delete_unique_constraint_from_datasetsplit_table.py on lines 0..16
apps/challenges/migrations/0046_add_max_concurrent_submission_evaluation_in_challenge.py on lines 0..18
apps/challenges/migrations/0056_add_leaderboard_decimal_precision_field_in_phase_split_model.py on lines 0..21
apps/web/migrations/0007_add_position_in_team_model.py on lines 0..16

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

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

apps/challenges/migrations/0102_challenge_ec2_storage.py on lines 0..16
apps/challenges/migrations/0110_challenge_ephemeral_storage.py on lines 0..16
apps/challenges/migrations/0112_challenge_sqs_retention_period.py on lines 0..16

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

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

apps/challenges/migrations/0004_challenge_is_disabled.py on lines 0..16
apps/challenges/migrations/0025_added_is_submission_pubblic_field.py on lines 0..16
apps/challenges/migrations/0030_add_boolean_field_in_star_model.py on lines 0..16
apps/challenges/migrations/0053_added_is_registration_open_field.py on lines 0..16
apps/challenges/migrations/0055_add_is_leaderboard_order_descending_in_phase_split_model.py on lines 0..16
apps/challenges/migrations/0058_add_show_leaderboard_by_latest_submission_field_in_challenge_phase_split_model.py on lines 0..21
apps/challenges/migrations/0064_add_is_restricted_to_select_one_submission_field_in_phase_model.py on lines 0..18
apps/challenges/migrations/0066_added_is_partial_submission_evaluation_enabled_field_in_phase_model.py on lines 0..21
apps/challenges/migrations/0073_add_inform_hosts_field.py on lines 0..18
apps/jobs/migrations/0007_add_is_flagged_field.py on lines 0..16
apps/jobs/migrations/0011_Change_submission_visibility_default_to_public.py on lines 0..16
apps/jobs/migrations/0012_add_baseline_submission.py on lines 0..18
apps/jobs/migrations/0016_add_ignore_submission_boolean_field_in_submission_model.py on lines 0..16
apps/web/migrations/0005_modified_default_attribute_of_visible_field_to_false.py on lines 0..16

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

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

apps/challenges/migrations/0004_challenge_is_disabled.py on lines 0..16
apps/challenges/migrations/0009_challengephase_is_public.py on lines 0..16
apps/challenges/migrations/0025_added_is_submission_pubblic_field.py on lines 0..16
apps/challenges/migrations/0030_add_boolean_field_in_star_model.py on lines 0..16
apps/challenges/migrations/0053_added_is_registration_open_field.py on lines 0..16
apps/challenges/migrations/0058_add_show_leaderboard_by_latest_submission_field_in_challenge_phase_split_model.py on lines 0..21
apps/challenges/migrations/0064_add_is_restricted_to_select_one_submission_field_in_phase_model.py on lines 0..18
apps/challenges/migrations/0066_added_is_partial_submission_evaluation_enabled_field_in_phase_model.py on lines 0..21
apps/challenges/migrations/0073_add_inform_hosts_field.py on lines 0..18
apps/jobs/migrations/0007_add_is_flagged_field.py on lines 0..16
apps/jobs/migrations/0011_Change_submission_visibility_default_to_public.py on lines 0..16
apps/jobs/migrations/0012_add_baseline_submission.py on lines 0..18
apps/jobs/migrations/0016_add_ignore_submission_boolean_field_in_submission_model.py on lines 0..16
apps/web/migrations/0005_modified_default_attribute_of_visible_field_to_false.py on lines 0..16

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

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

Severity: Major
Found in apps/challenges/migrations/0004_challenge_is_disabled.py and 14 other locations - About 2 hrs to fix
apps/challenges/migrations/0009_challengephase_is_public.py on lines 0..16
apps/challenges/migrations/0025_added_is_submission_pubblic_field.py on lines 0..16
apps/challenges/migrations/0030_add_boolean_field_in_star_model.py on lines 0..16
apps/challenges/migrations/0053_added_is_registration_open_field.py on lines 0..16
apps/challenges/migrations/0055_add_is_leaderboard_order_descending_in_phase_split_model.py on lines 0..16
apps/challenges/migrations/0058_add_show_leaderboard_by_latest_submission_field_in_challenge_phase_split_model.py on lines 0..21
apps/challenges/migrations/0064_add_is_restricted_to_select_one_submission_field_in_phase_model.py on lines 0..18
apps/challenges/migrations/0066_added_is_partial_submission_evaluation_enabled_field_in_phase_model.py on lines 0..21
apps/challenges/migrations/0073_add_inform_hosts_field.py on lines 0..18
apps/jobs/migrations/0007_add_is_flagged_field.py on lines 0..16
apps/jobs/migrations/0011_Change_submission_visibility_default_to_public.py on lines 0..16
apps/jobs/migrations/0012_add_baseline_submission.py on lines 0..18
apps/jobs/migrations/0016_add_ignore_submission_boolean_field_in_submission_model.py on lines 0..16
apps/web/migrations/0005_modified_default_attribute_of_visible_field_to_false.py on lines 0..16

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

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

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

                if submissions_already_public.count() == 1:
                    # Case when the phase is restricted to make only one submission as public
                    submission_serializer = SubmissionSerializer(
                        submissions_already_public[0],
                        data={"is_public": False},
Severity: Major
Found in apps/jobs/views.py and 1 other location - About 2 hrs to fix
apps/jobs/views.py on lines 466..483

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

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

apps/challenges/migrations/0004_challenge_is_disabled.py on lines 0..16
apps/challenges/migrations/0009_challengephase_is_public.py on lines 0..16
apps/challenges/migrations/0025_added_is_submission_pubblic_field.py on lines 0..16
apps/challenges/migrations/0030_add_boolean_field_in_star_model.py on lines 0..16
apps/challenges/migrations/0055_add_is_leaderboard_order_descending_in_phase_split_model.py on lines 0..16
apps/challenges/migrations/0058_add_show_leaderboard_by_latest_submission_field_in_challenge_phase_split_model.py on lines 0..21
apps/challenges/migrations/0064_add_is_restricted_to_select_one_submission_field_in_phase_model.py on lines 0..18
apps/challenges/migrations/0066_added_is_partial_submission_evaluation_enabled_field_in_phase_model.py on lines 0..21
apps/challenges/migrations/0073_add_inform_hosts_field.py on lines 0..18
apps/jobs/migrations/0007_add_is_flagged_field.py on lines 0..16
apps/jobs/migrations/0011_Change_submission_visibility_default_to_public.py on lines 0..16
apps/jobs/migrations/0012_add_baseline_submission.py on lines 0..18
apps/jobs/migrations/0016_add_ignore_submission_boolean_field_in_submission_model.py on lines 0..16
apps/web/migrations/0005_modified_default_attribute_of_visible_field_to_false.py on lines 0..16

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

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

apps/challenges/migrations/0033_delete_unique_constraint_from_datasetsplit_table.py on lines 0..16
apps/challenges/migrations/0035_add_max_concurrent_submissions_allowed_field.py on lines 0..16
apps/challenges/migrations/0056_add_leaderboard_decimal_precision_field_in_phase_split_model.py on lines 0..21
apps/web/migrations/0007_add_position_in_team_model.py on lines 0..16

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

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

apps/challenges/migrations/0004_challenge_is_disabled.py on lines 0..16
apps/challenges/migrations/0009_challengephase_is_public.py on lines 0..16
apps/challenges/migrations/0025_added_is_submission_pubblic_field.py on lines 0..16
apps/challenges/migrations/0030_add_boolean_field_in_star_model.py on lines 0..16
apps/challenges/migrations/0053_added_is_registration_open_field.py on lines 0..16
apps/challenges/migrations/0055_add_is_leaderboard_order_descending_in_phase_split_model.py on lines 0..16
apps/challenges/migrations/0058_add_show_leaderboard_by_latest_submission_field_in_challenge_phase_split_model.py on lines 0..21
apps/challenges/migrations/0064_add_is_restricted_to_select_one_submission_field_in_phase_model.py on lines 0..18
apps/challenges/migrations/0066_added_is_partial_submission_evaluation_enabled_field_in_phase_model.py on lines 0..21
apps/challenges/migrations/0073_add_inform_hosts_field.py on lines 0..18
apps/jobs/migrations/0007_add_is_flagged_field.py on lines 0..16
apps/jobs/migrations/0012_add_baseline_submission.py on lines 0..18
apps/jobs/migrations/0016_add_ignore_submission_boolean_field_in_submission_model.py on lines 0..16
apps/web/migrations/0005_modified_default_attribute_of_visible_field_to_false.py on lines 0..16

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

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

apps/challenges/migrations/0004_challenge_is_disabled.py on lines 0..16
apps/challenges/migrations/0009_challengephase_is_public.py on lines 0..16
apps/challenges/migrations/0025_added_is_submission_pubblic_field.py on lines 0..16
apps/challenges/migrations/0030_add_boolean_field_in_star_model.py on lines 0..16
apps/challenges/migrations/0053_added_is_registration_open_field.py on lines 0..16
apps/challenges/migrations/0055_add_is_leaderboard_order_descending_in_phase_split_model.py on lines 0..16
apps/challenges/migrations/0058_add_show_leaderboard_by_latest_submission_field_in_challenge_phase_split_model.py on lines 0..21
apps/challenges/migrations/0066_added_is_partial_submission_evaluation_enabled_field_in_phase_model.py on lines 0..21
apps/challenges/migrations/0073_add_inform_hosts_field.py on lines 0..18
apps/jobs/migrations/0007_add_is_flagged_field.py on lines 0..16
apps/jobs/migrations/0011_Change_submission_visibility_default_to_public.py on lines 0..16
apps/jobs/migrations/0012_add_baseline_submission.py on lines 0..18
apps/jobs/migrations/0016_add_ignore_submission_boolean_field_in_submission_model.py on lines 0..16
apps/web/migrations/0005_modified_default_attribute_of_visible_field_to_false.py on lines 0..16

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

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 paginated_queryset(
    queryset, request, pagination_class=PageNumberPagination()
):
    """
    Return a paginated result for a queryset
Severity: Major
Found in apps/base/utils.py and 1 other location - About 2 hrs to fix
apps/base/utils.py on lines 42..51

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

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 team_paginated_queryset(
    queryset, request, pagination_class=PageNumberPagination()
):
    """
    Return a paginated result for a queryset
Severity: Major
Found in apps/base/utils.py and 1 other location - About 2 hrs to fix
apps/base/utils.py on lines 30..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 53.

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

apps/challenges/migrations/0104_challenge_evaluation_module_error.py on lines 0..16

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

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

apps/challenges/migrations/0108_alter_leaderboarddata_is_disabled_null.py on lines 0..16

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

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