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

meta.maxNoteTextLengthをnote.textの最大サイズより大きく設定できる #5016

Closed
u1-liquid opened this issue Jun 1, 2019 · 0 comments · Fixed by #5465
Closed
Labels
⚠️bug? This might be a bug

Comments

@u1-liquid
Copy link
Contributor

u1-liquid commented Jun 1, 2019

💡 Summary

meta.maxNoteTextLength値にはサイズ上限がついていないが
note.textの最大サイズは8192文字の制限があり

https://github.com/syuilo/misskey/blob/aff80199e5b8d0f27f13b3679378c4b0a60e920f/src/models/entities/note.ts#L46-L49

meta.maxNoteTextLength = 10000
新しく投稿するnoteの文字数 = 9999

だとUI上では最大文字数を超えていないように見えるが
実際はDBのinsert時エラーになるはず

ちなみにnote.textに最大文字数の制限がついたのは 92dee53 (v11.13.0頃)ですがこれに該当するmigrationは作成されていないため
v11.13.0以前に立てた鯖はmeta.maxNoteTextLengthを8192以上に設定してもDBのinsert時エラーにならない

🙂 Expected Behavior

note.textの文字数制限を廃止
または
meta.maxNoteTextLength値を8192以上に設定できないようにする

☹️ Actual Behavior

note.textには最大文字数の制限があるけど
meta.maxNoteTextLengthは上限値の設定がいない

📝 Steps to Reproduce

  1. v11.13.0のソースコードで新しく鯖を立てる
  2. meta.maxNoteTextLength値を8192以上に設定する
  3. 8192文字以上のnoteを投稿する

📌 Environment

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
⚠️bug? This might be a bug
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant