Haul: @haul-bundler runtime.logger.debug is not function

Created on 18 Jul 2019  路  3Comments  路  Source: callstack/haul

Environment

npm dependencies

 {
    "@types/typescript": "^2.0.0",
    "@types/webpack-merge": "^4.1.5",
    "babel-loader": "^8.0.6",
    "react": "^16.8.6",
    "react-native": "0.60.3",
    "ts-loader": "^6.0.4",
    "typescript": "^3.5.3",
    "webpack-merge": "^4.2.1"
},

Error Log

/build/webpack/reso
lvers/AssetResolver.js:97
        runtime.logger.debug(`Reso
lved file: ${request.path} <--> ${
resolvedFile.path}`);


TypeError: runtime.logger.debug is
 not a function
    at resolver.fileSystem.readdir

Description

haul with typescript cause error runtime doesn't have logger.debug with transform option. Does anyone have an idea why this occur.

Reproducible Demo

reproduce by https://github.com/tkow/haul-test
this repository configuration works at previous version of react-native and [email protected]

bug

Most helpful comment

smartMerge probably was loosing a reference since the logger there was a Proxy. I switched it to built-in proxy support in logger so the smartMerge is handling it properly.

All 3 comments

@tkow It should be fixed now and will be released today EOD.

Thank you for very quick fix!
I survey this and this doesn't occur when I avoid to use smartMerge and keep module.rooms refs by no modifications in my configuration.

config.resolve.extensions = config.resolve.extensions.concat(addConfig.resolve.extensions)
config.module.rules = config.module.rules.concat(addConfig.module.rules)

So I think this problem could be caused by reference lost though I'm not certain. I'll be glad to hear If this is cared next release.

smartMerge probably was loosing a reference since the logger there was a Proxy. I switched it to built-in proxy support in logger so the smartMerge is handling it properly.

Was this page helpful?
0 / 5 - 0 ratings

Related issues

EamonnLaffey picture EamonnLaffey  路  5Comments

Natteke picture Natteke  路  6Comments

satya164 picture satya164  路  7Comments

jurajkrivda picture jurajkrivda  路  4Comments

satya164 picture satya164  路  5Comments