Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
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
[Python] 타입 힌트 내용 추가 #59
[Python] 타입 힌트 내용 추가 #59
Changes from 1 commit
a8862db
a4aa128
08f2212
File filter
Filter by extension
Conversations
Jump to
There are no files selected for viewing
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
관련 참고자료는 문서 최하단이나 주제의 하단에 참고 자료의 형태로 따로 모아두는것은 어떤가요?
논의를 통해 정해진 내용들이 가장 중요한 내용이라 그것을 중심으로 작성해 나가는것이 좋은것 같아서요.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
히스토리보단 결과를 담는 게 중요하다는 점에 동의합니다. 논의를 아예 안적어도 무방할 것 같고, 이 PR과 논의를 #을 사용하여 연결시켜주면 충분할 것 같습니다.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
issue와 달리 discussion은 서로 #으로 참조해도 PR 이력에 남지 않네요... 일단 #으로 PR과 discussion 간 서로 언급은 해두고, 관련 논의 줄은 가이드에서 지웠습니다.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
p4. 논의가 필요한 내용인 것 같습니다.
PEP673에 따르면, self나 cls에 대해 타입 힌트를 생략하지 않는 것도 괜찮다고 합니다.
물론 python 3.11+ 혹은 typing-extension를 쓰는 경우에 그렇고,
지금은 필요한 경우 적어야 하고, 그 외에는 생략하는 게 좋은 것 같습니다.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
typing-extension은 설치되어 있기 때문에, 모든 경우에 self, cls의 타입힌트를 생략할 수 있습니다.
아래 경우에는 생략하기 애매할 수 있는데, 아직 저희 코드베이스에는 등장하지 않습니다. 해당 경우가 발생하면 다시 의논의 여지가 있긴 하나, 우선 일관성을 고려하여 단정적인 어투의
생략합니다.
를 유지하도록 하겠습니다.There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
별개로 get_name() 메서드에
@classmethod
데코레이터가 누락되었네요. 추가하겠습니다.