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

GM_setValue size exception(1 * 1024 * 1024) #1

Closed
azu opened this issue Sep 23, 2013 · 4 comments
Closed

GM_setValue size exception(1 * 1024 * 1024) #1

azu opened this issue Sep 23, 2013 · 4 comments

Comments

@azu
Copy link
Contributor

azu commented Sep 23, 2013

@Constellation

http://userscripts.org/topics/130314

で報告されているエラーですが、Scriptishで確かめた感じだと、
GM_setValue に 大きな値を保存した際に例外を吐いてるようです。

GM_setValueは nsPrefBranch::SetComplexValue で保存されていて、この時にCheckSanityOfStringLengthで保存するサイズのチェックがされていて、MAX_PREF_LENGTH = 1 * 1024 * 1024 以上だと失敗するようです。

localStorage にすれば、Firefox 24 + Scriptish v0.1.11で動くのは確認しました。

いずれ pref.js への保存容量が4kb制限になるみたいなので、そのうちGreeasemonkey側の実装が変わりそうな気がしています。

@terepanda
Copy link

Firefox24で動作するようになりました。ありがとうございます!

@azu
Copy link
Contributor Author

azu commented Dec 5, 2013

Greasemonkey 1.13 で pref ではなく SQLiteのDBに移行したようなので、
恐らくこのサイズ制限にはかからなくなると思います。

代わりにwedataさんとalternativeが両方死んでるので、データを新規取得する方法がありませんが…

生きてるデータは以下ぐらいかな?

@azu
Copy link
Contributor Author

azu commented Jul 21, 2014

これもGreasemonkey(本体)ではSQLite移行して問題なくなったと思うので閉じます
(Scriptishは未だに問題残ってて、多分直らない気がする)

scriptish/scriptish#189

@azu azu closed this as completed Jul 21, 2014
@Constellation
Copy link
Owner

Thank you!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants