Comments (12)
Exactly: winston
uses colors
in an affected version (all versions >1.4.0 are affected):
https://github.com/winstonjs/winston/blob/65ab472f54906c72c6c72cffc0a12c9f1d0fe995/package.json#L46
The dependency on colors
should be pinned to version 1.4.0
. See Marak/colors.js#285
from module-packer.
It does use 1.4.0, but it is affecting my system(s) still. Idk if I am doing something wrong. I just removed my own fork since I don't need a logger.
from module-packer.
@PiSaucer you may have to use npm / yarn resolutions to pin it or check your lockfile. And the package.json should use "1.4.0"
, without any ~
or ^
.
from module-packer.
The package file of winston
states ^1.4.0
, so NPM would update to the newest 1.4.x version, which is affected. So you are probably using a newer version.
As @DanielRuf said, check the package-lock file and explicitly set 1.4.0
.
from module-packer.
After removing the ^
I get following errors:
Error: Cannot find module 'color'
Require stack:
- /module-packer/source/node_modules/colorspace/index.js
- /module-packer/source/node_modules/@dabh/diagnostics/modifiers/namespace-ansi.js
- /module-packer/source/node_modules/@dabh/diagnostics/node/development.js
- /module-packer/source/node_modules/@dabh/diagnostics/node/index.js
- /module-packer/source/node_modules/winston/lib/winston/exception-handler.js
- /module-packer/source/node_modules/winston/lib/winston/logger.js
- /module-packer/source/node_modules/winston/lib/winston/create-logger.js
- /module-packer/source/node_modules/winston/lib/winston.js
- /module-packer/source/cli-out/cli/main.js
at Function.Module._resolveFilename (node:internal/modules/cjs/loader:933:15)
at Function.Module._load (node:internal/modules/cjs/loader:778:27)
at Module.require (node:internal/modules/cjs/loader:999:19)
at require (node:internal/modules/cjs/helpers:102:18)
at Object.<anonymous> (/module-packer/source/node_modules/colorspace/index.js:3:13)
at Module._compile (node:internal/modules/cjs/loader:1097:14)
at Object.Module._extensions..js (node:internal/modules/cjs/loader:1149:10)
at Module.load (node:internal/modules/cjs/loader:975:32)
at Function.Module._load (node:internal/modules/cjs/loader:822:12)
at Module.require (node:internal/modules/cjs/loader:999:19) {
code: 'MODULE_NOT_FOUND',
requireStack: [
'/module-packer/source/node_modules/colorspace/index.js',
'/module-packer/source/node_modules/@dabh/diagnostics/modifiers/namespace-ansi.js',
'/module-packer/source/node_modules/@dabh/diagnostics/node/development.js',
'/module-packer/source/node_modules/@dabh/diagnostics/node/index.js',
'/module-packer/source/node_modules/winston/lib/winston/exception-handler.js',
'/module-packer/source/node_modules/winston/lib/winston/logger.js',
'/module-packer/source/node_modules/winston/lib/winston/create-logger.js',
'/module-packer/source/node_modules/winston/lib/winston.js',
'/module-packer/source/cli-out/cli/main.js'
]
}
Node.js v17.1.0
from module-packer.
Looks like you forgot an s
:
Error: Cannot find module 'color'
from module-packer.
@PiSaucer the package is named colors
, not color
.
from module-packer.
This is Winston's Package:
{
"name": "winston",
"description": "A logger for just about everything.",
"version": "3.3.3",
"author": "Charlie Robbins <[email protected]>",
"maintainers": [
"Jarrett Cruger <[email protected]>",
"Chris Alderson <[email protected]>",
"David Hyde <[email protected]>"
],
"repository": {
"type": "git",
"url": "https://github.com/winstonjs/winston.git"
},
"keywords": [
"winston",
"logger",
"logging",
"logs",
"sysadmin",
"bunyan",
"pino",
"loglevel",
"tools",
"json",
"stream"
],
"dependencies": {
"async": "^3.1.0",
"@dabh/diagnostics": "^2.0.2",
"is-stream": "^2.0.0",
"logform": "^2.2.0",
"one-time": "^1.0.0",
"readable-stream": "^3.4.0",
"stack-trace": "0.0.x",
"triple-beam": "^1.3.0",
"winston-transport": "^4.4.0"
},
"devDependencies": {
"@babel/cli": "^7.10.3",
"@babel/core": "^7.10.3",
"@babel/preset-env": "^7.10.3",
"@types/node": "^14.0.13",
"abstract-winston-transport": "^0.5.1",
"assume": "^2.2.0",
"colors": "1.4.0",
"cross-spawn-async": "^2.2.5",
"eslint-config-populist": "^4.2.0",
"hock": "^1.4.1",
"mocha": "^8.0.1",
"nyc": "^15.1.0",
"rimraf": "^3.0.2",
"split2": "^3.1.1",
"std-mocks": "^1.0.1",
"through2": "^3.0.1",
"winston-compat": "^0.1.5"
},
"main": "./lib/winston",
"browser": "./dist/winston",
"types": "./index.d.ts",
"scripts": {
"lint": "populist lib/*.js lib/winston/*.js lib/winston/**/*.js",
"pretest": "npm run lint",
"test": "nyc --reporter=text --reporter lcov npm run test:mocha",
"test:mocha": "mocha test/*.test.js test/**/*.test.js --exit",
"build": "./node_modules/.bin/rimraf dist && babel lib -d dist",
"prepublishOnly": "npm run build"
},
"engines": {
"node": ">= 6.4.0"
},
"license": "MIT"
}
from module-packer.
After changing Winston's Package and installing [email protected] (from the colorspace package), it is acting as normal. To me, this seems like a hassle to do each time a person wants to install module-packer. Hopefully, there is a more permanent fix soon.
from module-packer.
@PiSaucer please try npm / yarn resolutions
https://www.npmjs.com/package/npm-force-resolutions
https://stackoverflow.com/questions/52416312/npm-equivalent-of-yarn-resolutions
https://classic.yarnpkg.com/lang/en/docs/selective-version-resolutions/
from module-packer.
Winston has fixed the issue, so their next release should work normally again: winstonjs/winston#2007
from module-packer.
Thank you for reporting that for me. I appreciate your time and help.
from module-packer.
Related Issues (20)
- Add support for items and spell compendium entries like monsters HOT 1
- The Module Name field is immediately dismissed when pressing Create Module Project File. HOT 1
- Ability to hide a group but process pages. HOT 4
- Feature Request: Publish vscode extension in OpenVSX HOT 1
- Generate PDFs in A4 HOT 3
- Include more of the Solbera Fonts in the global.css file HOT 1
- Create a full-width "sidebar" style HOT 1
- Add support for font-awesome HOT 1
- Advanced.md Additions Request HOT 1
- Absolute image paths should be prefixed with "." not the current directory HOT 2
- Enhancement: Spells HOT 4
- images are not Visible for items handouts like monsters HOT 2
- Add a `references` section to the Module.yaml HOT 1
- Exported Map's Background Image Not Appearing on iOS Import HOT 4
- Values of items are not displayed in Markdown HOT 2
- Two columns display HOT 2
- Incorrect header style in default text block HOT 2
- Internationalization for Spells, Items and Monsters HOT 2
- Problem with Cyrillic characters HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from module-packer.