Skip to content

Conversation

@Temmmmmo
Copy link
Member

@Temmmmmo Temmmmmo commented Jul 15, 2023

Изменения

Фикс Oauth и переезд на Pydantic v2

Реализации

Заменены основные устаревшие методы из Pydantic

Детали

Заменены следующие устаревшие методы:

.dict() ---> .model_dump()
validator() ---> field_validator()
.from_orm() ---> .model_validate()
.schema() ---> .model_json_schema()
.update_forward_refs() ---> .model_rebuild()
.construct() ---> .model_construct()

Check-List

  • Вы проверили свой код перед отправкой запроса?
  • Вы написали тесты к реализованным функциям?
  • Вы не забыли применить black и isort?

@github-actions
Copy link

💩 Code linting failed, use black and isort to fix it.

@github-actions
Copy link

github-actions bot commented Jul 15, 2023

Code Coverage

Coverage Report
FileStmtsMissCoverMissing
auth_backend
   __main__.py330%1–5
   base.py11464%6–9
   exceptions.py32584%16, 31–33, 38
auth_backend/auth_plugins
   auth_method.py1532087%103, 137, 161, 203, 208, 236, 238, 245, 264, 270, 275–276, 280–291, 296, 318–321
   email.py1971294%235, 288, 290, 292, 296, 332, 351, 353, 375, 402, 406, 447
   github.py884747%63–110, 121–156, 163, 168
   google.py954751%71–112, 123–139, 146, 152–156, 160–165
   lkmsu.py884747%63–103, 114–142, 149, 154
   telegram.py894055%60–82, 94–103, 110, 116, 126–146
   vk.py884747%61–101, 112–141, 148, 153
   yandex.py1036042%62–116, 126–155, 163, 169
auth_backend/cli
   group.py13130%1–17
   process.py57570%1–73
   scope.py11110%1–15
   user.py20200%1–40
   user_group.py10100%1–18
auth_backend/models
   base.py55591%25–28, 76
auth_backend/routes
   app_auth.py241346%31–48
   exc_handlers.py37586%27, 46, 58, 68, 85
   groups.py85396%82, 132, 134
   scopes.py30390%24, 50–51
   user.py672563%47, 49, 51–60, 72–87, 128–137
   user_session.py70494%73–82, 110, 112
auth_backend/schemas
   models.py94397%149–151
auth_backend/schemas/types
   scopes.py24675%29–31, 36, 39, 41
auth_backend/utils
   security.py39295%35, 59
   smtp.py771877%76–79, 101–120
   user_session_control.py36294%33, 69
TOTAL195453273% 

Summary

Tests Skipped Failures Errors Time
50 6 💤 0 ❌ 0 🔥 15.818s ⏱️

@Temmmmmo Temmmmmo self-assigned this Jul 15, 2023
@grigoriev-semyon grigoriev-semyon merged commit 570d7d6 into main Jul 17, 2023
@grigoriev-semyon grigoriev-semyon deleted the bug-fixes branch July 17, 2023 08:29
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.

2 participants