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

Improve the response status code of kernel API /api/file/getFile #9075

Merged
merged 2 commits into from
Aug 30, 2023

Conversation

Zuoqiu-Yingyi
Copy link
Contributor

@Zuoqiu-Yingyi Zuoqiu-Yingyi commented Aug 30, 2023

  • Please commit to the dev branch
  • For contributing new features, please supplement and improve the corresponding user guide documents
  • For bug fixes, please describe the problem and solution via code comments
  • For text improvements (such as typos and wording adjustments), please submit directly

已经过测试 | Tested

  • Return value
    • Response status code 200: File content

    • Response status code 202: Exception information

      {
        "code": 404,
        "msg": "",
        "data": null
      }
      • code: non-zero for exceptions
        • -1: Parameter parsing error
        • 404: Not Found (file doesn't exist)
        • 405: Method Not Allowed (it's a directory)
        • 500: Server Error (stat file failed / read file failed)
      • msg: a piece of text describing the error

API.md Outdated Show resolved Hide resolved
@88250 88250 changed the title Improve the response status code of API /api/file/getFile Improve the response status code of kernel API /api/file/getFile Aug 30, 2023
@88250 88250 added this to the 2.10.3 milestone Aug 30, 2023
@Zuoqiu-Yingyi Zuoqiu-Yingyi requested a review from 88250 August 30, 2023 15:15
@88250 88250 merged commit baa3ef0 into siyuan-note:dev Aug 30, 2023
2 checks passed
@Zuoqiu-Yingyi Zuoqiu-Yingyi deleted the refactor/api-getFile-status-code branch August 30, 2023 15:48
EightDoor added a commit to EightDoor/siyuan that referenced this pull request Sep 1, 2023
* commit 'a63e1fda2e203917ae7f72cb359155f4094c4f3e': (217 commits)
  ⚡ Improve block loading performance on Windows/Linux/macOS amd64 arch siyuan-note#9084
  💄
  ⚡ Improve block loading performance on Windows/Linux/macOS amd64 arch siyuan-note#9084
  🐛 Block hyperlinks do not point to regenerated block IDs when importing .sy.zip siyuan-note#9083
  🎨 Reduce the memory usage of PDF asset file content parsing on the mobile siyuan-note#9079
  🎨 HTTPS certificate is no longer verified when `Convert network images to local images` siyuan-note#9080
  🐛 fix siyuan-note#9076
  🐛 fix siyuan-note#9076
  🐛
  🎨 siyuan-note#9068
  🎨 Improve the response status code of  kernel API `/api/file/getFile` siyuan-note#9075
  Improve the response status code of  kernel API `/api/file/getFile` (siyuan-note#9075)
  ✨ siyuan-note#9032siyuan-note#9032
  🐛 The update button is not displayed after the marketplace package version is updated Fix siyuan-note#9074siyuan-note#9032
  🎨 Improve asset file content search preview escaping siyuan-note#9073
  🎨 Improve asset file content search preview escaping siyuan-note#9073
  🎨 Improve EPUB asset file content parsing siyuan-note#9072
  ♻️ siyuan-note#9032
  ...

# Conflicts:
#	README.md
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants