Coder Social home page Coder Social logo

Comments (8)

VerteDinde avatar VerteDinde commented on September 27, 2024 2

Hey @sps-gold, unfortunately Spectron is fairly dependent on the remote module. This module was deprecated in Electron 12, and In Electron 14 it was removed from Electron itself for security reasons, replaced by an external @electron/remote module. Spectron is currently largely unmaintained, and fixing Spectron to work without the remote module will require a fairly large refactor (we provided more information in an issue in the spring here: #896).

We're working on getting Spectron up and running, but it unfortunately may take some time. Apologies for the delay!

from spectron.

sps-gold avatar sps-gold commented on September 27, 2024 2

Thank you @VerteDinde for looking into it and for the updates.
Its no longer a blocker for me now after I managed to get the tests running with electron 14 and following changes:

Here's what I did,

  1. upgrade spectron packages like - #1031
    (actually for now I just upgraded packages in my own package.json without touching spectron package)
  2. update chromedriver in wdio config
    drivers: {
    chrome: {
    version: "93.0.4577.15",

from spectron.

sps-gold avatar sps-gold commented on September 27, 2024 1

following PR looks similar you may follow to debug error in your case - #738

from spectron.

juanmartin avatar juanmartin commented on September 27, 2024

@sps-gold Where did you edit the wdio config? I can't find it in my project. Need to fix the same issue as my tests are failing due to having Electron v14 and Spectron v15 which still uses Chromium 91 where I need 93.

from spectron.

juanmartin avatar juanmartin commented on September 27, 2024

I have tried locking down electron-chromedriver dependency of Spectron to v14 to have Chrome v93 within my project but my tests throw:

javascript error: Cannot convert undefined or null to object

when doing app.start()
They used to work on older versions

from spectron.

sps-gold avatar sps-gold commented on September 27, 2024

@juanmartin my project uses selenium standalone service, so I can just update the configuration to specify chromedriver version as in documentation here https://webdriver.io/docs/selenium-standalone-service/

from spectron.

juanmartin avatar juanmartin commented on September 27, 2024

following PR looks similar you may follow to debug error in your case - #738

Yeah I stumbled upon that one, so it seems to be needing electron.remote which was completely deprecated in v14.
I've migrated to use @electron/remote in our project. Does this mean I cannot use Spectron anymore until it moves to @electron/remote or is there a way I can force the use of this module within Spectron?

from spectron.

sps-gold avatar sps-gold commented on September 27, 2024

closing as spectron is deprecated.

from spectron.

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.