Causes observable changes with prepareStackTrace
Chưa có ai nhận issue này.
Đánh giá
- Độ khó
- 5/5
- Thời gian dự kiến
- Hơn một tuần
- Mức phù hợp với người mới
- 25/100
- Loại issue
- Tính năng
- Độ rõ ràng
- Khá rõ ràng
- Mức độ hoạt động
- Đình trệ
- Công nghệ
- javascript
- Lĩnh vực
- tooling
Hướng nghiên cứu
Start with the issue's Error.captureStackTrace and Error.prepareStackTrace example, then inspect the linked source-map-support implementation at source-map-support.js around line 397. Compare the observable ordering and evaluation-cost concerns described here; the work is complete when the proposal has a decided behavior and its compatibility implications are documented.
Do mô hình lập chỉ mục viết ra từ nội dung của issue.
Mô tả
When requiring the stack properties value to be eagerly evaluated in captureStackTrace there is a problematic interaction with the existing accompanying prepareStackTrace. That one allows arbitrarily formatting of the stack trace attached to the error object. This makes it observable when the string content of the stack property is computed.
The proposal here would require eager evaluation of the stack formatting code at captureStackTrace time. Whereas the current implementation does it lazily.
Error.prepareStackTrace = (error, stack) => {console.log("2. prepare")};
let err = {};
Error.captureStackTrace(err);
console.log("1. capture");
err.stack;
Here we would essentially have to swap the order of effect 1 and 2.
I think this is not just a theoretical issue. Next to an observable change in behavior it would also make the prepareStackTrace API prohibitively expensive to use.
There is evidence of effectfull and expensive prepareStackTrace handlers, see e.g., source-map-support for node.
- Ngôn ngữ chính
- Không có dữ liệu ngôn ngữ
- Star
- 15
- Fork
- 5
- Chỉ số merge pull request
- Không có pull request nào được merge trong 30 ngày
Chuẩn bị môi trường
- Không có Dockerfile hay tệp Docker Compose
- Không có mẫu pull request
- Đọc hướng dẫn đóng góp
Bắt đầu từ đâu
- Đọc hết issue, rồi đọc hướng dẫn đóng góp của dự án.
- Bình luận trên issue rằng bạn sẽ nhận — tránh hai người làm cùng một việc.
- Fork repository và làm thay đổi trên một nhánh.
- Mở pull request có tham chiếu số hiệu của issue.
Issue khác của tc39/proposal-error-capturestacktrace
-
Độ khó 3/5 1-2 ngày Mức phù hợp với người mới 40/100
tc39/proposal-error-capturestacktrace#15 · 1 reaction ·
-
Độ khó 5/5 Hơn một tuần Mức phù hợp với người mới 35/100
tc39/proposal-error-capturestacktrace#13 · 4 bình luận · 1 reaction ·
-
Độ khó 5/5 Hơn một tuần Mức phù hợp với người mới 25/100
tc39/proposal-error-capturestacktrace#2 · 2 bình luận ·
-
Độ khó 5/5 Hơn một tuần Mức phù hợp với người mới 25/100
tc39/proposal-error-capturestacktrace#1 · 4 bình luận ·
Tất cả issue của tc39/proposal-error-capturestacktrace
Issue tương tự
-
enhancement needs triage
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 70/100
elastic/docs-builder#4495 ·
Maintainer thường phản hồi trong vòng 1 ngày
-
[Bug]: Target width input clamps the value on every keystrokeCó thể đã có người làm @AnushreeKasturi đã nhận hôm nay. Đang mởbug good first issue
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 82/100
suradet-ps/codeframe#37 · 2 bình luận ·
Maintainer thường phản hồi trong vòng 1 ngày
-
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 68/100
Maintainer thường phản hồi trong vòng 2 ngày
-
change request evaluating
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 72/100
sindresorhus/eslint-plugin-unicorn#3907 ·
Maintainer thường phản hồi trong vòng 1 ngày
-
bug needs-triage
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 70/100
Maintainer thường phản hồi trong vòng 1 ngày