fossasia/open-event-orga-server

View on GitHub

Showing 1,194 of 1,194 total issues

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

Severity: Major
Found in migrations/versions/4132f684e5f1_.py and 53 other locations - About 3 hrs to fix
migrations/versions/03ed49c73697_.py on lines 0..26
migrations/versions/04060417378c_.py on lines 0..26
migrations/versions/0d25e6904746_.py on lines 0..26
migrations/versions/0e5940f5bf43_.py on lines 0..26
migrations/versions/0ebd913edd27_.py on lines 0..26
migrations/versions/10136334dff5_.py on lines 0..26
migrations/versions/11143ed3e6fa_.py on lines 0..26
migrations/versions/149695270251_.py on lines 0..26
migrations/versions/16183eae08cb_.py on lines 0..26
migrations/versions/167379522d3d_.py on lines 0..26
migrations/versions/1a89015d90bd_.py on lines 0..26
migrations/versions/1c7e0ce885a6_.py on lines 0..26
migrations/versions/2339564f5dc7_.py on lines 0..26
migrations/versions/265d11072331_.py on lines 0..26
migrations/versions/27c4db7538ca_.py on lines 0..26
migrations/versions/2f9f90ee6e73_.py on lines 0..26
migrations/versions/34be8a5853bd_.py on lines 0..26
migrations/versions/3a9c159811ae_.py on lines 0..26
migrations/versions/3ddac4799fb1_.py on lines 0..26
migrations/versions/4e5dd0df14b5_.py on lines 0..26
migrations/versions/5aed7e80e00e_.py on lines 0..26
migrations/versions/63203fd4c3ea_.py on lines 0..26
migrations/versions/66c7787c546e_.py on lines 0..26
migrations/versions/673cf7219a71_.py on lines 0..26
migrations/versions/6f6b4b3a368d_.py on lines 0..26
migrations/versions/76617aa50e25_.py on lines 0..26
migrations/versions/784a1fc57171_.py on lines 0..26
migrations/versions/7871961f26f2_.py on lines 0..26
migrations/versions/7b359f067e8e_.py on lines 0..26
migrations/versions/8223e1b0c247_.py on lines 0..26
migrations/versions/83e0a28b1430_.py on lines 0..26
migrations/versions/840bc71025d6_.py on lines 0..26
migrations/versions/9ccc41444de6_.py on lines 0..26
migrations/versions/aa204a8b5743_.py on lines 0..26
migrations/versions/aa4b21539f5b_.py on lines 0..26
migrations/versions/abf206ef23a1_.py on lines 0..26
migrations/versions/ac0d73a95c0a_.py on lines 0..26
migrations/versions/ac2a9daf5a8e_.py on lines 0..26
migrations/versions/ad7f50c4afb5_.py on lines 0..26
migrations/versions/b723e2342f15_.py on lines 0..26
migrations/versions/c6b183975be9_.py on lines 0..26
migrations/versions/ca628ab9ac91_.py on lines 0..26
migrations/versions/cdba269e9de1_.py on lines 0..26
migrations/versions/d40a49824b53_.py on lines 0..26
migrations/versions/d73fc7833958_.py on lines 0..26
migrations/versions/dd97b5e8fa6b_.py on lines 0..26
migrations/versions/de41bffc4830_.py on lines 0..26
migrations/versions/df5729aed5d2_.py on lines 0..26
migrations/versions/e42e322f7ffb_.py on lines 0..26
migrations/versions/e8222a407dd5_.py on lines 0..26
migrations/versions/efa8f2dbf092_.py on lines 0..26
migrations/versions/f2b4430d9e57_.py on lines 0..26
migrations/versions/f873b99e5be3_.py on lines 0..26

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

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

Severity: Major
Found in migrations/versions/63203fd4c3ea_.py and 53 other locations - About 3 hrs to fix
migrations/versions/03ed49c73697_.py on lines 0..26
migrations/versions/04060417378c_.py on lines 0..26
migrations/versions/0d25e6904746_.py on lines 0..26
migrations/versions/0e5940f5bf43_.py on lines 0..26
migrations/versions/0ebd913edd27_.py on lines 0..26
migrations/versions/10136334dff5_.py on lines 0..26
migrations/versions/11143ed3e6fa_.py on lines 0..26
migrations/versions/149695270251_.py on lines 0..26
migrations/versions/16183eae08cb_.py on lines 0..26
migrations/versions/167379522d3d_.py on lines 0..26
migrations/versions/1a89015d90bd_.py on lines 0..26
migrations/versions/1c7e0ce885a6_.py on lines 0..26
migrations/versions/2339564f5dc7_.py on lines 0..26
migrations/versions/265d11072331_.py on lines 0..26
migrations/versions/27c4db7538ca_.py on lines 0..26
migrations/versions/2f9f90ee6e73_.py on lines 0..26
migrations/versions/34be8a5853bd_.py on lines 0..26
migrations/versions/3a9c159811ae_.py on lines 0..26
migrations/versions/3ddac4799fb1_.py on lines 0..26
migrations/versions/4132f684e5f1_.py on lines 0..26
migrations/versions/4e5dd0df14b5_.py on lines 0..26
migrations/versions/5aed7e80e00e_.py on lines 0..26
migrations/versions/66c7787c546e_.py on lines 0..26
migrations/versions/673cf7219a71_.py on lines 0..26
migrations/versions/6f6b4b3a368d_.py on lines 0..26
migrations/versions/76617aa50e25_.py on lines 0..26
migrations/versions/784a1fc57171_.py on lines 0..26
migrations/versions/7871961f26f2_.py on lines 0..26
migrations/versions/7b359f067e8e_.py on lines 0..26
migrations/versions/8223e1b0c247_.py on lines 0..26
migrations/versions/83e0a28b1430_.py on lines 0..26
migrations/versions/840bc71025d6_.py on lines 0..26
migrations/versions/9ccc41444de6_.py on lines 0..26
migrations/versions/aa204a8b5743_.py on lines 0..26
migrations/versions/aa4b21539f5b_.py on lines 0..26
migrations/versions/abf206ef23a1_.py on lines 0..26
migrations/versions/ac0d73a95c0a_.py on lines 0..26
migrations/versions/ac2a9daf5a8e_.py on lines 0..26
migrations/versions/ad7f50c4afb5_.py on lines 0..26
migrations/versions/b723e2342f15_.py on lines 0..26
migrations/versions/c6b183975be9_.py on lines 0..26
migrations/versions/ca628ab9ac91_.py on lines 0..26
migrations/versions/cdba269e9de1_.py on lines 0..26
migrations/versions/d40a49824b53_.py on lines 0..26
migrations/versions/d73fc7833958_.py on lines 0..26
migrations/versions/dd97b5e8fa6b_.py on lines 0..26
migrations/versions/de41bffc4830_.py on lines 0..26
migrations/versions/df5729aed5d2_.py on lines 0..26
migrations/versions/e42e322f7ffb_.py on lines 0..26
migrations/versions/e8222a407dd5_.py on lines 0..26
migrations/versions/efa8f2dbf092_.py on lines 0..26
migrations/versions/f2b4430d9e57_.py on lines 0..26
migrations/versions/f873b99e5be3_.py on lines 0..26

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

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

Severity: Major
Found in migrations/versions/167379522d3d_.py and 53 other locations - About 3 hrs to fix
migrations/versions/03ed49c73697_.py on lines 0..26
migrations/versions/04060417378c_.py on lines 0..26
migrations/versions/0d25e6904746_.py on lines 0..26
migrations/versions/0e5940f5bf43_.py on lines 0..26
migrations/versions/0ebd913edd27_.py on lines 0..26
migrations/versions/10136334dff5_.py on lines 0..26
migrations/versions/11143ed3e6fa_.py on lines 0..26
migrations/versions/149695270251_.py on lines 0..26
migrations/versions/16183eae08cb_.py on lines 0..26
migrations/versions/1a89015d90bd_.py on lines 0..26
migrations/versions/1c7e0ce885a6_.py on lines 0..26
migrations/versions/2339564f5dc7_.py on lines 0..26
migrations/versions/265d11072331_.py on lines 0..26
migrations/versions/27c4db7538ca_.py on lines 0..26
migrations/versions/2f9f90ee6e73_.py on lines 0..26
migrations/versions/34be8a5853bd_.py on lines 0..26
migrations/versions/3a9c159811ae_.py on lines 0..26
migrations/versions/3ddac4799fb1_.py on lines 0..26
migrations/versions/4132f684e5f1_.py on lines 0..26
migrations/versions/4e5dd0df14b5_.py on lines 0..26
migrations/versions/5aed7e80e00e_.py on lines 0..26
migrations/versions/63203fd4c3ea_.py on lines 0..26
migrations/versions/66c7787c546e_.py on lines 0..26
migrations/versions/673cf7219a71_.py on lines 0..26
migrations/versions/6f6b4b3a368d_.py on lines 0..26
migrations/versions/76617aa50e25_.py on lines 0..26
migrations/versions/784a1fc57171_.py on lines 0..26
migrations/versions/7871961f26f2_.py on lines 0..26
migrations/versions/7b359f067e8e_.py on lines 0..26
migrations/versions/8223e1b0c247_.py on lines 0..26
migrations/versions/83e0a28b1430_.py on lines 0..26
migrations/versions/840bc71025d6_.py on lines 0..26
migrations/versions/9ccc41444de6_.py on lines 0..26
migrations/versions/aa204a8b5743_.py on lines 0..26
migrations/versions/aa4b21539f5b_.py on lines 0..26
migrations/versions/abf206ef23a1_.py on lines 0..26
migrations/versions/ac0d73a95c0a_.py on lines 0..26
migrations/versions/ac2a9daf5a8e_.py on lines 0..26
migrations/versions/ad7f50c4afb5_.py on lines 0..26
migrations/versions/b723e2342f15_.py on lines 0..26
migrations/versions/c6b183975be9_.py on lines 0..26
migrations/versions/ca628ab9ac91_.py on lines 0..26
migrations/versions/cdba269e9de1_.py on lines 0..26
migrations/versions/d40a49824b53_.py on lines 0..26
migrations/versions/d73fc7833958_.py on lines 0..26
migrations/versions/dd97b5e8fa6b_.py on lines 0..26
migrations/versions/de41bffc4830_.py on lines 0..26
migrations/versions/df5729aed5d2_.py on lines 0..26
migrations/versions/e42e322f7ffb_.py on lines 0..26
migrations/versions/e8222a407dd5_.py on lines 0..26
migrations/versions/efa8f2dbf092_.py on lines 0..26
migrations/versions/f2b4430d9e57_.py on lines 0..26
migrations/versions/f873b99e5be3_.py on lines 0..26

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

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

Severity: Major
Found in migrations/versions/9ccc41444de6_.py and 53 other locations - About 3 hrs to fix
migrations/versions/03ed49c73697_.py on lines 0..26
migrations/versions/04060417378c_.py on lines 0..26
migrations/versions/0d25e6904746_.py on lines 0..26
migrations/versions/0e5940f5bf43_.py on lines 0..26
migrations/versions/0ebd913edd27_.py on lines 0..26
migrations/versions/10136334dff5_.py on lines 0..26
migrations/versions/11143ed3e6fa_.py on lines 0..26
migrations/versions/149695270251_.py on lines 0..26
migrations/versions/16183eae08cb_.py on lines 0..26
migrations/versions/167379522d3d_.py on lines 0..26
migrations/versions/1a89015d90bd_.py on lines 0..26
migrations/versions/1c7e0ce885a6_.py on lines 0..26
migrations/versions/2339564f5dc7_.py on lines 0..26
migrations/versions/265d11072331_.py on lines 0..26
migrations/versions/27c4db7538ca_.py on lines 0..26
migrations/versions/2f9f90ee6e73_.py on lines 0..26
migrations/versions/34be8a5853bd_.py on lines 0..26
migrations/versions/3a9c159811ae_.py on lines 0..26
migrations/versions/3ddac4799fb1_.py on lines 0..26
migrations/versions/4132f684e5f1_.py on lines 0..26
migrations/versions/4e5dd0df14b5_.py on lines 0..26
migrations/versions/5aed7e80e00e_.py on lines 0..26
migrations/versions/63203fd4c3ea_.py on lines 0..26
migrations/versions/66c7787c546e_.py on lines 0..26
migrations/versions/673cf7219a71_.py on lines 0..26
migrations/versions/6f6b4b3a368d_.py on lines 0..26
migrations/versions/76617aa50e25_.py on lines 0..26
migrations/versions/784a1fc57171_.py on lines 0..26
migrations/versions/7871961f26f2_.py on lines 0..26
migrations/versions/7b359f067e8e_.py on lines 0..26
migrations/versions/8223e1b0c247_.py on lines 0..26
migrations/versions/83e0a28b1430_.py on lines 0..26
migrations/versions/840bc71025d6_.py on lines 0..26
migrations/versions/aa204a8b5743_.py on lines 0..26
migrations/versions/aa4b21539f5b_.py on lines 0..26
migrations/versions/abf206ef23a1_.py on lines 0..26
migrations/versions/ac0d73a95c0a_.py on lines 0..26
migrations/versions/ac2a9daf5a8e_.py on lines 0..26
migrations/versions/ad7f50c4afb5_.py on lines 0..26
migrations/versions/b723e2342f15_.py on lines 0..26
migrations/versions/c6b183975be9_.py on lines 0..26
migrations/versions/ca628ab9ac91_.py on lines 0..26
migrations/versions/cdba269e9de1_.py on lines 0..26
migrations/versions/d40a49824b53_.py on lines 0..26
migrations/versions/d73fc7833958_.py on lines 0..26
migrations/versions/dd97b5e8fa6b_.py on lines 0..26
migrations/versions/de41bffc4830_.py on lines 0..26
migrations/versions/df5729aed5d2_.py on lines 0..26
migrations/versions/e42e322f7ffb_.py on lines 0..26
migrations/versions/e8222a407dd5_.py on lines 0..26
migrations/versions/efa8f2dbf092_.py on lines 0..26
migrations/versions/f2b4430d9e57_.py on lines 0..26
migrations/versions/f873b99e5be3_.py on lines 0..26

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

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

Severity: Major
Found in migrations/versions/aa204a8b5743_.py and 53 other locations - About 3 hrs to fix
migrations/versions/03ed49c73697_.py on lines 0..26
migrations/versions/04060417378c_.py on lines 0..26
migrations/versions/0d25e6904746_.py on lines 0..26
migrations/versions/0e5940f5bf43_.py on lines 0..26
migrations/versions/0ebd913edd27_.py on lines 0..26
migrations/versions/10136334dff5_.py on lines 0..26
migrations/versions/11143ed3e6fa_.py on lines 0..26
migrations/versions/149695270251_.py on lines 0..26
migrations/versions/16183eae08cb_.py on lines 0..26
migrations/versions/167379522d3d_.py on lines 0..26
migrations/versions/1a89015d90bd_.py on lines 0..26
migrations/versions/1c7e0ce885a6_.py on lines 0..26
migrations/versions/2339564f5dc7_.py on lines 0..26
migrations/versions/265d11072331_.py on lines 0..26
migrations/versions/27c4db7538ca_.py on lines 0..26
migrations/versions/2f9f90ee6e73_.py on lines 0..26
migrations/versions/34be8a5853bd_.py on lines 0..26
migrations/versions/3a9c159811ae_.py on lines 0..26
migrations/versions/3ddac4799fb1_.py on lines 0..26
migrations/versions/4132f684e5f1_.py on lines 0..26
migrations/versions/4e5dd0df14b5_.py on lines 0..26
migrations/versions/5aed7e80e00e_.py on lines 0..26
migrations/versions/63203fd4c3ea_.py on lines 0..26
migrations/versions/66c7787c546e_.py on lines 0..26
migrations/versions/673cf7219a71_.py on lines 0..26
migrations/versions/6f6b4b3a368d_.py on lines 0..26
migrations/versions/76617aa50e25_.py on lines 0..26
migrations/versions/784a1fc57171_.py on lines 0..26
migrations/versions/7871961f26f2_.py on lines 0..26
migrations/versions/7b359f067e8e_.py on lines 0..26
migrations/versions/8223e1b0c247_.py on lines 0..26
migrations/versions/83e0a28b1430_.py on lines 0..26
migrations/versions/840bc71025d6_.py on lines 0..26
migrations/versions/9ccc41444de6_.py on lines 0..26
migrations/versions/aa4b21539f5b_.py on lines 0..26
migrations/versions/abf206ef23a1_.py on lines 0..26
migrations/versions/ac0d73a95c0a_.py on lines 0..26
migrations/versions/ac2a9daf5a8e_.py on lines 0..26
migrations/versions/ad7f50c4afb5_.py on lines 0..26
migrations/versions/b723e2342f15_.py on lines 0..26
migrations/versions/c6b183975be9_.py on lines 0..26
migrations/versions/ca628ab9ac91_.py on lines 0..26
migrations/versions/cdba269e9de1_.py on lines 0..26
migrations/versions/d40a49824b53_.py on lines 0..26
migrations/versions/d73fc7833958_.py on lines 0..26
migrations/versions/dd97b5e8fa6b_.py on lines 0..26
migrations/versions/de41bffc4830_.py on lines 0..26
migrations/versions/df5729aed5d2_.py on lines 0..26
migrations/versions/e42e322f7ffb_.py on lines 0..26
migrations/versions/e8222a407dd5_.py on lines 0..26
migrations/versions/efa8f2dbf092_.py on lines 0..26
migrations/versions/f2b4430d9e57_.py on lines 0..26
migrations/versions/f873b99e5be3_.py on lines 0..26

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

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

Severity: Major
Found in migrations/versions/3a01b7d9d55e_.py and 24 other locations - About 3 hrs to fix
migrations/versions/4caf2c473e6a_.py on lines 0..27
migrations/versions/8500f5ec6c45_.py on lines 0..26
migrations/versions/rev-2019-08-13-16:07:52-cd3beca1951a_.py on lines 0..27
migrations/versions/rev-2020-01-13-22:43:30-eef7c9bc83a0_.py on lines 0..27
migrations/versions/rev-2020-01-17-18:09:31-6ebafb385765_.py on lines 0..27
migrations/versions/rev-2020-07-26-08:15:09-507022789bcb_.py on lines 0..27
migrations/versions/rev-2020-09-04-10:49:48-3548da69bdec_.py on lines 0..27
migrations/versions/rev-2020-09-25-11:11:26-8e86e0ddc9a4_.py on lines 0..27
migrations/versions/rev-2020-11-16-15:19:38-74a148c0100d_.py on lines 0..27
migrations/versions/rev-2020-12-10-13:19:11-447e39dd5fc2_.py on lines 0..27
migrations/versions/rev-2021-01-15-22:29:59-6314551fe3a7_.py on lines 0..27
migrations/versions/rev-2021-01-31-01:41:31-0c584e84a77b_add_speaker_address.py on lines 0..27
migrations/versions/rev-2021-02-03-17:36:38-d0ac0e357cd9_add_exhibitor_social_links.py on lines 0..27
migrations/versions/rev-2021-02-11-22:30:21-9756adf77900_.py on lines 0..27
migrations/versions/rev-2021-02-20-18:40:40-d92b04bfc2eb_.py on lines 0..27
migrations/versions/rev-2021-03-09-10:35:32-92e0289733a0_add_rocket_chat_token.py on lines 0..27
migrations/versions/rev-2021-07-07-03:47:53-eecca008e169_.py on lines 0..27
migrations/versions/rev-2021-07-22-00:49:24-ab0e4baaabab_.py on lines 0..27
migrations/versions/rev-2021-10-06-18:48:55-ed141a4b57df_.py on lines 0..27
migrations/versions/rev-2021-10-09-20:25:22-c09e0327c6cb_.py on lines 0..27
migrations/versions/rev-2021-11-06-20:56:17-b3cf88a46150_.py on lines 0..27
migrations/versions/rev-2021-11-09-20:38:00-d0b8204bb208_.py on lines 0..27
migrations/versions/rev-2021-11-22-14:44:00-c4fc87788cd5_.py on lines 0..27
migrations/versions/rev-2022-02-06-15:18:08-760795a6d7eb_.py on lines 0..27

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

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

Function before_update_object has a Cognitive Complexity of 23 (exceeds 5 allowed). Consider refactoring.
Open

    def before_update_object(self, event, data, view_kwargs):
        """
        method to save image urls before updating event object
        :param event:
        :param data:
Severity: Minor
Found in app/api/events.py - About 3 hrs to fix

Cognitive Complexity

Cognitive Complexity is a measure of how difficult a unit of code is to intuitively understand. Unlike Cyclomatic Complexity, which determines how difficult your code will be to test, Cognitive Complexity tells you how difficult your code will be to read and comprehend.

A method's cognitive complexity is based on a few simple rules:

  • Code is not considered more complex when it uses shorthand that the language provides for collapsing multiple statements into one
  • Code is considered more complex for each "break in the linear flow of the code"
  • Code is considered more complex when "flow breaking structures are nested"

Further reading

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

                self.session.query(UserCheckIn)
                .filter(
                    UserCheckIn.ticket_holder_id == data.get('ticket_holder'),
                    UserCheckIn.session_id == data.get('session'),
                    UserCheckIn.check_in_out_at >= datetime.datetime.utcnow().date(),
Severity: Major
Found in app/api/user_check_in.py and 1 other location - About 3 hrs to fix
app/api/user_check_in.py on lines 177..181

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

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

    op.create_table('association',
    sa.Column('ticket_id', sa.Integer(), nullable=True),
    sa.Column('ticket_tag_id', sa.Integer(), nullable=True),
    sa.ForeignKeyConstraint(['ticket_id'], ['ticket.id'], ),
    sa.ForeignKeyConstraint(['ticket_tag_id'], ['ticket_tag.id'], )
Severity: Major
Found in migrations/versions/4163ebc03101_.py and 1 other location - About 3 hrs to fix
migrations/versions/30ca70296a1c_.py on lines 169..173

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

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

    op.create_table('speakers_sessions',
    sa.Column('speaker_id', sa.Integer(), nullable=True),
    sa.Column('session_id', sa.Integer(), nullable=True),
    sa.ForeignKeyConstraint(['session_id'], ['session.id'], ),
    sa.ForeignKeyConstraint(['speaker_id'], ['speaker.id'], )
Severity: Major
Found in migrations/versions/30ca70296a1c_.py and 1 other location - About 3 hrs to fix
migrations/versions/4163ebc03101_.py on lines 25..29

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

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

                    self.session.query(UserCheckIn)
                    .filter(
                        UserCheckIn.ticket_holder_id == data.get('ticket_holder'),
                        UserCheckIn.station_id == data.get('station'),
                        UserCheckIn.created_at >= datetime.datetime.utcnow().date(),
Severity: Major
Found in app/api/user_check_in.py and 1 other location - About 3 hrs to fix
app/api/user_check_in.py on lines 161..165

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

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

File scheduled_jobs.py has 302 lines of code (exceeds 250 allowed). Consider refactoring.
Open

import datetime
import logging

import pytz
from flask_celeryext import RequestContextTask
Severity: Minor
Found in app/api/helpers/scheduled_jobs.py - About 3 hrs to fix

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

def upgrade():
    ### commands auto generated by Alembic - please adjust! ###
    op.create_table('custom_placeholder',
    sa.Column('id', sa.Integer(), nullable=False),
    sa.Column('name', sa.String(), nullable=True),
Severity: Major
Found in migrations/versions/90a9f0908326_.py and 1 other location - About 3 hrs to fix
migrations/versions/24017504a117_.py on lines 20..24

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

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

    op.create_table('image_config',
    sa.Column('id', sa.Integer(), nullable=False),
    sa.Column('page', sa.String(), nullable=True),
    sa.Column('size', sa.String(), nullable=True),
    sa.PrimaryKeyConstraint('id')
Severity: Major
Found in migrations/versions/24017504a117_.py and 1 other location - About 3 hrs to fix
migrations/versions/90a9f0908326_.py on lines 18..24

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

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

File export_helpers.py has 296 lines of code (exceeds 250 allowed). Consider refactoring.
Open

import json
import os
import shutil
from collections import OrderedDict
from datetime import datetime
Severity: Minor
Found in app/api/helpers/export_helpers.py - About 3 hrs to fix

Function calculate_update_amount has a Cognitive Complexity of 22 (exceeds 5 allowed). Consider refactoring.
Open

    def calculate_update_amount(order):
        discount = None
        if order.discount_code_id:
            discount = order.discount_code
        # Access code part will be done ticket_holders API
Severity: Minor
Found in app/api/helpers/ticketing.py - About 3 hrs to fix

Cognitive Complexity

Cognitive Complexity is a measure of how difficult a unit of code is to intuitively understand. Unlike Cyclomatic Complexity, which determines how difficult your code will be to test, Cognitive Complexity tells you how difficult your code will be to read and comprehend.

A method's cognitive complexity is based on a few simple rules:

  • Code is not considered more complex when it uses shorthand that the language provides for collapsing multiple statements into one
  • Code is considered more complex for each "break in the linear flow of the code"
  • Code is considered more complex when "flow breaking structures are nested"

Further reading

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

Severity: Major
Found in migrations/versions/6ffaeab2c3c2_.py and 14 other locations - About 3 hrs to fix
migrations/versions/1959f5049425_.py on lines 0..26
migrations/versions/1c52a25b4a97_.py on lines 0..26
migrations/versions/4bbba854e30b_.py on lines 0..26
migrations/versions/cfe06645c991_.py on lines 0..26
migrations/versions/e3caa0f2a16c_.py on lines 0..24
migrations/versions/eaa029ebb260_.py on lines 0..26
migrations/versions/rev-2023-06-12-13:39:49-410e54b84481_.py on lines 0..26
migrations/versions/rev-2023-06-20-17:34:57-e5c599d64ef5_.py on lines 0..26
migrations/versions/rev-2023-06-22-10:02:35-8cf2327b952b_.py on lines 0..26
migrations/versions/rev-2023-06-22-11:53:16-a15294581397_.py on lines 0..26
migrations/versions/rev-2023-06-26-18:45:58-7a4ac439ef4d_.py on lines 0..26
migrations/versions/rev-2023-07-26-10:30:16-8bd9e8e80517_.py on lines 0..26
migrations/versions/rev-2023-08-10-16:04:19-24271525a263_.py on lines 0..26
migrations/versions/rev-2024-03-23-08:47:20-e7e952b58504_.py on lines 0..26

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

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

migrations/versions/1959f5049425_.py on lines 0..26
migrations/versions/1c52a25b4a97_.py on lines 0..26
migrations/versions/4bbba854e30b_.py on lines 0..26
migrations/versions/6ffaeab2c3c2_.py on lines 0..26
migrations/versions/cfe06645c991_.py on lines 0..26
migrations/versions/e3caa0f2a16c_.py on lines 0..24
migrations/versions/eaa029ebb260_.py on lines 0..26
migrations/versions/rev-2023-06-12-13:39:49-410e54b84481_.py on lines 0..26
migrations/versions/rev-2023-06-20-17:34:57-e5c599d64ef5_.py on lines 0..26
migrations/versions/rev-2023-06-22-11:53:16-a15294581397_.py on lines 0..26
migrations/versions/rev-2023-06-26-18:45:58-7a4ac439ef4d_.py on lines 0..26
migrations/versions/rev-2023-07-26-10:30:16-8bd9e8e80517_.py on lines 0..26
migrations/versions/rev-2023-08-10-16:04:19-24271525a263_.py on lines 0..26
migrations/versions/rev-2024-03-23-08:47:20-e7e952b58504_.py on lines 0..26

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

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

migrations/versions/1959f5049425_.py on lines 0..26
migrations/versions/1c52a25b4a97_.py on lines 0..26
migrations/versions/4bbba854e30b_.py on lines 0..26
migrations/versions/6ffaeab2c3c2_.py on lines 0..26
migrations/versions/cfe06645c991_.py on lines 0..26
migrations/versions/e3caa0f2a16c_.py on lines 0..24
migrations/versions/eaa029ebb260_.py on lines 0..26
migrations/versions/rev-2023-06-12-13:39:49-410e54b84481_.py on lines 0..26
migrations/versions/rev-2023-06-20-17:34:57-e5c599d64ef5_.py on lines 0..26
migrations/versions/rev-2023-06-22-10:02:35-8cf2327b952b_.py on lines 0..26
migrations/versions/rev-2023-06-22-11:53:16-a15294581397_.py on lines 0..26
migrations/versions/rev-2023-06-26-18:45:58-7a4ac439ef4d_.py on lines 0..26
migrations/versions/rev-2023-07-26-10:30:16-8bd9e8e80517_.py on lines 0..26
migrations/versions/rev-2024-03-23-08:47:20-e7e952b58504_.py on lines 0..26

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

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 migrations/versions/eaa029ebb260_.py and 14 other locations - About 3 hrs to fix
migrations/versions/1959f5049425_.py on lines 0..26
migrations/versions/1c52a25b4a97_.py on lines 0..26
migrations/versions/4bbba854e30b_.py on lines 0..26
migrations/versions/6ffaeab2c3c2_.py on lines 0..26
migrations/versions/cfe06645c991_.py on lines 0..26
migrations/versions/e3caa0f2a16c_.py on lines 0..24
migrations/versions/rev-2023-06-12-13:39:49-410e54b84481_.py on lines 0..26
migrations/versions/rev-2023-06-20-17:34:57-e5c599d64ef5_.py on lines 0..26
migrations/versions/rev-2023-06-22-10:02:35-8cf2327b952b_.py on lines 0..26
migrations/versions/rev-2023-06-22-11:53:16-a15294581397_.py on lines 0..26
migrations/versions/rev-2023-06-26-18:45:58-7a4ac439ef4d_.py on lines 0..26
migrations/versions/rev-2023-07-26-10:30:16-8bd9e8e80517_.py on lines 0..26
migrations/versions/rev-2023-08-10-16:04:19-24271525a263_.py on lines 0..26
migrations/versions/rev-2024-03-23-08:47:20-e7e952b58504_.py on lines 0..26

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

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