Starts in:
1 DAY
12 HRS
48 MIN
0 SEC
Starts in:
1 D
12 H
48 M
0 S
Open Closed

source-map not found #2714


User avatar
0
agilmore created
  • ABP Framework version: v5.1.4
  • UI type: Blazor
  • DB provider: EF Core
  • Tiered (MVC) or Identity Server Separated (Angular): no
  • Exception message and stack trace:

Severity Code Description Project File Line Suppression State Error TS6053 File 'C:/Users/agilm/Documents/Repos/Datansa.App/src/Datansa.App.HttpApi.Host/node_modules/source-map/source-map' not found. The file is in the program because: Root file specified for compilation Datansa.App.HttpApi.Host JavaScript Content Files 1 Active

  • Steps to reproduce the issue:" Build Solution

After upgrading from 5.0.1 to 5.1.4, I now get the above error when building.

I've tried abp install-libs , then yarn + abp install-libs in the Datansa.App.HttpApi.Host project. However, this didn't fix the issue.

I've also tried the fix described in this - https://github.com/mozilla/source-map/issues/449

npm ls source-map returns:

C:\Users\agilm\Documents\Repos\Datansa.App\src\Datansa.App.HttpApi.Host>npm ls source-map my-app@1.0.0 C:\Users\agilm\Documents\Repos\Datansa.App\src\Datansa.App.HttpApi.Host -- @volo/abp.aspnetcore.mvc.ui.theme.lepton@5.1.4 -- @volo/abp.aspnetcore.mvc.ui.theme.commercial@5.1.4 -- @abp/aspnetcore.mvc.ui.theme.shared@5.1.4 -- @abp/aspnetcore.mvc.ui@5.1.4 -- gulp@4.0.2 -- glob-watcher@5.0.3 -- anymatch@2.0.0 -- micromatch@3.1.10 -- snapdragon@0.8.2 -- source-map@0.5.7


5 Answer(s)
  • User Avatar
    0
    EngincanV created
    Support Team .NET Developer

    Hi @agilmore, can you check the source-map version? (you can see the version from yarn.lock file)

  • User Avatar
    0
    agilmore created

    Here is the content of my yarn.lock file, where source-map appears.

    ...

    convert-source-map@^1.5.0: version "1.6.0" resolved "https://registry.yarnpkg.com/convert-source-map/-/convert-source-map-1.6.0.tgz#51b537a8c43e0f04dec1993bffcdd504e758ac20" integrity sha512-eFu7XigvxdZ1ETfbgPBohgyQ/Z++C0eEhTor0qRwBw9unw+L0/6V8wkSuGgzdThkiS5lSpdptOQPD8Ak40a+7A== dependencies: safe-buffer "~5.1.1"

    ....

    snapdragon@^0.8.1: version "0.8.2" resolved "https://registry.yarnpkg.com/snapdragon/-/snapdragon-0.8.2.tgz#64922e7c565b0e14204ba1aa7d6964278d25182d" dependencies: base "^0.11.1" debug "^2.2.0" define-property "^0.2.5" extend-shallow "^2.0.1" map-cache "^0.2.2" source-map "^0.5.6" source-map-resolve "^0.5.0" use "^3.1.0"

    ...

    source-map-resolve@^0.5.0: version "0.5.1" resolved "https://registry.yarnpkg.com/source-map-resolve/-/source-map-resolve-0.5.1.tgz#7ad0f593f2281598e854df80f19aae4b92d7a11a" dependencies: atob "^2.0.0" decode-uri-component "^0.2.0" resolve-url "^0.2.1" source-map-url "^0.4.0" urix "^0.1.0"

    source-map-url@^0.4.0: version "0.4.0" resolved "https://registry.yarnpkg.com/source-map-url/-/source-map-url-0.4.0.tgz#3e935d7ddd73631b97659956d55128e87b5084a3"

    source-map@^0.5.6: version "0.5.7" resolved "https://registry.yarnpkg.com/source-map/-/source-map-0.5.7.tgz#8a039d2d1021d22d1ea14c80d8ea468ba2ef3fcc"

    ....

    vinyl-fs@^3.0.0: version "3.0.3" resolved "https://registry.yarnpkg.com/vinyl-fs/-/vinyl-fs-3.0.3.tgz#c85849405f67428feabbbd5c5dbdd64f47d31bc7" integrity sha512-vIu34EkyNyJxmP0jscNzWBSygh7VWhqun6RmqVfXePrOwi9lhvRs//dOaGOTRUQr4tx7/zd26Tk5WeSVZitgng== dependencies: fs-mkdirp-stream "^1.0.0" glob-stream "^6.1.0" graceful-fs "^4.0.0" is-valid-glob "^1.0.0" lazystream "^1.0.0" lead "^1.0.0" object.assign "^4.0.4" pumpify "^1.3.5" readable-stream "^2.3.3" remove-bom-buffer "^3.0.0" remove-bom-stream "^1.2.0" resolve-options "^1.1.0" through2 "^2.0.0" to-through "^2.0.0" value-or-function "^3.0.0" vinyl "^2.0.0" vinyl-sourcemap "^1.1.0"

    vinyl-sourcemap@^1.1.0: version "1.1.0" resolved "https://registry.yarnpkg.com/vinyl-sourcemap/-/vinyl-sourcemap-1.1.0.tgz#92a800593a38703a8cdb11d8b300ad4be63b3e16" integrity sha1-kqgAWTo4cDqM2xHYswCtS+Y7PhY= dependencies: append-buffer "^1.0.2" convert-source-map "^1.5.0" graceful-fs "^4.1.6" normalize-path "^2.1.1" now-and-later "^2.0.0" remove-bom-buffer "^3.0.0" vinyl "^2.0.0"

    vinyl@^2.0.0: version "2.2.0" resolved "https://registry.yarnpkg.com/vinyl/-/vinyl-2.2.0.tgz#d85b07da96e458d25b2ffe19fece9f2caa13ed86" integrity sha512-MBH+yP0kC/GQ5GwBqrTPTzEfiiLjta7hTtvQtbxBgTeSXsmKQRQecjibMbxIXzVT3Y9KJK+drOz1/k+vsu8Nkg== dependencies: clone "^2.1.1" clone-buffer "^1.0.0" clone-stats "^1.0.0" cloneable-readable "^1.0.0" remove-trailing-separator "^1.0.1" replace-ext "^1.0.0" ....

  • User Avatar
    2
    EngincanV created
    Support Team .NET Developer

    Can you try to upgrade the source-map package? You can add a resolutions section to your package.json file as below:

    "resolutions": {
        "source-map": "0.7.3"
    }
    

    and then run the abp install-libs command again.

  • User Avatar
    0
    jhsanc created

    Hello EngincanV, I had the same issue but after I applied your solution I had this issue:

    [1/4] Resolving packages... warning Resolution field "source-map@0.7.3" is incompatible with requested version "source-map@^0.5.6" success Already up-to-date. Done in 0.20s.

  • User Avatar
    0
    EngincanV created
    Support Team .NET Developer

    Hi, this problem is related to VS2021, please see this comment to fix the problem also please revert the change that I've suggested above.

Made with ❤️ on ABP v9.1.0-preview. Updated on November 20, 2024, 13:06