be5invis / Iosevka

Versatile typeface for code, from code.
http://be5invis.github.io/Iosevka
SIL Open Font License 1.1
19.14k stars 567 forks source link

can't build font; "Cannot read property 'belongs' of undefined" #330

Closed CMGS closed 5 years ago

CMGS commented 5 years ago

this is build output

npm run build -- contents::iosevka-term                                                                         git/master !

> iosevka@2.2.1 build /Users/pengzf/Documents/workspace/sources/Iosevka
> verda -f verdafile.js "contents::iosevka-term"

♦ node ./node_modules/patel/bin/patel-c --strict glyphs/common-shapes.ptl -o glyphs/common-shapes.js
♦ node ./node_modules/patel/bin/patel-c --strict glyphs/symbol-geometric.ptl -o glyphs/symbol-geometric.js
♦ node ./node_modules/patel/bin/patel-c --strict glyphs/symbol-math.ptl -o glyphs/symbol-math.js
♦ node ./node_modules/patel/bin/patel-c --strict glyphs/autobuilds.ptl -o glyphs/autobuilds.js
♦ node ./node_modules/patel/bin/patel-c --strict glyphs/letters-unified-basic.ptl -o glyphs/letters-unified-basic.js
♦ node ./node_modules/patel/bin/patel-c --strict glyphs/symbol-other.ptl -o glyphs/symbol-other.js
♦ node ./node_modules/patel/bin/patel-c --strict glyphs/letters-unified-extended.ptl -o glyphs/letters-unified-extended.js
♦ node ./node_modules/patel/bin/patel-c --strict glyphs/symbol-punctuation.ptl -o glyphs/symbol-punctuation.js
TypeError: Cannot read property 'belongs' of undefined
    at Object.<anonymous> (/Users/pengzf/Documents/workspace/sources/Iosevka/node_modules/patrisika/passes/codegen.js:276:21)
    at /Users/pengzf/Documents/workspace/sources/Iosevka/node_modules/patrisika/commons/match.js:74:79
    at /Users/pengzf/Documents/workspace/sources/Iosevka/node_modules/patrisika/passes/codegen.js:25:17
    at Object.isStrict (/Users/pengzf/Documents/workspace/sources/Iosevka/node_modules/patrisika/passes/codegen.js:394:13)
    at /Users/pengzf/Documents/workspace/sources/Iosevka/node_modules/patrisika/commons/match.js:74:79
    at /Users/pengzf/Documents/workspace/sources/Iosevka/node_modules/patrisika/passes/codegen.js:25:17
    at Object.<anonymous> (/Users/pengzf/Documents/workspace/sources/Iosevka/node_modules/patrisika/passes/codegen.js:115:17)
    at /Users/pengzf/Documents/workspace/sources/Iosevka/node_modules/patrisika/commons/match.js:74:79
    at /Users/pengzf/Documents/workspace/sources/Iosevka/node_modules/patrisika/passes/codegen.js:25:17
    at Array.map (<anonymous>)
× Error Unhandled exception when building "Builtin::File::glyphs/symbol-geometric.js":
 { code: 1 }
♦ node ./node_modules/patel/bin/patel-c --strict glyphs/overmarks.ptl -o glyphs/overmarks.js
Building process terminated.npm ERR! code ELIFECYCLE
npm ERR! errno 1
npm ERR! iosevka@2.2.1 build: `verda -f verdafile.js "contents::iosevka-term"`
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the iosevka@2.2.1 build script.
npm ERR! This is probably not a problem with npm. There is likely additional logging output above.

this is npm build logs

0 info it worked if it ends with ok
1 verbose cli [
1 verbose cli   '/usr/local/Cellar/node/12.1.0/bin/node',
1 verbose cli   '/usr/local/bin/npm',
1 verbose cli   'run',
1 verbose cli   'build',
1 verbose cli   '--',
1 verbose cli   'contents::iosevka-term'
1 verbose cli ]
2 info using npm@6.9.0
3 info using node@v12.1.0
4 verbose run-script [ 'prebuild', 'build', 'postbuild' ]
5 info lifecycle iosevka@2.2.1~prebuild: iosevka@2.2.1
6 info lifecycle iosevka@2.2.1~build: iosevka@2.2.1
7 verbose lifecycle iosevka@2.2.1~build: unsafe-perm in lifecycle true
8 verbose lifecycle iosevka@2.2.1~build: PATH: /usr/local/lib/node_modules/npm/node_modules/npm-lifecycle/node-gyp-bin:/Users/pengzf/Documents/workspace/sources/Iosevka/node_modules/.bin:/usr/local/sbin:/usr/local/opt/python/libexec/bin:/Users/pengzf/.go/bin:/usr/local/bin:/usr/bin:/bin:/usr/sbin:/sbin
9 verbose lifecycle iosevka@2.2.1~build: CWD: /Users/pengzf/Documents/workspace/sources/Iosevka
10 silly lifecycle iosevka@2.2.1~build: Args: [ '-c', 'verda -f verdafile.js "contents::iosevka-term"' ]
11 silly lifecycle iosevka@2.2.1~build: Returned: code: 1  signal: null
12 info lifecycle iosevka@2.2.1~build: Failed to exec build script
13 verbose stack Error: iosevka@2.2.1 build: `verda -f verdafile.js "contents::iosevka-term"`
13 verbose stack Exit status 1
13 verbose stack     at EventEmitter.<anonymous> (/usr/local/lib/node_modules/npm/node_modules/npm-lifecycle/index.js:301:16)
13 verbose stack     at EventEmitter.emit (events.js:196:13)
13 verbose stack     at ChildProcess.<anonymous> (/usr/local/lib/node_modules/npm/node_modules/npm-lifecycle/lib/spawn.js:55:14)
13 verbose stack     at ChildProcess.emit (events.js:196:13)
13 verbose stack     at maybeClose (internal/child_process.js:1000:16)
13 verbose stack     at Process.ChildProcess._handle.onexit (internal/child_process.js:267:5)
14 verbose pkgid iosevka@2.2.1
15 verbose cwd /Users/pengzf/Documents/workspace/sources/Iosevka
16 verbose Darwin 18.6.0
17 verbose argv "/usr/local/Cellar/node/12.1.0/bin/node" "/usr/local/bin/npm" "run" "build" "--" "contents::iosevka-term"
18 verbose node v12.1.0
19 verbose npm  v6.9.0
20 error code ELIFECYCLE
21 error errno 1
22 error iosevka@2.2.1 build: `verda -f verdafile.js "contents::iosevka-term"`
22 error Exit status 1
23 error Failed at the iosevka@2.2.1 build script.
23 error This is probably not a problem with npm. There is likely additional logging output above.
24 verbose exit [ 1, true ]
sfktrifork commented 5 years ago

Seeing the same error on dev branch at commit b51a91e613e0ad333b279291351a57465d1b2dbb.

be5invis commented 5 years ago

Have you tried Node 10 instead of 12?


发件人: Sebastian Frelle Koch notifications@github.com 发送时间: Monday, May 27, 2019 8:32:19 AM 收件人: be5invis/Iosevka 抄送: Subscribed 主题: Re: [be5invis/Iosevka] can't build font; "Cannot read property 'belongs' of undefined" (#330)

Seeing the same error on dev branch at commit #b51a91e613e0ad333b279291351a57465d1b2dbb.

― You are receiving this because you are subscribed to this thread. Reply to this email directly, view it on GitHubhttps://nam04.safelinks.protection.outlook.com/?url=https%3A%2F%2Fgithub.com%2Fbe5invis%2FIosevka%2Fissues%2F330%3Femail_source%3Dnotifications%26email_token%3DAAB2TWZK24UCUVSJQKVF5VLPXP5IHA5CNFSM4HMWXGUKYY3PNVWWK3TUL52HS4DFVREXG43VMVBW63LNMVXHJKTDN5WW2ZLOORPWSZGODWKCMZI%23issuecomment-496248421&data=02%7C01%7C%7C158f792fd6d04669c27608d6e2b8820f%7C84df9e7fe9f640afb435aaaaaaaaaaaa%7C1%7C0%7C636945679419837056&sdata=sxje%2BzyYrL6kSjh5IxDV6x%2FWurTA8E6IIY5pIwnPDxg%3D&reserved=0, or mute the threadhttps://nam04.safelinks.protection.outlook.com/?url=https%3A%2F%2Fgithub.com%2Fnotifications%2Funsubscribe-auth%2FAAB2TWYLER7EQ7WPZ2ZVED3PXP5IHANCNFSM4HMWXGUA&data=02%7C01%7C%7C158f792fd6d04669c27608d6e2b8820f%7C84df9e7fe9f640afb435aaaaaaaaaaaa%7C1%7C0%7C636945679419857060&sdata=IzlSXm0wE8Y8ATZqMe1obJ8K3%2Ftv6GtHbAVQGUAT04U%3D&reserved=0.

sfktrifork commented 5 years ago

@be5invis Thank you. I managed to get it working using the following Node/NPM versions:

be5invis commented 5 years ago

Fixed in dev by a fix in the dep. In Node 12 it should work now. Closed.