Hi Tim, I don't recall the details exactly, but I bumped into an installation error when running yarn install. The message said that package.json defined a packageManager field, that it was set to yarn 4.10 and that I needed to enable Nodejs CorePack. I wasn't sure about enabling corepack, so I added a packageManager field to the 7.6.2 package.json file, setting it to use yarn 1.22.22.
After that confusion, I might have run yarn upgrade. If so, that was probably my mistake. It would explain how ngx-mask was bumped up to 13.2.2. On Friday, October 25, 2024 at 11:45:40 AM UTC-7 DSpace Technical Support wrote: > Hi Michael, > > That's very odd behavior, because in the "yarn.lock" for DSpace 7.6.2, it > looks like it's using "ngx-mask" version 13.1.15. > > Here's the "yarn.lock" which comes with DSpace 7.6.2: > > https://github.com/DSpace/dspace-angular/blob/dspace-7.6.2/yarn.lock#L8459-L8464 > > Where did you see DSpace using "ngx-mask" version 13.2.2? That > definitely is *wrong*, but I'm confused where that could be coming from. > If we can figure out where it comes from, then that may help us track down > why some people are hitting this error when installing DSpace 7.6.2. > > Thanks, > > Tim > > On Tuesday, October 22, 2024 at 8:19:35 PM UTC-5 msp...@willamette.edu > wrote: > >> >> In case it's helpful....I also just ran into this issue on a fresh 7.6.2 >> install. In yarn.lock, I see that the ngx-mask package resolved to version >> 13.2.2. So I edited package.json to just install bug fix releases using >> "ngx-mask@~13.1.7" and my build succeeded. >> On Thursday, October 17, 2024 at 2:35:16 PM UTC-7 DSpace Technical >> Support wrote: >> >>> All, >>> >>> I encountered this same error today in a Pull Request: >>> >>> ./node_modules/@ng-dynamic-forms/ui-ng-bootstrap/fesm2020/ui-ng-bootstrap.mjs:729:307-323 >>> >>> - Error: export 'MaskDirective' (imported as 'i4') was not found in >>> 'ngx-mask' (possible exports: INITIAL_CONFIG, NEW_CONFIG, NGX_MASK_CONFIG, >>> NgxMaskDirective, NgxMaskModule, NgxMaskPipe, NgxMaskService, >>> _configFactory, initialConfig, timeMasks, withoutValidation) >>> >>> That said, the error ONLY seems to occur when an **incompatible** >>> version of "ngx-mask" is installed. >>> >>> In my case, I saw the error when building this PR: >>> https://github.com/DSpace/dspace-angular/pull/3433 This PR simply >>> updated "ngx-mask" from version 14.2.4 to 14.3.3. But, that error occurs >>> because in "ngx-mask" version 14.3.2 the "MaskDirective" class was renamed >>> to "NgxMaskMaskDirective". See the "ngx-mask" changelog at >>> https://github.com/JsDaddy/ngx-mask/blob/develop/CHANGELOG.md#feature-1432 >>> <https://github.com/JsDaddy/ngx-mask/blob/develop/CHANGELOG.md#feature-1432> >>> >>> However, that doesn't explain why some people are encountering this >>> issue in a "fresh install". The only way I see it is if the wrong version >>> of "ngx-mask" is installed, but in DSpace 7.6.2 and 8.0, we **pin** >>> "ngx-mask" to a compatible version. >>> >>> So, I'm still stumped as to the reason why some people see this error. >>> But, I've at least figured out a different scenario where it also occurs. >>> >>> Tim >>> >>> >>> On Tuesday, August 27, 2024 at 6:36:35 AM UTC-5 Joachim Schneider wrote: >>> >>>> I am on a fresh install of Ubuntu 22.04.4 LTS with NodeJS v18.20.4 and >>>> Yarn 1.22.22 >>>> >>>> $ cd /opt/dspace-frontend >>>> $ yarn clean >>>> $ yarn install >>>> [many warnings] >>>> $ yarn build:prod >>>> yarn run v1.22.22 >>>> $ cross-env NODE_ENV=production yarn run build:ssr >>>> $ ng build --configuration production && ng run >>>> dspace-angular:server:production >>>> ⠙ Generating browser application bundles (phase: setup)...- >>>> angular-idle-preload [main/commonjs] (git+ >>>> https://github.com/gdi2290/angular-idle-preload.git) >>>> - ngx-sortablejs [es2015/esm2015] ( >>>> https://github.com/sortablejs/ngx-sortablejs) >>>> - ng2-file-upload [es2015/esm2015] () >>>> ✔ Browser application bundle generation complete. >>>> [fewer warnings] >>>> ./node_modules/@ng-dynamic-forms/ui-ng-bootstrap/fesm2020/ui-ng-bootstrap.mjs:736:285-301 >>>> >>>> - Error: export 'MaskDirective' (imported as 'i4') was not found in >>>> 'ngx-mask' (possible exports: INITIAL_CONFIG, NEW_CONFIG, NGX_MASK_CONFIG, >>>> NgxMaskDirective, NgxMaskModule, NgxMaskPipe, NgxMaskService, >>>> _configFactory, initialConfig, timeMasks, withoutValidation) >>>> >>>> >>>> error Command failed with exit code 1. >>>> info Visit https://yarnpkg.com/en/docs/cli/run for documentation about >>>> this command. >>>> error Command failed with exit code 1. >>>> info Visit https://yarnpkg.com/en/docs/cli/run for documentation about >>>> this command. >>>> >>>> HTH. If I can help any more with logs or anything, just give me a hint >>>> :) >>>> On Tuesday, May 7, 2024 at 8:15:17 p.m. UTC+2 DSpace Technical Support >>>> wrote: >>>> >>>>> For folks who are hitting this strange error ("export 'MaskDirective' >>>>> (imported as 'i4') was not found in 'ngx-mask'"), could you share what >>>>> version of Node you are using? And what operating system? >>>>> >>>>> While searching around, I came across a similar error on StackOverflow >>>>> (not specific to DSpace). In this scenario, the person said it only >>>>> occurs >>>>> with Node v18, while Node v16 works fine: >>>>> https://stackoverflow.com/questions/78236715/how-to-solve-error-export-maskdirective-imported-as-i8-was-not-found-in-n >>>>> >>>>> I'm not able to reproduce this error on Windows 11 using Node v18.20.2 >>>>> & it's not occurred in our automatic build testing on Ubuntu (also using >>>>> Node 18). But, it sounds like several of you are hitting this error. >>>>> So, >>>>> maybe it's somehow specific to a version of Node? Or specific to an >>>>> Operating System? >>>>> >>>>> Overall, this error is referencing *dependencies* of DSpace >>>>> (@ng-dynamic-forms and ngx-mask), and not DSpace itself. This is why I'm >>>>> starting to wonder if there are specific build environments where these >>>>> dependencies are not working properly. >>>>> >>>>> If anyone has found a solution, hopefully they will share it so that >>>>> we can document it. >>>>> >>>>> Tim >>>>> On Tuesday, May 7, 2024 at 12:53:47 PM UTC-5 dto...@uw.edu wrote: >>>>> >>>>>> Did the folks who ran into this error ever figure out how to resolve >>>>>> it? I too am running into the error, even after Tim's troubleshooting >>>>>> steps. >>>>>> >>>>>> Thanks, >>>>>> >>>>>> -Dave >>>>>> >>>>>> On Saturday, April 20, 2024 at 7:06:12 AM UTC-7 Abdelouahab Djoudi >>>>>> wrote: >>>>>> >>>>>> >>>>>> i have the same issue >>>>>> On Thursday, March 28, 2024 at 10:58:00 PM UTC+1 DSpace Technical >>>>>> Support wrote: >>>>>> >>>>>> That sounds like an error because something didn't install properly. >>>>>> I'd recommend re-running the "yarn install" by doing this: >>>>>> >>>>>> # Clean current cached data >>>>>> yarn clean >>>>>> >>>>>> # Reinstall all dependencies >>>>>> yarn install >>>>>> >>>>>> # Try to build again >>>>>> yarn build:prod >>>>>> >>>>>> Hopefully it will succeed this time, as it sounds like it's >>>>>> complaining that a dependency wasn't fully installed in that "yarn >>>>>> install" >>>>>> step. >>>>>> >>>>>> Tim >>>>>> >>>>>> On Thursday, March 21, 2024 at 4:14:01 AM UTC-5 stb...@gmail.com >>>>>> wrote: >>>>>> >>>>>> Dear all, >>>>>> >>>>>> after building yarn build:prod I have got the error message: >>>>>> >>>>>> ./node_modules/@ng-dynamic-forms/ui-ng-bootstrap/fesm2020/ui-ng-bootstrap.mjs:736:285-301 >>>>>> >>>>>> - Error: export 'MaskDirective' (imported as 'i4') was not found in >>>>>> 'ngx-mask' (possible exports: INITIAL_CONFIG, NEW_CONFIG, >>>>>> NGX_MASK_CONFIG, >>>>>> NgxMaskDirective, NgxMaskModule, NgxMaskPipe, NgxMaskService, >>>>>> _configFactory, initialConfig, timeMasks, withoutValidation) >>>>>> >>>>>> What should I do now? >>>>>> >>>>>> Thanking you in advance >>>>>> Stefanie >>>>>> >>>>>> -- All messages to this mailing list should adhere to the Code of Conduct: https://www.lyrasis.org/about/Pages/Code-of-Conduct.aspx --- You received this message because you are subscribed to the Google Groups "DSpace Technical Support" group. To unsubscribe from this group and stop receiving emails from it, send an email to dspace-tech+unsubscr...@googlegroups.com. To view this discussion visit https://groups.google.com/d/msgid/dspace-tech/50cdb812-7765-4677-bfa1-2ebccfd2b6d0n%40googlegroups.com.