production builds failing in ember 3.0.0.beta.5: broccoliBuilderErrorStack: TypeError: name.definition is not a function
Chưa có ai nhận issue này.
- #60 của @0xadada — đã đóng, không merge
Đánh giá
- Độ khó
- 3/5
- Thời gian dự kiến
- 1-2 ngày
- Mức phù hợp với người mới
- 45/100
- Loại issue
- Lỗi
- Độ rõ ràng
- Khá rõ ràng
- Mức độ hoạt động
- Đình trệ
- Công nghệ
- javascript
- Lĩnh vực
- build-system
Hướng nghiên cứu
Bắt đầu với việc tái hiện tại mirai-audio/mir commit 7bc4b65df5d01e085c98122c8c8a79542a26dad9 và chạy ember build -e production. Đọc ember-cli-build.js, cấu hình ember-cli-uglify và đường dẫn lỗi của UglifyWriter; so sánh bản build được nén nhưng thất bại với cách khắc phục compress: false. Hoàn tất khi các bản build production hoàn thành với tính năng nén được bật mà không có TypeError đã báo cáo.
Do mô hình lập chỉ mục viết ra từ nội dung của issue.
Mô tả
production builds started failing when I upgraded to ember 3.0.0.beta.2
ember build -e production
cleaning up...
Build failed.
Build Error (UglifyWriter)
name.definition is not a function
Stack Trace and Error Report: /var/folders/ss/sjsdtptn7j1cc6y_x8lbc3ch0000gnT/error.dump.84a92b54f2b31e423fbac3414a0600c9.log
/var/folders/ss/sjsdtptn7j1cc6y_x8lbc3ch0000gn/T/error.dump.84a92b54f2b31e423fbac3414a0600c9.log
=================================================================================
ENV Summary:
TIME: Sat Feb 03 2018 13:15:30 GMT-0500 (EST)
TITLE: ember
ARGV:
- /Users/x/.nvm/versions/node/v8.9.3/bin/node
- /usr/local/bin/ember
- build
- -e
- production
EXEC_PATH: /Users/ron/.nvm/versions/node/v8.9.3/bin/node
TMPDIR: /var/folders/ss/sjsdtptn7j1cc6y_x8lbc3ch0000gn/T
SHELL: /usr/local/bin/bash
PATH:
- /Users/x/.pyenv/shims
- /Users/x/.rvm/gems/ruby-head/bin
- /Users/x/.rvm/gems/ruby-head@global/bin
- /Users/x/.rvm/rubies/ruby-head/bin
- /Users/x/.nvm/versions/node/lts/*/bin
- /Users/x/.nvm/versions/node/v8.9.3/bin
- /usr/local/bin
- /usr/bin
- /bin
- /usr/sbin
- /sbin
- /usr/local/MacGPG2/bin
- /Users/x/bin
- /Applications/Xcode.app/Contents/Developer/usr/bin
- /Users/x/.rvm/bin
- /Users/x/.config/yarn/global/node_modules/.bin
PLATFORM: darwin x64
FREEMEM: 386052096
TOTALMEM: 17179869184
UPTIME: 231154
LOADAVG: 3.248046875,2.896484375,2.8720703125
CPUS:
- Intel(R) Core(TM) i7-2635QM CPU @ 2.00GHz - 2000
- Intel(R) Core(TM) i7-2635QM CPU @ 2.00GHz - 2000
- Intel(R) Core(TM) i7-2635QM CPU @ 2.00GHz - 2000
- Intel(R) Core(TM) i7-2635QM CPU @ 2.00GHz - 2000
- Intel(R) Core(TM) i7-2635QM CPU @ 2.00GHz - 2000
- Intel(R) Core(TM) i7-2635QM CPU @ 2.00GHz - 2000
- Intel(R) Core(TM) i7-2635QM CPU @ 2.00GHz - 2000
- Intel(R) Core(TM) i7-2635QM CPU @ 2.00GHz - 2000
ENDIANNESS: LE
VERSIONS:
- ares: 1.10.1-DEV
- cldr: 31.0.1
- http_parser: 2.7.0
- icu: 59.1
- modules: 57
- nghttp2: 1.25.0
- node: 8.9.3
- openssl: 1.0.2n
- tz: 2017b
- unicode: 9.0
- uv: 1.15.0
- v8: 6.1.534.48
- zlib: 1.2.11
ERROR Summary:
- broccoliBuilderErrorStack: TypeError: name.definition is not a function
at append_var (eval at <anonymous> (/Users/x/mirai-audio/mir/node_modules/uglify-es/tools/node.js:21:1), <anonymous>:11923:28)
at flatten_vars (eval at <anonymous> (/Users/x/mirai-audio/mir/node_modules/uglify-es/tools/node.js:21:1), <anonymous>:11971:21)
at flatten_fn (eval at <anonymous> (/Users/x/mirai-audio/mir/node_modules/uglify-es/tools/node.js:21:1), <anonymous>:11990:13)
at eval (eval at <anonymous> (/Users/x/mirai-audio/mir/node_modules/uglify-es/tools/node.js:21:1), <anonymous>:11792:44)
at AST_Call.eval [as optimize] (eval at <anonymous> (/Users/x/mirai-audio/mir/node_modules/uglify-es/tools/node.js:21:1), <anonymous>:7666:23)
at Compressor.before (eval at <anonymous> (/Users/x/mirai-audio/mir/node_modules/uglify-es/tools/node.js:21:1), <anonymous>:7649:24)
at AST_Call.eval [as transform] (eval at <anonymous> (/Users/x/mirai-audio/mir/node_modules/uglify-es/tools/node.js:21:1), <anonymous>:4559:35)
at eval (eval at <anonymous> (/Users/x/mirai-audio/mir/node_modules/uglify-es/tools/node.js:21:1), <anonymous>:4618:49)
at Compressor.before (eval at <anonymous> (/Users/x/mirai-audio/mir/node_modules/uglify-es/tools/node.js:21:1), <anonymous>:7644:9)
at AST_Return.eval [as transform] (eval at <anonymous> (/Users/x/mirai-audio/mir/node_modules/uglify-es/tools/node.js:21:1), <anonymous>:4559:35)
- codeFrame: name.definition is not a function
- errorMessage: Build Canceled: Broccoli Builder ran into an error with `UglifyWriter` plugin. 💥
name.definition is not a function
- errorType: Build Error
- location:
- column: [undefined]
- file: [undefined]
- line: [undefined]
- treeDir: [undefined]
- message: Build Canceled: Broccoli Builder ran into an error with `UglifyWriter` plugin. 💥
name.definition is not a function
- name: Error
- nodeAnnotation: UglifyWriter
- nodeName: UglifyWriter
- originalErrorMessage: name.definition is not a function
- stack: TypeError: name.definition is not a function
at append_var (eval at <anonymous> (/Users/x/mirai-audio/mir/node_modules/uglify-es/tools/node.js:21:1), <anonymous>:11923:28)
at flatten_vars (eval at <anonymous> (/Users/x/mirai-audio/mir/node_modules/uglify-es/tools/node.js:21:1), <anonymous>:11971:21)
at flatten_fn (eval at <anonymous> (/Users/x/mirai-audio/mir/node_modules/uglify-es/tools/node.js:21:1), <anonymous>:11990:13)
at eval (eval at <anonymous> (/Users/x/mirai-audio/mir/node_modules/uglify-es/tools/node.js:21:1), <anonymous>:11792:44)
at AST_Call.eval [as optimize] (eval at <anonymous> (/Users/x/mirai-audio/mir/node_modules/uglify-es/tools/node.js:21:1), <anonymous>:7666:23)
at Compressor.before (eval at <anonymous> (/Users/x/mirai-audio/mir/node_modules/uglify-es/tools/node.js:21:1), <anonymous>:7649:24)
at AST_Call.eval [as transform] (eval at <anonymous> (/Users/x/mirai-audio/mir/node_modules/uglify-es/tools/node.js:21:1), <anonymous>:4559:35)
at eval (eval at <anonymous> (/Users/x/mirai-audio/mir/node_modules/uglify-es/tools/node.js:21:1), <anonymous>:4618:49)
at Compressor.before (eval at <anonymous> (/Users/x/mirai-audio/mir/node_modules/uglify-es/tools/node.js:21:1), <anonymous>:7644:9)
at AST_Return.eval [as transform] (eval at <anonymous> (/Users/x/mirai-audio/mir/node_modules/uglify-es/tools/node.js:21:1), <anonymous>:4559:35)
=================================================================================
I narrowed it down to ember-cli-uglify by disabling the addon in my ember-cli-build.js file, at which point builds would succeed.
ember-cli-build.js
module.exports = function(defaults) {
let app = new EmberApp(defaults, {
// ...
'ember-cli-uglify': {
uglify: {
compress: false // added this to workaround the issue
}
},
// ...
more details:
$ember --version --verbose
ember-cli: 3.0.0-beta.2
http_parser: 2.7.0
node: 8.9.3
v8: 6.1.534.48
uv: 1.15.0
zlib: 1.2.11
ares: 1.10.1-DEV
modules: 57
nghttp2: 1.25.0
openssl: 1.0.2n
icu: 59.1
unicode: 9.0
cldr: 31.0.1
tz: 2017b
os: darwin x6
A repo demonstrating the failure is here at this commit:
https://github.com/mirai-audio/mir/tree/7bc4b65df5d01e085c98122c8c8a79542a26dad9
- Ngôn ngữ chính
- JavaScript
- Star
- 23
- Fork
- 23
- 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
Dự án này không cung cấp dev container, Dockerfile hay hướng dẫn đóng góp, nên bạn cần tự thiết lập môi trường: hãy bắt đầu từ README và xem hướng dẫn đóng góp lần đầu của chúng tôi để biết các bước chung.
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 ember-cli/ember-cli-terser
-
Độ khó 3/5 1-2 ngày Mức phù hợp với người mới 35/100
ember-cli/ember-cli-terser#323 ·
-
bug
Độ khó 4/5 3-5 ngày Mức phù hợp với người mới 35/100
ember-cli/ember-cli-terser#287 · 7 bình luận ·
-
Sourcemaps + fingerprinting regression with ember-cli-terser 4.0.2?Có thể làm lại được Pull request cho issue này đã bị đóng mà không được merge. Đang mởbug
Độ khó 4/5 3-5 ngày Mức phù hợp với người mới 32/100
ember-cli/ember-cli-terser#275 · 10 bình luận · 4 reaction ·
Tất cả issue của ember-cli/ember-cli-terser
Issue tương tự
-
`yarn vitest:update` (documented) throws locally; local Cypress scripts target an unserved portĐang mở
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 65/100
rescript-lang/rescript-lang.org#1415 ·
Maintainer thường phản hồi trong vòng 2 ngày
-
bug
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 85/100
Deepak3699/Ai_Mentor#244 ·
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 72/100
antithesishq/bombadil#361 ·
Maintainer thường phản hồi trong vòng 1 ngày
-
ungroomed
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 72/100
dequelabs/axe-core#5455 · 1 bình luận ·
Maintainer thường phản hồi trong vòng 1 ngày
-
Độ khó 1/5 Dưới một giờ Mức phù hợp với người mới 88/100
DietrichGebert/ponytail#1072 ·
Maintainer thường phản hồi trong vòng 3 ngày