Radio Control App
還沒有人認領這個 Issue。
評估
研究方向
Start with the coursework files in the linked types-stretch directory and read the existing classes, especially the __str__ method and Playlist. Run mypy as you work, then add your own test code as requested. Done means the requested dataclasses, Person and Podcast classes, generic playlist, and formatted durations are implemented and checked.
由索引模型根據 Issue 內容生成。
描述
Link to the coursework
https://github.com/CodeYourFuture/Module-Tools/tree/main/types-stretch
Learning Objectives
- Turn classes into dataclasses.
- Make and use a generic class.
- Use classes within a heirarchy.
- Refactor a codebase using mypy.
Why are we doing this?
Sprint 5 Stretch - Radio Control App
This is part of an app that can be used to control an online radio station
Your task is to:
- Add type annotations where appropriate.
- Upgrade everything use dataclasses. Use frozen where appropriate.
- Observe how the given str method works, and add one to the other classes
- When the str method is called, have it print the duration in formatted mm:ss rather than just seconds
- Add a new class of Person - you can use your imagination what this includes, but it should have at least a string name
- Turn the fields for artists, host, and guest into Person classes
- Make a new class Podcast that extends the TalkShow class, with an extra string field for sponsor
- Finish implementing the class Playlist, and set it to takes a generic, e.g. either Song or TalkShow or Podcast
- As you implement, make sure to keep checking with mypy and add your own code at the end to test it works correctly
Maximum time in hours
1
How to get help
General advice on asking for help can be found on the curriculum pages.
You can always share your blockers in your class channel and get help from your colleagues.
Submission & Review
Fork the coursework repo to your own GitHub account.
Make regular small commits with clear messages.
When you are ready, open a Pull Request to the CYF repo. Make sure you fill in the PR template provided.
A volunteer will review your submission and send you feedback.
- 主要語言
- Shell
- 星號
- 0
- 分支
- 116
- PR 合併指標
- 30 天內沒有已合併 PR
環境準備
- 沒有 Dockerfile 或 Docker Compose 檔案
- 沒有 Pull Request 範本
- 閱讀貢獻指南
從這裡開始
- 先讀完整個 Issue,再讀專案的貢獻指南。
- 在 Issue 下留言說明你要接手 —— 這能避免兩個人做同樣的事。
- Fork 儲存庫,在一個分支上完成修改。
- 送出 Pull Request,並在描述裡引用這個 Issue 編號。
CodeYourFuture/Module-Tools 的其他 Issue
-
📅 Sprint 4 Module-Tools Setup Submit:None 🦔 Size Tiny
難度 2/5 1-3 小時 新手友好度 70/100
CodeYourFuture/Module-Tools#712 ·
-
🏕 Priority Mandatory 📅 Sprint 4 Core Module-Tools Submit:None 🦔 Size Tiny
難度 1/5 1 小時以內 新手友好度 70/100
CodeYourFuture/Module-Tools#581 ·
-
🏕 Priority Mandatory 🐇 Size Small 📅 Sprint 2 📅 Sprint 4 Module-Tools Recurring Submit:None
難度 1/5 1-3 小時 新手友好度 58/100
CodeYourFuture/Module-Tools#544 ·
-
Install a JDK未關閉🏕 Priority Mandatory 📅 Sprint 4 Core Module-Tools Submit:None
難度 1/5 1-3 小時 新手友好度 78/100
CodeYourFuture/Module-Tools#480 ·
-
🏕 Priority Mandatory 🐂 Size Medium 📅 Sprint 4 Core Module-Tools Submit:Slack
難度 2/5 半天 新手友好度 45/100
CodeYourFuture/Module-Tools#137 ·
查看 CodeYourFuture/Module-Tools 的全部 Issue
相似的 Issue
-
area: release enhancement good first issue size: S
難度 2/5 1-3 小時 新手友好度 70/100
dhruvchawla2511/Friday#39 ·
-
難度 1/5 1 小時以內 新手友好度 88/100
tldr-pages/tldr#25495 · 1 則留言 ·
維護者通常 1 天內回覆
-
action-item bug
難度 2/5 1-3 小時 新手友好度 72/100
getcommunityone/open-navigator#895 ·
維護者通常 1 天內回覆
-
enhancement help wanted ready-for-triage triaged
難度 2/5 1-3 小時 新手友好度 62/100
rh-pvsec/crypto-scanner-tasks#78 · 2 則留言 ·
維護者通常 5 天內回覆
-
難度 2/5 1-3 小時 新手友好度 62/100
ModelEngine-Group/nexent#4428 ·
維護者通常 1 天內回覆