CatoAntonsen / MMM-Ruter

MMM-Ruter is a MagicMirror² module for displaying public transport information for Oslo and Akershus (Norway). It's using data from Ruter.no.
MIT License
19 stars 13 forks source link

Loading endlessly #9

Open G0vernment opened 6 years ago

G0vernment commented 6 years ago

I have written everything in the config file as insstructed but it doesnt show any times, it just shows loading. Forever. Is there sometihng im doing wrong?

{ module: "MMM-Ruter", header: "Ruter", position: "top_left", config: { showplatforms: true, maxItems: 10, stops: [ { stopid: "3011420", platforms: [ "1", "2" ], timeToThere: 5 }, { stopid: "3010013", timeToThere: 10, stopName: "Jernbanetorget" } ]
}
},

harald25 commented 6 years ago

It might be related to some stops only. I'm also experiencing the same with "Jar t-bane": 2190050 and "Jar trikk": 2190051. But I'm having no problems with the bus stop "Bjerkelundsveien": 2190052.

EDIT: My problem was caused by the platforms: variable. I had specified platforms that didn't exist. Have you checked if this might be the cause of your problem too?

paul-gordon commented 6 years ago

I have the exact same issue, and it is definitely related to the platforms variable. If I omit the platforms item entirely, the data for my stop loads & displays correctly. It even shows the platform numbers. The moment I introduce the platforms variable, with any combination of the correct platform numbers, the module sticks permanently on "loading"...

erikmohn commented 6 years ago

Experienced Access-Control-Allow-Origin issues with endless loading, and nothing in logs.

"fixed" with electron.js modification:

            webPreferences: {
                    nodeIntegration: false,
                    zoomFactor: config.zoom,
                    **webSecurity: false**
            },
Axachi commented 5 years ago

Please explaine more where in the code do i put this?

sk9010 commented 5 years ago

Hi, electron.js is located in MagicMirror/js/

Locate webPreferences (in the electron.js file) and add the line mentioned above.

webPreferences: { nodeIntegration: false, zoomFactor: config.zoom, webSecurity: false },

Save and start the service. Fixed the issue for me.