Closed george-dilthey closed 2 years ago
Thank you for your feedback!' first issue
@george-dilthey will you please post your Magic Mirror Config here in its entirety as well as populate your issue with the requested info that was left blank.
Thanks!
please remove any or all api keys from said file, and replace them with #####
Sure!
To reproduce: Git clone into the modules folder, cd into the MMM-nyc-transit folder, npm install, restart magic mirror.
Screenshot of error in MM logs
Platform: Node version: 14.17.4 Electron version: 1.12.4 Running on raspberry pi 4 runnin raspbian. I'm ssh'd in through a macbook pro running the latest version of Big sur.
Here's my config file in entirety: `let config = { address: "localhost", // Address to listen on, can be: // - "localhost", "127.0.0.1", "::1" to listen on loopback interface // - another specific IPv4/6 to listen on a specific interface // - "0.0.0.0", "::" to listen on any interface // Default, when address config is left out or empty, is "localhost" port: 8080, basePath: "/", // The URL path where MagicMirror is hosted. If you are using a Reverse proxy // you must set the sub path here. basePath must end with a / ipWhitelist: ["127.0.0.1", "::ffff:127.0.0.1", "::1"], // Set [] to allow all IP addresses // or add a specific IPv4 of 192.168.1.5 : // ["127.0.0.1", "::ffff:127.0.0.1", "::1", "::ffff:192.168.1.5"], // or IPv4 range of 192.168.3.0 --> 192.168.3.15 use CIDR format : // ["127.0.0.1", "::ffff:127.0.0.1", "::1", "::ffff:192.168.3.0/28"],
useHttps: false, // Support HTTPS or not, default "false" will use HTTP
httpsPrivateKey: "", // HTTPS private key path, only require when useHttps is true
httpsCertificate: "", // HTTPS Certificate path, only require when useHttps is true
language: "en",
locale: "en-US",
logLevel: ["INFO", "LOG", "WARN", "ERROR"], // Add "DEBUG" for even more logging
timeFormat: 12,
units: "metric",
// serverOnly: true/false/"local" ,
// local for armv6l processors, default
// starts serveronly and then starts chrome browser
// false, default for all NON-armv6l devices
// true, force serveronly mode, because you want to.. no UI on this device
modules: [
{
module: "alert",
},
{
module: 'MMM-Unsplash',
position: 'fullscreen_below',
config: {
collections: '369966,1240111,1136512,629911,150672,920773,461370',
apiKey: '####',
updateInterval: '100',
orientation: 'portrait'
}
},
{
module: 'MMM-nyc-transit',
position: "top_bar",
header: "Next Train",
config: {
apiKey: '######',
displayType: 'list',
mtaType: 'train',
stations: [
{
stationId: 237,
walkingTime: 5,
dir: {
upTown: false,
downTown: true
}
},
{
stationId: 177,
walkingTime: 5,
dir: {
upTown: true,
downTown: false
}
}
],
updateInterval: 300000
}
},
{
module: "updatenotification",
position: "top_bar"
},
{
module: "clock",
position: "top_left",
config: {
timeFormat: 12,
displaySeconds: false,
showSunTimes: true,
lat: "40.752470",
lon: "-73.940760",
dateFormat: "dddd, MMMM D"
}
},
{
module: "calendar",
position: "top_left",
config: {
maximumNumberOfDays: 5,
maximumEntries: 5,
displaySymbol: false,
calendars: [
{
url: "######"
}
]
}
},
{
module: 'MMM-MyCommute',
position: 'top_left',
header: 'Commute',
classes: 'default everyone',
config: {
apiKey: "######",
origin: "#######",
showError: false,
destinations: [
{
destination: '######',
label: '#####',
mode: 'transit',
color: '#82E5AA',
showNextVehicleDeparture: true,
// startTime: '16:00',
// endTime: '19:00'
},
{
destination: '#####',
label: '###',
mode: 'transit',
showNextVehicleDeparture: true,
// startTime: '07:00',
// endTime: '10:00'
},
]
}
},
{
module:"MyCovid19",
position:"middle_center",
header: "COVID-19 Cases",
config:{
counties: [{'New York City':'New York'}],
//note the ':' between the county and state name
// one of countries or states or counties MUST be specified
// line colors can be any definition of color either a name ,or a hex string
// one per country above, used in order,
line_colors:['white', 'blue'],
//
chart_type:"cases", // or "cumulative deaths"
chart_title:"", // however u want to label
// the vertical steps on the chart.. how tall u want it to be and how mant increments
ranges:{min:0,max:8000,stepSize:10000},
// size of the chart in pixels
width: 900,
height: 300,
startDate: "03/01/2020",
backgroundColor: ""
}
},
{
module: "compliments",
position: "lower_third",
config: {
remoteFile: 'new_compliments.json'
}
},
{
module: "MMM-DarkSkyForecast",
position: "top_right",
classes: "default everyone",
disabled: false,
config: {
apikey: "#####",
latitude: "####",
longitude: "-####",
iconset: "3c",
concise: true,
forecastLayout: "tiled",
units: "us",
showExtraCurrentConditions: false,
showWind: false,
showDailyForecast: false,
maxHourliesToShow: 3
}
},
{
module: "MMM-DarkSkyForecast",
position: "top_right",
classes: "default everyone",
disabled: false,
config: {
apikey: "#####",
latitude: "####",
longitude: "-####",
iconset: "3c",
concise: true,
forecastLayout: "tiled",
units: "us",
showExtraCurrentConditions: false,
showSummary: false,
showWind: false,
showHourlyForecast: false,
maxDailiesToShow: 3,
showCurrentConditions: false,
requestDelay: 250
}
},
{
module: "MMM-NowPlayingOnSpotify",
position: "bottom_left",
header: "Now Playing",
config: {
clientID: "###",
clientSecret: "#####",
accessToken: "####",
showCoverArt: false
}
},
{
module: 'MMM-WiFiPassword',
position: "bottom_right",
config: {
//See 'Configuration options' for more information.
header: "Wifi Info",
network: "###",
password: "###",
showAuthType: false
}
},
{
module: "newsfeed",
position: "bottom_bar",
config: {
feeds: [
{
title: "New York Times",
url: "https://rss.nytimes.com/services/xml/rss/nyt/HomePage.xml"
},
{
title: "Politco",
url: "http://www.politico.com/rss/politicopicks.xml"
},
{
title: "NPR",
url: "http://www.npr.org/rss/rss.php?id=1001"
},
{
title: "New York Times",
url: "https://rss.nytimes.com/services/xml/rss/nyt/NYRegion.xml"
},
{
title: "New York Times",
url: "https://rss.nytimes.com/services/xml/rss/nyt/World.xml"
},
{
title: "BBC",
url: "http://feeds.bbci.co.uk/news/world/rss.xml"
}
],
showSourceTitle: true,
showPublishDate: true,
ignoreOldItems: true,
ignoreOlderThan: 172800000
}
},
]
};
/ DO NOT EDIT THE LINE BELOW / if (typeof module !== "undefined") {module.exports = config;}`
Thank you for sharing. Can you please remove all modules except the MMM-nyc-transit
and restart the application to see if the error persists?
And where did you obtain your API key from?
API key is from the site you posted (and I refreshed it too). I wonāt be able to try without the modules until next week as Iāve just gone out of town. But I can say it was one of the first modules I tried and the problem has persisted from the get go.
Having the same issue of the train status not showing but the "Next Train" header is. Fairly new to this so I'm not sure how to run a debug.
`/ Magic Mirror Config Sample
*/
var config = { address: "0.0.0.0", // Address to listen on, can be: // - "localhost", "127.0.0.1", "::1" to listen on loopback interface // - another specific IPv4/6 to listen on a specific interface // - "0.0.0.0", "::" to listen on any interface // Default, when address config is left out or empty, is "localhost" port: 8080, basePath: "/", // The URL path where MagicMirror is hosted. If you are using a Reverse proxy // you must set the sub path here. basePath must end with a / ipWhitelist: [], // Set [] to allow all IP addresses // or add a specific IPv4 of 192.168.1.5 : // ["127.0.0.1", "::ffff:127.0.0.1", "::1", "::ffff:192.168.1.5"], // or IPv4 range of 192.168.3.0 --> 192.168.3.15 use CIDR format : // ["127.0.0.1", "::ffff:127.0.0.1", "::1", "::ffff:192.168.3.0/28"],
useHttps: false, // Support HTTPS or not, default "false" will use HTTP
httpsPrivateKey: "", // HTTPS private key path, only require when useHttps is true
httpsCertificate: "", // HTTPS Certificate path, only require when useHttps is true
language: "en",
locale: "en-US",
logLevel: ["INFO", "LOG", "WARN", "ERROR"], // Add "DEBUG" for even more logging
timeFormat: 12,
units: "imperial",
useBeaufort: false,
// serverOnly: true/false/"local" ,
// local for armv6l processors, default
// starts serveronly and then starts chrome browser
// false, default for all NON-armv6l devices
// true, force serveronly mode, because you want to.. no UI on this device
modules: [
{
module: "alert",
},
{
module: "updatenotification",
position: "top_bar"
},
{
module: "clock",
position: "top_left",
config: {
displaySeconds: false,
showSunTimes: false,
}
},
{
module: "calendar",
header: "Calendar",
position: "top_left",
config: {
fullDayEventDateFormat: "dddd",
wrapEvents: true,
wrapLocationEvents: true,
calendars: [
{
symbol: "calendars",
url: "webcal://www.calendarlabs.com/ical-calendar/ics/76/US_Holidays.ics",
},
]
}
},
{
module: "MMM-OpenmapWeather",
position: "top_right", // This can be any of the regions. Best results in left or right regions.
header: "Current Weather", //Location is the default value if header is empty or not defined.
config: {
// See 'Configuration options' for more information.
location: "brooklyn,USA",
locationID: "5128581", //Location ID from http://openweathermap.org/help/city_list.txt
roundTemp: true,
degreeLabel: false,
showHumidity: true,
appid: "#####", //openweathermap.org API key
colorIcon: true
}
},
/*{
module: "weather",
position: "top_right",
config: {
weatherProvider: "openweathermap",
type: "current",
location: "Brooklyn, NY",
locationID: "5128581", //ID from http://bulk.openweathermap.org/sample/city.list.json.gz; unzip the gz file and find your city
apiKey: "#####",
useBeaufort: false,
showHumidity: true,
windUnits: "mph",
roundTemp: true
}
},*/
{
module: "weather",
position: "top_right",
header: "Weather Forecast",
config: {
weatherProvider: "openweathermap",
type: "forecast",
location: "Brooklyn, NY",
locationID: "5128581", //ID from http://bulk.openweathermap.org/sample/city.list.json.gz; unzip the gz file and find your city
apiKey: "#####",
showPrecipitationAmount: true,
roundTemp: true,
colored: true,
}
},
{
module: "newsfeed",
position: "bottom_bar",
config: {
feeds: [
{
title: "New York Times",
url: "https://rss.nytimes.com/services/xml/rss/nyt/HomePage.xml",
},
{
title: "CNN",
url: "http://rss.cnn.com/rss/cnn_topstories.rss"
},
],
showSourceTitle: true,
showPublishDate: true,
broadcastNewsFeeds: true,
broadcastNewsUpdates: true,
showDescription: true,
updateInterval: 30000,
}
},
{
module: "MMM-nyc-transit",
position: "top_bar",
header: "Next Train",
config: {
apiKey: "#####",
displayType: "list",
mtaType: "train",
stations: [
{
stationId: 39,
walkingTime: 5,
dir: {
upTown: true,
downTown: false
}
},
],
updateInterval: 300000
}
},
{
module: "MMM-MyScoreboard",
position: "top_right",
classes: "default everyone",
header: "My Scoreboard",
config: {
showLeagueSeparators: true,
colored: true,
rolloverHours: 12,
viewStyle: "mediumLogos",
sports: [
{
league: "NHL",
teams: ["NYR"]
},
{
league: "MLB",
teams: ["MIL", "NYY"]
},
{
league: "NFL",
teams:["GB"]
},
{
league: "ENG_PREMIERE_LEAGUE",
teams:["ARS"]
},
{
league: "UEFA_EUROPA",
teams:["ARS"]
},
{
league: "UEFA_CHAMPIONS",
teams:["ARS"]
},
{
league: "ENG_FA_CUP",
teams:["ARS"]
},
{
league: "UEFA_EUROPEAN_CHAMPIONSHIP",
},
{
league: "FIFA_WORLD_CUP",
},
{
league: "NBA",
teams:["MIL"]
},
]
}
},
]
};
/ DO NOT EDIT THE LINE BELOW / if (typeof module !== "undefined") {module.exports = config;} `
@stern1978 & @george-dilthey have you tried running the app locally on your machine? And what version of Magic Mirror are you currently using?
Run it locally:
git clone magic mirror, and clone this module into magicmirror/modules
dir and set it up and run npm start
Hiya! I have run it locally and I just cloned down MM a few days ago so I presume the latest version, but I could try to do it again when I get home and check the version.
@Elaniobro ran it locally and it worked. Quit it and ran in server only and it works there now too.
@stern1978, for my own edification, will you please inform me which version of magic mirror you are running? You may find that here
2.16.0
@stern1978; I assume you have no lingering issues now? What type of Raspberry Pi do you have?
@george-dilthey; Please confirm the version of both MM and this module that you are using, as well as if you ran npm/yarn install
in the module itself, withing the magic-mirror/modules
dir
All good now. Thanks.
Raspberry Pi 3 Model B Plus Rev 1.3
I'm seeing the same issue where I can only see the header but the train info does not populate anymore.
Note: this was working for me for months but just stopped working recently.
MM v. 2.16.0 running locally RPi v4 Cloned a brand new instance of MM and MMM-nyc-transit for test.
/* Magic Mirror Config Sample
*
* By Michael Teeuw https://michaelteeuw.nl
* MIT Licensed.
*
* For more information on how you can configure this file
* see https://docs.magicmirror.builders/getting-started/configuration.html#general
* and https://docs.magicmirror.builders/modules/configuration.html
*/
let config = {
address: "localhost", // Address to listen on, can be:
// - "localhost", "127.0.0.1", "::1" to listen on loopback interface
// - another specific IPv4/6 to listen on a specific interface
// - "0.0.0.0", "::" to listen on any interface
// Default, when address config is left out or empty, is "localhost"
port: 8080,
basePath: "/", // The URL path where MagicMirror is hosted. If you are using a Reverse proxy
// you must set the sub path here. basePath must end with a /
ipWhitelist: ["127.0.0.1", "::ffff:127.0.0.1", "::1"], // Set [] to allow all IP addresses
// or add a specific IPv4 of 192.168.1.5 :
// ["127.0.0.1", "::ffff:127.0.0.1", "::1", "::ffff:192.168.1.5"],
// or IPv4 range of 192.168.3.0 --> 192.168.3.15 use CIDR format :
// ["127.0.0.1", "::ffff:127.0.0.1", "::1", "::ffff:192.168.3.0/28"],
useHttps: false, // Support HTTPS or not, default "false" will use HTTP
httpsPrivateKey: "", // HTTPS private key path, only require when useHttps is true
httpsCertificate: "", // HTTPS Certificate path, only require when useHttps is true
language: "en",
locale: "en-US",
logLevel: ["INFO", "LOG", "WARN", "ERROR"], // Add "DEBUG" for even more logging
timeFormat: 24,
units: "metric",
// serverOnly: true/false/"local" ,
// local for armv6l processors, default
// starts serveronly and then starts chrome browser
// false, default for all NON-armv6l devices
// true, force serveronly mode, because you want to.. no UI on this device
modules: [
{
module: "alert",
},
{
module: "updatenotification",
position: "top_bar"
},
{
module: "clock",
position: "top_left"
},
{
module: "calendar",
header: "US Holidays",
position: "top_left",
config: {
calendars: [
{
symbol: "calendar-check",
url: "webcal://www.calendarlabs.com/ical-calendar/ics/76/US_Holidays.ics" }
]
}
},
{
module: 'MMM-nyc-transit',
position: "top_bar",
header: "Next Train",
config: {
apiKey: 'my_api_was_here_from_mta.info_',
displayType: 'list',
mtaType: 'train',
stations: [
{
stationId: 237,
walkingTime: 5,
dir: {
upTown: false,
downTown: true
}
},
{
stationId: 177,
walkingTime: 5,
dir: {
upTown: true,
downTown: false
}
}
],
updateInterval: 300000
}
},
{
module: "compliments",
position: "lower_third"
},
{
module: "weather",
position: "top_right",
config: {
weatherProvider: "openweathermap",
type: "current",
location: "New York",
locationID: "5128581", //ID from http://bulk.openweathermap.org/sample/city.list.json.gz; unzip the gz file and find your city
apiKey: "YOUR_OPENWEATHER_API_KEY"
}
},
{
module: "weather",
position: "top_right",
header: "Weather Forecast",
config: {
weatherProvider: "openweathermap",
type: "forecast",
location: "New York",
locationID: "5128581", //ID from http://bulk.openweathermap.org/sample/city.list.json.gz; unzip the gz file and find your city
apiKey: "YOUR_OPENWEATHER_API_KEY"
}
},
{
module: "newsfeed",
position: "bottom_bar",
config: {
feeds: [
{
title: "New York Times",
url: "https://rss.nytimes.com/services/xml/rss/nyt/HomePage.xml"
}
],
showSourceTitle: true,
showPublishDate: true,
broadcastNewsFeeds: true,
broadcastNewsUpdates: true
}
},
]
};
/*************** DO NOT EDIT THE LINE BELOW ***************/
if (typeof module !== "undefined") {module.exports = config;}
@danieldiazie & @george-dilthey; I am wondering if this issue is raspberry pi4 specific now. I myself only have a pi3 and pi0w.
Do either of you have an earlier version of a pi that you may dbl check the module/mirror on?
Unfortunately I do not.
Nope. Only have the one.
@Elaniobro I too only have a 4. To answer your previous question, I downloaded both MM and this module together last week so I presume I have the latest versions. MM is 2.16.0.
Let me know if I can help with any other troubleshooting. I'm home this week and would love to get this going so just LMK!
I think we might need someone with both a raspberry pi4 & an earlier pi to test.
I am unable to reproduce the errors you and others reporting on my local machine or Pi's. (pi3/pi0w)
@george-dilthey, @stern1978 & @danieldiazie, is the bug/issue still present for you? If not I will be closing this issue as a š
āāļø wontfix
Thank you.
@Elaniobro yes it is, although I recently ordered a RP3, should be here in a couple days. Happy to help debug once it gets here.
Has anyone found a solution to the header only issue?
@Nneuland what is your "header only issue"?
@danieldiazie were you able to verify issue persists on a RP3?
HI! I'm on RP4 only getting a header.
With this error repeating
socketNotificationReceived: āTRAIN_TABLEā: Array(2) MMM-nyc-transit.js:332 Uncaught TypeError: Cannot read property āfadeSpeedā of undefined at Class.socketNotificationReceived (:8080/modules/MMM-nyā¦-nyc-transit.js:332) at module.js:245 at Socket. (socketclient.js:38) at Socketā¦/node_modules/component-emitter/index.js.Emitter.emit (socket.io.js:1915) at Socket.emit (socket.io.js:1544) at Socket.emitEvent (socket.io.js:1161) at Socket.onevent (socket.io.js:1135) at Socket.MMSocket.socket.onevent (socketclient.js:32) at Socket.onpacket (socket.io.js:1089) at Managerā¦/node_modules/component-emitter/index.js.Emitter.emit (socket.io.js:1915)
Not sure if this is enough information for you...
N
Here is my config for mmm-nyc-transit Have I missed something?
{ module: 'MMM-nyc-transit', position: "top_bar", header: "Next Train", config: { apiKey: 'xxxxxxxxxxx', displayType: 'list', mtaType: 'train', stations: [ { stationId: 629, walkingTime: 3, dir: { upTown: true, downTown: true, } }, { stationId: 177, walkingTime: 5, dir: { upTown: false, downTown: false } } ], updateInterval: 300000 } },
Raspberry Pi 3B here. Same error with
[13.12.2021 15:57.39.560] [ERROR]
(node:5713) UnhandledPromiseRejectionWarning: Error: RangeError: index out of range: 3 + 109 > 23
at /home/pi/MagicMirror/modules/MMM-nyc-transit/node_helper.js:187:15
at processTicksAndRejections (internal/process/task_queues.js:93:5)
I tracked down the error further. It appears to be in a downstream dependency that parses the MTA feed message using protobuf. Specifically this line: https://github.com/ericandrewlewis/mta-realtime-subway-departures/blob/c7dd12a4ed9381ddfb1fbdecdbf9b5bb4dec448e/index.js#L32
@James-Quigley do you have to to put in a fix on the repo?
@James-Quigley @george-dilthey @Nneuland @danieldiazie @stern1978; https://github.com/ericandrewlewis/mta-realtime-subway-departures/issues/15 fix should resolve this issue. Will you all please re-install the module so that it picks up the v1.2.1 patch fix of the https://github.com/ericandrewlewis/mta-realtime-subway-departures dependency?
I've updated to 1.2.1 of mta-realtime-subway-departures, but I'm still experiencing the same error
Nvm ignore me. My API key wasn't valid. To anybody else experiencing the same thing, double check your API key
Just checking in. Is there an MTA -BUS schedule feature available with this module yet?
Thanks
Nick
On Fri, Mar 4, 2022 at 4:29 PM James Quigley @.***> wrote:
Nvm ignore me. My API key wasn't valid. To anybody else experiencing the same thing, double check your API key
ā Reply to this email directly, view it on GitHub https://github.com/Elaniobro/MMM-nyc-transit/issues/56#issuecomment-1059545290, or unsubscribe https://github.com/notifications/unsubscribe-auth/AV4YKP32MHEO2W7OKV5KOETU6J6DVANCNFSM5BLYIGAQ . Triage notifications on the go with GitHub Mobile for iOS https://apps.apple.com/app/apple-store/id1477376905?ct=notification-email&mt=8&pt=524675 or Android https://play.google.com/store/apps/details?id=com.github.android&referrer=utm_campaign%3Dnotification-email%26utm_medium%3Demail%26utm_source%3Dgithub.
You are receiving this because you were mentioned.Message ID: @.***>
@Nneuland, negative. It is something I wanted to explore but do not have the bandwidth at the moment. Open to PR's š
Describe the bug I installed the module and followed the directions for an api key. I copied the example config from the readme and when i run it, i get an error:
(node:6098) UnhandledPromiseRejectionWarning: Error: RangeError: index out of range: 3 + 109 > 23 at /home/pi/Development/MagicMirror/modules/MMM-nyc-transit/node_helper.js:175:15 at processTicksAndRejections (internal/process/task_queues.js:95:5)
To Reproduce Steps to reproduce the behavior:
Expected behavior The module to display data.
Actual behavior Header is displayed, but no transit data is displayed
Screenshots If applicable, add screenshots to help explain your problem.
Platform (please complete the following information):
Configuration
{ module: 'MMM-nyc-transit', position: "top_bar", header: "Next Train", config: { apiKey: 'API_KEY', displayType: 'list', mtaType: 'train', stations: [ { stationId: 237, walkingTime: 5, dir: { upTown: false, downTown: true } }, { stationId: 177, walkingTime: 5, dir: { upTown: true, downTown: false } } ], updateInterval: 300000 } },
Additional context Add any other context about the problem here.