EXCLUDE_GLOBS causes failure for directory with a git submodule
Nobody has claimed this yet.
Assessment
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Newbie friendliness
- 35/100
- Issue type
- Bug
- Clarity
- Mostly clear
- Activity status
- Stale
- Tech stack
- git, javascript, node.js
- Domain
- build-system, cli
Research direction
Start by reproducing the failure with node-lambda package, a local file:sub-module dependency, and EXCLUDE_GLOBS="sub-module". Inspect the packaging flow around lib/main.js:543 and how EXCLUDE_GLOBS handles submodule directories. Done means the directory can be excluded without npm install failing, while the workaround does not leave sub-module/package.json in the archive.
Written by the indexing model from the issue text.
Description
If a git submodule is listed in package.json
"dependencies": {
....
"sub-module": "file:sub-module"
},
and the directory name is within EXCLUDE_GLOBS
EXCLUDE_GLOBS="sub-module"
the following error occurs.
As a workaround, one can exclude the directory content EXCLUDE_GLOBS="sub-module/*", but this leaves sub-module/package.json in the zip file.
$ node-lambda package
Warning!!! You are building on a platform that is not 64-bit Linux (darwin.x64). If any of your Node dependencies include C-extensions, they may not work as expected in the Lambda environment.
=> Moving files to temporary directory
=> Running npm install --production
/usr/local/lib/node_modules/node-lambda/lib/main.js:543
throw err;
^
Error: Command failed: npm -s install --production --prefix /var/folders/4c/b2p9cxl9699211w4mps998g40000gp/T/apiAccess-1494407987225
at ChildProcess.exithandler (child_process.js:204:12)
at emitTwo (events.js:106:13)
at ChildProcess.emit (events.js:191:7)
at maybeClose (internal/child_process.js:886:16)
at Socket.<anonymous> (internal/child_process.js:342:11)
at emitOne (events.js:96:13)
at Socket.emit (events.js:188:7)
at Pipe._handle.close [as _onclose] (net.js:501:12)
$
- Dominant language
- JavaScript
- Stars
- 1.4k
- Forks
- 185
- PR merge metrics
- No merged PRs in 30d
Contributor guide
No contributing guide indexed for this repository
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
More from motdotla/node-lambda
-
Difficulty 4/5 3-5 days Newbie friendliness 35/100
motdotla/node-lambda#840 · 1 comment ·
-
Difficulty 4/5 3-5 days Newbie friendliness 35/100
motdotla/node-lambda#641 · 6 comments · 2 reactions ·
-
Difficulty 5/5 Over a week Newbie friendliness 15/100
motdotla/node-lambda#618 ·
-
enhancement
Difficulty 4/5 3-5 days Newbie friendliness 30/100
motdotla/node-lambda#544 · 1 reaction ·
-
question
Difficulty 4/5 3-5 days Newbie friendliness 25/100
motdotla/node-lambda#537 · 2 comments · 1 reaction ·
All issues in motdotla/node-lambda
Similar issues
-
bug
Difficulty 2/5 1-3 hours Newbie friendliness 76/100
avniproject/avni-client#2135 ·
-
automated broken-link
Difficulty 1/5 Under an hour Newbie friendliness 85/100
-
agent/security hive/hosted-available-lke648397-260827-5n31 security
Difficulty 2/5 1-3 hours Newbie friendliness 84/100
-
enhancement
Difficulty 2/5 1-3 hours Newbie friendliness 70/100
babalae/bettergi-scripts-list#3674 ·
-
A-Release-Notes C-Editing D-Modest S-Ready-For-Implementation
Difficulty 2/5 1-3 hours Newbie friendliness 72/100
bevyengine/bevy-website#2595 ·