Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Migrate annotations (old) #317

Open
wants to merge 26 commits into
base: master
Choose a base branch
from
Open

Migrate annotations (old) #317

wants to merge 26 commits into from

Conversation

yCobanoglu
Copy link
Member

No description provided.

yCobanoglu added 26 commits March 7, 2022 15:38
# Conflicts:
#	ebl/fragmentarium/application/annotations_image_extractor.py
#	ebl/fragmentarium/application/annotations_schema.py
# Conflicts:
#	ebl/app.py
#	ebl/fragmentarium/application/annotations_image_extractor.py
#	ebl/fragmentarium/application/annotations_service.py
#	ebl/fragmentarium/domain/annotation.py
#	ebl/tests/conftest.py
#	ebl/tests/fragmentarium/test_annotations_route.py
#	ebl/tests/fragmentarium/test_annotations_service.py
#	ebl/tests/signs/test_sign_images_route.py
@sourcery-ai
Copy link
Contributor

sourcery-ai bot commented Nov 6, 2022

Sourcery Code Quality Report

❌  Merging this PR will decrease code quality in the affected files by 0.33%.

Quality metrics Before After Change
Complexity 0.44 ⭐ 0.41 ⭐ -0.03 👍
Method Length 49.29 ⭐ 49.23 ⭐ -0.06 👍
Working memory 7.10 🙂 7.14 🙂 0.04 👎
Quality 79.98% 79.65% -0.33% 👎
Other metrics Before After Change
Lines 2051 2013 -38
Changed files Quality Before Quality After Quality Change
ebl/app.py 85.83% ⭐ 86.39% ⭐ 0.56% 👍
ebl/context.py 98.83% ⭐ 98.83% ⭐ 0.00%
ebl/mongo_collection.py 89.39% ⭐ 89.39% ⭐ 0.00%
ebl/fragmentarium/application/annotations_schema.py 92.76% ⭐ 92.76% ⭐ 0.00%
ebl/fragmentarium/application/annotations_service.py 75.12% ⭐ 76.92% ⭐ 1.80% 👍
ebl/fragmentarium/application/cropped_annotations_service.py 81.48% ⭐ 81.48% ⭐ 0.00%
ebl/fragmentarium/application/cropped_sign_image.py 94.65% ⭐ 94.65% ⭐ 0.00%
ebl/fragmentarium/application/cropped_sign_images_repository.py 96.84% ⭐ 96.84% ⭐ 0.00%
ebl/fragmentarium/domain/annotation.py 79.39% ⭐ 79.56% ⭐ 0.17% 👍
ebl/fragmentarium/infrastructure/cropped_sign_images_repository.py 94.58% ⭐ 94.58% ⭐ 0.00%
ebl/fragmentarium/infrastructure/mongo_annotations_repository.py 89.06% ⭐ 89.06% ⭐ 0.00%
ebl/fragmentarium/web/annotations.py 79.11% ⭐ 79.11% ⭐ 0.00%
ebl/fragmentarium/web/bootstrap.py 41.19% 😞 44.31% 😞 3.12% 👍
ebl/signs/web/bootstrap.py 84.62% ⭐ 84.62% ⭐ 0.00%
ebl/signs/web/cropped_annotations.py 91.85% ⭐ 91.85% ⭐ 0.00%
ebl/tests/conftest.py 91.78% ⭐ 91.76% ⭐ -0.02% 👎
ebl/tests/test_mongo_collection.py 91.52% ⭐ 91.52% ⭐ 0.00%
ebl/tests/factories/annotation.py 47.13% 😞 47.13% 😞 0.00%
ebl/tests/fragmentarium/test_annotation.py 82.18% ⭐ 82.18% ⭐ 0.00%
ebl/tests/fragmentarium/test_annotations_route.py 77.44% ⭐ 77.44% ⭐ 0.00%
ebl/tests/fragmentarium/test_annotations_schema.py 59.39% 🙂 59.39% 🙂 0.00%
ebl/tests/fragmentarium/test_annotations_service.py 60.82% 🙂 60.82% 🙂 0.00%
ebl/tests/fragmentarium/test_cropped_annotations_service.py 63.68% 🙂 63.68% 🙂 0.00%
ebl/tests/signs/test_sign_images_route.py 62.71% 🙂 62.71% 🙂 0.00%
ebl/tests/transliteration/test_line_label.py 82.14% ⭐ 82.14% ⭐ 0.00%
ebl/tests/transliteration/test_line_number.py 71.82% 🙂 71.82% 🙂 0.00%
ebl/transliteration/domain/line_label.py 84.13% ⭐ 84.13% ⭐ 0.00%
ebl/transliteration/domain/line_number.py 94.13% ⭐ 93.37% ⭐ -0.76% 👎

Here are some functions in these files that still need a tune-up:

File Function Complexity Length Working Memory Quality Recommendation
ebl/fragmentarium/web/bootstrap.py create_fragmentarium_routes 0 ⭐ 271 ⛔ 17 ⛔ 44.31% 😞 Try splitting into smaller methods. Extract out complex expressions
ebl/tests/fragmentarium/test_annotations_service.py test_update 0 ⭐ 259 ⛔ 16 ⛔ 45.84% 😞 Try splitting into smaller methods. Extract out complex expressions
ebl/tests/conftest.py signs 0 ⭐ 287 ⛔ 9 🙂 55.72% 🙂 Try splitting into smaller methods
ebl/fragmentarium/application/annotations_service.py AnnotationsService._cropped_image_from_annotations_helper 3 ⭐ 104 🙂 15 😞 57.59% 🙂 Extract out complex expressions
ebl/tests/conftest.py context 0 ⭐ 102 🙂 18 ⛔ 57.88% 🙂 Extract out complex expressions

Legend and Explanation

The emojis denote the absolute quality of the code:

  • ⭐ excellent
  • 🙂 good
  • 😞 poor
  • ⛔ very poor

The 👍 and 👎 indicate whether the quality has improved or gotten worse with this pull request.


Please see our documentation here for details on how these metrics are calculated.

We are actively working on this report - lots more documentation and extra metrics to come!

Help us improve this quality report!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant