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

🌐 Add Korean translation for Tutorial - JSON Compatible Encoder #3152

Merged
merged 2 commits into from Dec 8, 2021

Conversation

NEONKID
Copy link
Contributor

@NEONKID NEONKID commented May 1, 2021

Hello there.

Translated by referring to the previous PR. If you have any problems such as mistranslations, please feel free to leave your comments here.

This PR translates tutorial/encoder.md in Korean.

related: #2017

@tiangolo tiangolo added awaiting-review lang-all Translations lang-ko Korean translations labels May 1, 2021
@codecov
Copy link

codecov bot commented May 1, 2021

Codecov Report

Merging #3152 (0ca4843) into master (ce0ec06) will not change coverage.
The diff coverage is n/a.

❗ Current head 0ca4843 differs from pull request most recent head d1fa3ae. Consider uploading reports for the commit d1fa3ae to get more accurate results
Impacted file tree graph

@@            Coverage Diff            @@
##            master     #3152   +/-   ##
=========================================
  Coverage   100.00%   100.00%           
=========================================
  Files          243       243           
  Lines         7419      7419           
=========================================
  Hits          7419      7419           

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 2252837...d1fa3ae. Read the comment docs.

@github-actions
Copy link
Contributor

github-actions bot commented May 1, 2021

📝 Docs preview for commit 0ca4843 at: https://608d280e7010f90923b80230--fastapi.netlify.app

@@ -0,0 +1,34 @@
# JSON Compatible 인코더
Copy link
Sponsor Contributor

Choose a reason for hiding this comment

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

You missed Compatible.


사이즈가 큰 문자열 형태의 JSON 형식(문자열)의 데이터가 들어있을 땐 `str`로 반환하지 않습니다. JSON과 모두 호환되는 값과 하위 값이 있는 Python 표준 데이터 구조 (예: `dict`)를 반환합니다.

!!! note
Copy link
Sponsor Contributor

Choose a reason for hiding this comment

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

Suggested change
!!! note
!!! note "참고"


이를 위해 `jsonable_encoder` 를 사용할 수 있습니다.

Pydantic 모델과 같은 객체를 받고 JSON 호환 가능한 데이터로 반환합니다:
Copy link
Sponsor Contributor

Choose a reason for hiding this comment

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

Suggested change
Pydantic 모델과 같은 객체를 받고 JSON 호환 가능한 데이터로 반환합니다:
Pydantic 모델과 같은 객체를 받고 JSON 호환 가능한 버전으로 반환합니다:

It's not a big deal; the original sentence used the term version, not data however.

It's good to keep the intention of the author as you can possible.

사이즈가 큰 문자열 형태의 JSON 형식(문자열)의 데이터가 들어있을 땐 `str`로 반환하지 않습니다. JSON과 모두 호환되는 값과 하위 값이 있는 Python 표준 데이터 구조 (예: `dict`)를 반환합니다.

!!! note
`jsonable_encoder` 은 실제로 **FastAPI** 에서 내부적으로 데이터를 변환하는 데 사용하지만, 다른 많은 곳에서도 이는 유용합니다.
Copy link
Sponsor Contributor

Choose a reason for hiding this comment

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

Again, for preserving the intention, don't break a sentence structure, please. 🤗

And I think "는" is proper than "은" where jsonable_encoder after.

Copy link

@peebbv6364 peebbv6364 left a comment

Choose a reason for hiding this comment

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

I propose some modifications. However, you can reject the offer because it is simply an expression of my thoughts.


이렇게 호출한 결과는 파이썬 표준인 <a href="https://docs.python.org/3/library/json.html#json.dumps" class="external-link" target="_blank">`json.dumps()`</a>로 인코딩 할 수 있습니다.

사이즈가 큰 문자열 형태의 JSON 형식(문자열)의 데이터가 들어있을 땐 `str`로 반환하지 않습니다. JSON과 모두 호환되는 값과 하위 값이 있는 Python 표준 데이터 구조 (예: `dict`)를 반환합니다.

Choose a reason for hiding this comment

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

Suggested change
사이즈가 큰 문자열 형태의 JSON 형식(문자열)의 데이터가 들어있을 땐 `str`로 반환하지 않습니다. JSON과 모두 호환되는 값과 하위 값이 있는 Python 표준 데이터 구조 (예: `dict`)를 반환합니다.
길이가 긴 문자열 형태의 JSON 형식(문자열)의 데이터가 들어있는 상황에서는 `str`로 반환하지 않습니다. JSON과 모두 호환되는 값과 하위 값이 있는 Python 표준 데이터 구조 (예: `dict`)를 반환합니다.

사이즈가 큰 문자열 형태의 JSON 형식(문자열)의 데이터가 들어있을 땐 `str`로 반환하지 않습니다. JSON과 모두 호환되는 값과 하위 값이 있는 Python 표준 데이터 구조 (예: `dict`)를 반환합니다.

!!! note
`jsonable_encoder` 은 실제로 **FastAPI** 에서 내부적으로 데이터를 변환하는 데 사용하지만, 다른 많은 곳에서도 이는 유용합니다.

Choose a reason for hiding this comment

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

Suggested change
`jsonable_encoder` 은 실제로 **FastAPI** 에서 내부적으로 데이터를 변환하는 데 사용하지만, 다른 많은 곳에서도 이는 유용합니다.
실제로 `jsonable_encoder`**FastAPI** 에서 내부적으로 데이터를 변환하는 데 사용되지만, 다른 많은 곳에서도 유용하게 사용됩니다.


사이즈가 큰 문자열 형태의 JSON 형식(문자열)의 데이터가 들어있을 땐 `str`로 반환하지 않습니다. JSON과 모두 호환되는 값과 하위 값이 있는 Python 표준 데이터 구조 (예: `dict`)를 반환합니다.

!!! note

Choose a reason for hiding this comment

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

Suggested change
!!! note
!!! 참고

Copy link
Sponsor Contributor

Choose a reason for hiding this comment

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

We have to write like:

Suggested change
!!! note
!!! note "참고"


## `jsonable_encoder` 사용

JSON 호환 가능 데이터만 수신하는 `fake_db` 데이터베이스가 있다고 가정해보겠습니다.

Choose a reason for hiding this comment

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

Suggested change
JSON 호환 가능 데이터만 수신하는 `fake_db` 데이터베이스가 있다고 가정해보겠습니다.
JSON 호환 가능 데이터만 수신하는 `fake_db` 데이터베이스가 존재한다고 가정하겠습니다.


JSON 호환 가능 데이터만 수신하는 `fake_db` 데이터베이스가 있다고 가정해보겠습니다.

예를 들면, `datetime` 객체는 JSON과 호환되는 데이터가 아니므로 이 데이터는 받지 않습니다.

Choose a reason for hiding this comment

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

Suggested change
예를 들면, `datetime` 객체는 JSON과 호환되는 데이터가 아니므로 이 데이터는 받지 않습니다.
예를 들면, `datetime` 객체는 JSON과 호환되는 데이터가 아니므로 이 데이터는 받아들여지지 않습니다.

@NEONKID
Copy link
Contributor Author

NEONKID commented May 4, 2021

@hard-coders @peebbv6364
Thank you for reviewing. I have actively accepted and reflected your opinions.

@hard-coders hard-coders mentioned this pull request May 11, 2021
@0417taehyun
Copy link
Contributor

@peebbv6364

Can you approve the review?

@tiangolo
Copy link
Owner

tiangolo commented Dec 8, 2021

Thanks for your contribution @NEONKID! 🍰

And thanks for the reviews @hard-coders and @peebbv6364! 🙇

@tiangolo tiangolo merged commit 461e0d4 into tiangolo:master Dec 8, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
approved-2 lang-all Translations lang-ko Korean translations
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

5 participants