4

I'm completely asea here.

We had a working app build with an old Electron Forge (^5.2.4; 5.2.6) created using the old React template (1.0.2-1.0.4) with the usual suspects of React tech (react-redux, react-router, etc.)

Up until about 1-2 weeks ago everything has been fine. Now, after running its startup code, showing some components, doing some things, then we get a Variant 119 error (ref issues or multiple versions of React).

Since the code used to work the ref thing seems spurious, but I checked all our refs (there are a total of two). I did the usual npm ls and yarn list, even checked a lot of modules for additional Reacts, but found nada.

Our yarn.lock file has not changed other than some internal dependencies that aren't Electron or React related. No external components (BlueprintJS, Semantic UI React, ...) have changed over the course of working-to-non-working.

Here's the kicker: reverting to previously-working versions (including deleting node_modules etc.) doesn't help. The build machine is running the same version of NodeJS as it has been (10.15.mumble). I've tried to track down caches (including Yarn) and deleted them, deleted the out directory, done full rebuilds, etc.

What could be impacting an Electron Forge build like this? What other code, directories, caches, configurations, etc. should I be looking for?

That it impacts previously-working versions points me towards build/environment problems, although this happens across machines, which points back at the project. After multiple days bisecting and rebuilding and having the same thing happen I've paid a visit to Witt's End. And I don't like it there.

1 Answer 1

0

Looking at the error message, it lists two different reasons for the error. It seems you have ruled out multiple react instances in your code, but be wary if you use npm link as that can do weird things with dependencies.

So have you check to see if someone on your project team checked in something that is trying to use a ref where they shouldn’t as that will also cause this error

9
  • No npm/yarn links (one one machine there never was one, on the other it was both unlunk and node_modules replaced anyway). But yep, definitely something that could cause an error--but was checked :) Oct 3, 2019 at 21:53
  • 1
    If you roll the code back, to the day before the problem started. Does that fix it? Would be good to work out if it a code or infrastructure isssue Oct 5, 2019 at 8:46
  • "...reverting to previously-working versions (including deleting node_modules etc.) doesn't help" Oct 5, 2019 at 11:57
  • @DaveNewton check if your app is running in dev environment? (electron /path/to/your/app/dir) Oct 8, 2019 at 0:54
  • @SudhakarRV This is the built app; dev mode works fine. Dev console in built app shows nothing unusual until the error, and reverting to previously-good build does not fix the error even with complete node_modules rebuild. That's why I statted I believe it's explicitly a build issue. Oct 8, 2019 at 2:39

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.