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

Added nullable user_id #32

Merged
merged 4 commits into from
Nov 8, 2024
Merged

Added nullable user_id #32

merged 4 commits into from
Nov 8, 2024

Conversation

zipperman1
Copy link
Contributor

@zipperman1 zipperman1 commented Nov 8, 2024

Изменения

Добавил nullable user_id в Comment
Изменил nullable на True в user_id в LecturerUserComment

Детали реализации

См. Изменения

Check-List

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

Copy link

github-actions bot commented Nov 8, 2024

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

Copy link

github-actions bot commented Nov 8, 2024

Code Coverage

Coverage Report
FileStmtsMissCoverMissing
rating_api
   __main__.py440%1–7
   exceptions.py26581%17, 35–36, 44, 49
rating_api/models
   base.py551965%24–27, 45, 53, 56, 58–59, 63–67, 72–77
   db.py52590%40–46
rating_api/routes
   comment.py663645%28, 34–37, 55–58, 85–108, 125–128, 140–145
   exc_handlers.py20480%12, 26, 33, 40
   lecturer.py896626%31–33, 50–71, 104–145, 157–173, 183–194
rating_api/schemas
   models.py66198%34
TOTAL42714067% 

Summary

Tests Skipped Failures Errors Time
10 0 💤 10 ❌ 0 🔥 7.336s ⏱️

Copy link

github-actions bot commented Nov 8, 2024

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

@Zimovchik Zimovchik linked an issue Nov 8, 2024 that may be closed by this pull request
@Zimovchik Zimovchik self-requested a review November 8, 2024 14:26
@@ -52,6 +53,6 @@ class Comment(BaseDbModel):
class LecturerUserComment(BaseDbModel):
id: Mapped[int] = mapped_column(Integer, primary_key=True)
lecturer_id: Mapped[int] = mapped_column(Integer, ForeignKey("lecturer.id"))
user_id: Mapped[int] = mapped_column(Integer, nullable=False)
user_id: Mapped[int] = mapped_column(Integer, nullable=True)
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

не нужно

@zipperman1 zipperman1 merged commit 94f0a5b into main Nov 8, 2024
2 checks passed
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.

Добавить в сущность Comment параметр user_id
2 participants