mirror of
https://github.com/penpot/penpot.git
synced 2025-06-26 14:06:59 +02:00
✨ Prevent high cpu usage on reporting big errors.
This commit is contained in:
parent
d892be4971
commit
0092806dda
1 changed files with 7 additions and 4 deletions
|
@ -30,10 +30,13 @@
|
||||||
:method (:request-method request)
|
:method (:request-method request)
|
||||||
:hint (ex-message error)
|
:hint (ex-message error)
|
||||||
:params (:params request)
|
:params (:params request)
|
||||||
:spec-problems (some-> data ::s/problems)
|
|
||||||
:spec-value (some-> data ::s/value)
|
:spec-problems (some->> data ::s/problems (take 10) seq vec)
|
||||||
:spec-explain (with-out-str
|
:spec-value (some->> data ::s/value)
|
||||||
(expound/printer data))
|
:spec-explain (binding [s/*explain-out* expound/printer]
|
||||||
|
(with-out-str
|
||||||
|
(s/explain-out (update data ::s/problems #(take 10 %)))))
|
||||||
|
|
||||||
:data (some-> data (dissoc ::s/problems ::s/value :hint))
|
:data (some-> data (dissoc ::s/problems ::s/value :hint))
|
||||||
:ip-addr (parse-client-ip request)
|
:ip-addr (parse-client-ip request)
|
||||||
:profile-id (:profile-id request)}
|
:profile-id (:profile-id request)}
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue