Giter Site home page Giter Site logo

Comments (6)

Lalem001 avatar Lalem001 commented on May 14, 2024 1

Yes it looks correct, and it works for me locally.

from karma-rollup-preprocessor.

jlmakes avatar jlmakes commented on May 14, 2024

Can you share a little more about how it breaks?

I'm curious what @rollup/plugin-multi-entry does to the facadeModuleId, I wasn't able to figure that out by looking at its source.

from karma-rollup-preprocessor.

Lalem001 avatar Lalem001 commented on May 14, 2024

@rollup/plugin-multi-entry registers all the files that it processes under a virtual file with the name of \0rollup:plugin-multi-entry:entry-point. facadeModuleId was the only ID property I could find that maintains the null byte. The rest of the properties like fileName replace the null byte with an underscore.

However, I am just discovering that karma itself prevents @rollup/plugin-multi-entry from working as expected in a different way. The plugin is expecting a glob, but Karma is already expanding the glob to individual files. This observation appears to tread on #49.

Still, that doesn't change the fact that tests were passing with karma-rollup-preprocessor 7.0.0, and failing with 7.0.1 with the same rollup config.

Sorry for being brief, I am in a hurry atm. Can expand more later if still needed.

from karma-rollup-preprocessor.

jlmakes avatar jlmakes commented on May 14, 2024

Just following up on this @Lalem001. I'd like to fix this, do you still think your suggestion !hasNullByte() is the best way forward?

from karma-rollup-preprocessor.

Lalem001 avatar Lalem001 commented on May 14, 2024

The suggestion is a possible solution. Karma would never use that particular plugin correctly anyway, since it only sends Rollup (and the preprocessor) 1 file at a time. The solution might resolve problems with other plugins that have not yet been reported.

I will say however that this issue so far has been preventing me from being on latest karma-rollup-preprocessor, and the solution proposed does resolve the issue for me locally.

from karma-rollup-preprocessor.

jlmakes avatar jlmakes commented on May 14, 2024

That makes sense. Well, it seems like a fair precaution to check for null bytes. I updated the development branch, does this look correct to you?

from karma-rollup-preprocessor.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo 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.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.