Closed Beastlynoob closed 3 years ago
Hi, I am glad you're enjoying my module. Could you please elaborate on the adays bdays concept? From your first paragraph, it seems like you both of them every day of the week. Or do you have adays M,W,F one week and then T,Th the next? If it is the latter case, I can certainly work something out that would allow you to do that. Thanks again for using my module and giving feedback, it makes me quite happy to hear it is getting use!
Best, Ethan On Aug 22, 2020, 4:56 PM -0500, Beastlynoob notifications@github.com, wrote:
Hi, I love your module so much and I am so glad you made it. I am having an issue. I am currently in high school so we have days and bdays in our school so I have day classes on Monday, Wednesday, Friday, Tuesday and Thursday. and B day classes on Tuesday Thursday, Monday, Wednesday, and Friday. So my classes alternate. Is there a way I could put that into the config file? — You are receiving this because you are subscribed to this thread. Reply to this email directly, view it on GitHub, or unsubscribe.
Sorry I didn't mean to make it so confusing. I have attached an image to this comment. The way it goes is that I have the same 4 classes on a day and the same 4 other classes on b day. I hope that made more sensel
I also had one more problem if you could also help me with that please. I installed your module and pasted the config.js file with all my information however when I launch magic mirror I just get a loading sign from it. I tried reinstalling the module as well but no luck.
Here is the config.js file: `` { module: "MMM-MyStudyLife", position: "top_right", config: { code: "my own id", showSchedule: true, showExams: true, showTasks: true, classes: { "English 2": [1,3,5], "AP Spanish IV": [1,3,5], "Algebra II": [1,3,5], "Computer Science I": [1,3,5], "Chemistry": [2,4], "Learner Leadership Council": [2,4], "Broadway Bound": [2,4], "AP World History": [2,4], } } },
Hi, Ill take a look into that soonfor you. A heads up, you should delete the photo you put in here. I think it contains your email information, since this is a public issue thread you shoukd also cross that information out.
Best, Ethan On Aug 22, 2020, 9:38 PM -0500, Beastlynoob notifications@github.com, wrote:
I also had one more problem if you could also help me with that please. I installed your module and pasted the config.js file with all my information however when I launch magic mirror I just get a loading sign from it. I tried reinstalling the module as well but no luck. — You are receiving this because you commented. Reply to this email directly, view it on GitHub, or unsubscribe.
Oh I didn't even notice that thank you!
I know you are probably very busy, I just wanted to check up to see how it's going.
Uni is starting up again so this past week I've been busy moving in and trying to not catch covid. Im working on the issues atm.
No worries, focus on school this isn't a priority.
I should have a branch with a hopefully working cycle schedule implementation, it is aptly named "cycle". Please try it out and let me know if you have any issues. A config that might work for you is
{
module: "MMM-MyStudyLife",
position: "top_right",
config: {
code: "your code (Including the semi colon in the middle and the equal sign at the end)",
showSchedule: true,
showExams: true,
showTasks: true,
useCycles: true,
classes: {
"English 2": [0],
"AP Spanish IV": [0],
"Algebra II": [0],
"Computer Science I": [0],
"Chemistry": [1],
"Learner Leadership Council": [1],
"Broadway Bound": [1],
"AP World History": [1],
},
}
}
If you still receive the loading error let me know, your config looked fine to me so I could only think there is an issue with it having cycles. Hopefully this fixes that. Make sure to double check the names are spelt exactly right.
I added the following features:
I tried downloading the branch and trying the update but it did not work and was still stuck on loading. To download the branch I first did cd MMM-MyStudyLife
then git pull
then git checkout cycle
and lastly npm install
. I made sure the access code was still the same and all the classes were spelled correctly. Let me know if I did something wrong?
That is how you should switch branches. If you dont mind troubleshooting for me, please follow these steps:
here is what popped up. Sorry I'm responding so late.
`Electron Security Warning (Insecure Resources) This renderer process loads resources using insecure protocols.This exposes users of this app to unnecessary security risks. Consider loading the following resources over HTTPS or FTPS.
For more information and help, consult https://electronjs.org/docs/tutorial/security. This warning will not show up once the app is packaged. /home/pi/MagicMirror…ity-warnings.js:145 Electron Security Warning (Insecure Content-Security-Policy) This renderer process has either no Content Security Policy set or a policy with "unsafe-eval" enabled. This exposes users of this app to unnecessary security risks.
For more information and help, consult https://electronjs.org/docs/tutorial/security. This warning will not show up once the app is packaged. MMM-MyStudyLife.js:278 code worked MMM-MyStudyLife.js:287 added schedule stuff MMM-MyStudyLife.js:300 added term stuff MMM-MyStudyLife.js:302 term stuff failed MMM-MyStudyLife.js:303 Uncaught Could not find current term `
Alright thank you. That should be pretty easy to fix on my end. Do you have yearly classes not semesterly?
I have yearly classes
try the new version of cycles and let me now how it goes
I updated but the module completely disappeared. It doesbt show up when i launch magic mirror
Sorry i should have been more clear. Put "useTerms: false," into your config file. If that doesnt work please try "npm start dev" again and let me know what it says
Best, Ethan On Sep 1, 2020, 12:37 AM -0500, Beastlynoob notifications@github.com, wrote:
I updated but the module completely disappeared. It doesbt show up when i launch magic mirror — You are receiving this because you commented. Reply to this email directly, view it on GitHub, or unsubscribe.
`Electron Security Warning (Insecure Resources) This renderer process loads resources using insecure protocols.This exposes users of this app to unnecessary security risks. Consider loading the following resources over HTTPS or FTPS.
For more information and help, consult https://electronjs.org/docs/tutorial/security. This warning will not show up once the app is packaged. /home/pi/MagicMirror…ity-warnings.js:145 Electron Security Warning (Insecure Content-Security-Policy) This renderer process has either no Content Security Policy set or a policy with "unsafe-eval" enabled. This exposes users of this app to unnecessary security risks.
For more information and help, consult https://electronjs.org/docs/tutorial/security. This warning will not show up once the app is packaged.  `
It showed nothing still here is console thing
Here is my config file if you need it. `modules: [
{ module: "MMM-MyStudyLife", position: "bottom_bar", config: { code: '", showSchedule: true, showExams: true, showTasks: true, useCycles: true, useTerms: false, classes: { "Algebra II": [0], "AP Spanish IV": [0], "AP World History": [1], "Broadway Bound": [1], "Chemistry": [1], "Computer Science I": [0], "English 2": [0], "Learner Leadership Council": [1], "Lunch": [0,1], } } },`
Can you try putting position as "top_right", it shouldn't matter but it couldnt hurt to try. In the meantime ill put a bunch of debugging stuff into the code to try to figure out whats wrong in your case. Thanks for your patience in all this, we will get it figured out
Best, Ethan On Sep 1, 2020, 1:02 PM -0500, Beastlynoob notifications@github.com, wrote:
Here is my config file if you need it.
modules: [ { module: "MMM-MyStudyLife", position: "bottom_bar", config: { code: '", showSchedule: true, showExams: true, showTasks: true, useCycles: true, useTerms: false, classes: { "Algebra II": [0], "AP Spanish IV": [0], "AP World History": [1], "Broadway Bound": [1], "Chemistry": [1], "Computer Science I": [0], "English 2": [0], "Learner Leadership Council": [1], "Lunch": [0,1], } } },
— You are receiving this because you commented. Reply to this email directly, view it on GitHub, or unsubscribe.
Alright I've pushed a couple more bug fixes to the branch. Try updating and seeing if it works now, I think it should.
Good news the module appeared again. But bad news it is still stuck on loading. Thank you so so much for taking time out of your day to help me.
here is the console thing:
`/home/pi/MagicMirror/node_modules/electron/dist/resources/electron.asar/renderer/security-warnings.js:95 Electron Security Warning (Insecure Resources) This renderer process loads resources using insecure protocols.This exposes users of this app to unnecessary security risks. Consider loading the following resources over HTTPS or FTPS.
For more information and help, consult https://electronjs.org/docs/tutorial/security. This warning will not show up once the app is packaged. warnAboutInsecureResources @ /home/pi/MagicMirror/node_modules/electron/dist/resources/electron.asar/renderer/security-warnings.js:95 logSecurityWarnings @ /home/pi/MagicMirror/node_modules/electron/dist/resources/electron.asar/renderer/security-warnings.js:214 loadHandler @ /home/pi/MagicMirror/node_modules/electron/dist/resources/electron.asar/renderer/security-warnings.js:233 /home/pi/MagicMirror/node_modules/electron/dist/resources/electron.asar/renderer/security-warnings.js:145 Electron Security Warning (Insecure Content-Security-Policy) This renderer process has either no Content Security Policy set or a policy with "unsafe-eval" enabled. This exposes users of this app to unnecessary security risks.
For more information and help, consult
https://electronjs.org/docs/tutorial/security.
This warning will not show up
once the app is packaged.
(anonymous) @ /home/pi/MagicMirror/node_modules/electron/dist/resources/electron.asar/renderer/security-warnings.js:145
Promise.then (async)
warnAboutInsecureCSP @ /home/pi/MagicMirror/node_modules/electron/dist/resources/electron.asar/renderer/security-warnings.js:139
logSecurityWarnings @ /home/pi/MagicMirror/node_modules/electron/dist/resources/electron.asar/renderer/security-warnings.js:218
loadHandler @ /home/pi/MagicMirror/node_modules/electron/dist/resources/electron.asar/renderer/security-warnings.js:233
MMM-MyStudyLife.js:278 code worked
MMM-MyStudyLife.js:287 added schedule stuff
MMM-MyStudyLife.js:306 added term stuff
MMM-MyStudyLife.js:329 added class stuff
MMM-MyStudyLife.js:333 added tasks stuff
MMM-MyStudyLife.js:338 added exam stuff
MMM-MyStudyLife.js:79 Loading successful
MMM-MyStudyLife.js:354 sorting classes
MMM-MyStudyLife.js:356 null
MMM-MyStudyLife.js:357 Uncaught (in promise) TypeError: Cannot read property 'includes' of undefined
at Class.sortClasses (MMM-MyStudyLife.js:357)
at Class.makeSchedule (MMM-MyStudyLife.js:217)
at Class.getDom (MMM-MyStudyLife.js:81)
at main.js:111
at new Promise (
Hi, my internet is out so Im not able to do any updates to the code. Ill check this out as soon as I can
Best, Ethan On Sep 1, 2020, 4:49 PM -0500, Beastlynoob notifications@github.com, wrote:
here is the console thing:
/home/pi/MagicMirror/node_modules/electron/dist/resources/electron.asar/renderer/security-warnings.js:95 Electron Security Warning (Insecure Resources) This renderer process loads resources using insecure protocols.This exposes users of this app to unnecessary security risks. Consider loading the following resources over HTTPS or FTPS. • http://localhost:8080/css/main.css • http://localhost:8080/fonts/roboto.css • http://localhost:8080/socket.io/socket.io.js • http://localhost:8080/vendor/node_modules/nunjucks/browser/nunjucks.min.js • http://localhost:8080/js/defaults.js • http://localhost:8080/config/config.js • http://localhost:8080/vendor/vendor.js • http://localhost:8080/modules/default/defaultmodules.js • http://localhost:8080/js/logger.js • http://localhost:8080/translations/translations.js • http://localhost:8080/js/translator.js • http://localhost:8080/js/class.js • http://localhost:8080/js/module.js • http://localhost:8080/js/loader.js • http://localhost:8080/js/socketclient.js • http://localhost:8080/js/main.js • http://localhost:8080/fonts/node_modules/roboto-fontface/fonts/roboto-condensed/Roboto-Condensed-Regular.woff2 • http://localhost:8080/translations/en.json • http://localhost:8080/translations/en.json • http://localhost:8080/modules/MMM-MyStudyLife//MMM-MyStudyLife.js • http://localhost:8080/modules/MMM-MyStudyLife/styles1.css • http://localhost:8080/vendor/css/font-awesome.css • http://localhost:8080/vendor/node_modules/@fortawesome/fontawesome-free/css/all.min.css • http://localhost:8080/vendor/node_modules/@fortawesome/fontawesome-free/css/v4-shims.min.css • http://localhost:8080/css/custom.css For more information and help, consult https://electronjs.org/docs/tutorial/security. This warning will not show up once the app is packaged. warnAboutInsecureResources @ /home/pi/MagicMirror/node_modules/electron/dist/resources/electron.asar/renderer/security-warnings.js:95 logSecurityWarnings @ /home/pi/MagicMirror/node_modules/electron/dist/resources/electron.asar/renderer/security-warnings.js:214 loadHandler @ /home/pi/MagicMirror/node_modules/electron/dist/resources/electron.asar/renderer/security-warnings.js:233 /home/pi/MagicMirror/node_modules/electron/dist/resources/electron.asar/renderer/security-warnings.js:145 Electron Security Warning (Insecure Content-Security-Policy) This renderer process has either no Content Security Policy set or a policy with "unsafe-eval" enabled. This exposes users of this app to unnecessary security risks. For more information and help, consult https://electronjs.org/docs/tutorial/security. This warning will not show up once the app is packaged. (anonymous) @ /home/pi/MagicMirror/node_modules/electron/dist/resources/electron.asar/renderer/security-warnings.js:145 Promise.then (async) warnAboutInsecureCSP @ /home/pi/MagicMirror/node_modules/electron/dist/resources/electron.asar/renderer/security-warnings.js:139 logSecurityWarnings @ /home/pi/MagicMirror/node_modules/electron/dist/resources/electron.asar/renderer/security-warnings.js:218 loadHandler @ /home/pi/MagicMirror/node_modules/electron/dist/resources/electron.asar/renderer/security-warnings.js:233 MMM-MyStudyLife.js:278 code worked MMM-MyStudyLife.js:287 added schedule stuff MMM-MyStudyLife.js:306 added term stuff MMM-MyStudyLife.js:329 added class stuff MMM-MyStudyLife.js:333 added tasks stuff MMM-MyStudyLife.js:338 added exam stuff MMM-MyStudyLife.js:79 Loading successful MMM-MyStudyLife.js:354 sorting classes MMM-MyStudyLife.js:356 null MMM-MyStudyLife.js:357 Uncaught (in promise) TypeError: Cannot read property 'includes' of undefined at Class.sortClasses (MMM-MyStudyLife.js:357) at Class.makeSchedule (MMM-MyStudyLife.js:217) at Class.getDom (MMM-MyStudyLife.js:81) at main.js:111 at new Promise () at updateDom (main.js:110) at Object.updateDom (main.js:542) at Class.updateDom (module.js:357) at Class.socketNotificationReceived (MMM-MyStudyLife.js:340) at module.js:243
— You are receiving this because you commented. Reply to this email directly, view it on GitHub, or unsubscribe.
No worries, thank you so much
This is a confusing error to me... Do all of your classes have names? Could you please try going to this website for me: https://apitester.com/. When there enter https://api.mystudylife.com/v6.1/data into the URL box. Next click the plus box labeled "Add Request Header". In the name box put "Authorization" then in the value put "Bearer[space]YOURCODE". Then try pasting the response here (It might contain sensitive information, I only need to see the code in the "classes" section of the file. Feel free to censor anything you want.)
request: `GET /v6.1/data HTTP/1.1 Host: api.mystudylife.com Accept: / User-Agent: Mozilla/5.0 (compatible; Rigor/1.0.0; http://rigor.com)
Response header: HTTP/1.1 401 Unauthorized Cache-Control: no-cache Pragma: no-cache Content-Length: 111 Content-Type: application/json; charset=utf-8 Expires: -1 Server: Microsoft-IIS/10.0 WWW-Authenticate: Bearer realm="My Study Life Platform" Access-Control-Allow-Origin: https://app.mystudylife.com Access-Control-Allow-Methods: GET, POST, PUT, DELETE, OPTIONS Access-Control-Allow-Headers: Accept, Authorization, Origin, Content-Type, X-MSL-Version Request-Context: I took this part out Access-Control-Expose-Headers: Request-Context Date: Sat, 05 Sep 2020 00:50:24 GMT
Response body: {"error":"not_authorized","error_message":"The requested resource requires authorization.","error_detail":null} `
Try re-getting your code from my study life, it shouldn't have an error on that site. Try reentering code on this side and my mirror application, let me know what happens
Best, Ethan On Sep 4, 2020, 7:53 PM -0500, Beastlynoob notifications@github.com, wrote:
request:
GET /v6.1/data HTTP/1.1 Host: api.mystudylife.com Accept: / User-Agent: Mozilla/5.0 (compatible; Rigor/1.0.0; http://rigor.com) Response header: HTTP/1.1 401 Unauthorized Cache-Control: no-cache Pragma: no-cache Content-Length: 111 Content-Type: application/json; charset=utf-8 Expires: -1 Server: Microsoft-IIS/10.0 WWW-Authenticate: Bearer realm="My Study Life Platform" Access-Control-Allow-Origin: https://app.mystudylife.com Access-Control-Allow-Methods: GET, POST, PUT, DELETE, OPTIONS Access-Control-Allow-Headers: Accept, Authorization, Origin, Content-Type, X-MSL-Version Request-Context: I took this part out Access-Control-Expose-Headers: Request-Context Date: Sat, 05 Sep 2020 00:50:24 GMT Response body: {"error":"not_authorized","error_message":"The requested resource requires authorization.","error_detail":null}
— You are receiving this because you commented. Reply to this email directly, view it on GitHub, or unsubscribe.
I tried getting a new code. While doing that I figured out that I had a hidden class. I deleted that class and got a new API code and put that it. It is still stuck on loading.
Dang, could I see your console again and the classes codefrom api site
Ethan On Sep 4, 2020, 8:07 PM -0500, Beastlynoob notifications@github.com, wrote:
I tried getting a new code. While doing that I figured out that I had a hidden class. I deleted that class and got a new API code and put that it. It is still stuck on loading. — You are receiving this because you commented. Reply to this email directly, view it on GitHub, or unsubscribe.
Request Headers
GET /v6.1/data HTTP/1.1 Host: api.mystudylife.com Accept: */* User-Agent: Mozilla/5.0 (compatible; Rigor/1.0.0; http://rigor.com)
Response Headers
HTTP/1.1 401 Unauthorized Cache-Control: no-cache Pragma: no-cache Content-Length: 111 Content-Type: application/json; charset=utf-8 Expires: -1 Server: Microsoft-IIS/10.0 WWW-Authenticate: Bearer realm="My Study Life Platform" Access-Control-Allow-Origin: https://app.mystudylife.com Access-Control-Allow-Methods: GET, POST, PUT, DELETE, OPTIONS Access-Control-Allow-Headers: Accept, Authorization, Origin, Content-Type, X-MSL-Version Request-Context: appId=cid-v1:697b66b3-f043-41f7-aa9f-f553d6b58f5c Access-Control-Expose-Headers: Request-Context Date: Sat, 05 Sep 2020 04:14:50 GMT
Response Body
{"error":"not_authorized","error_message":"The requested resource requires authorization.","error_detail":null}
It says pass, I dont know if that helps.
Can I see a screenshot of what the website looks like. It really shouldn't have an error from there. Thanks again for all your communication
Best, Ethan On Sep 4, 2020, 11:17 PM -0500, Beastlynoob notifications@github.com, wrote:
It says pass, I dont know if that helps. — You are receiving this because you commented. Reply to this email directly, view it on GitHub, or unsubscribe.
Sorry for such a late response.
Can I see the website just above where you screenshoted.
I'm sorry I really don't know what could be causing this issue besides inputting the wrong code. I just re-checked this website using my own info and it still worked. When I inputted a wrong code, I received the exact same response you have been having.
Could you try double checking your code and getting a fresh one from the mystudylife website. Then make sure you paste the code with one space between Bearer and it. Also make sure to include everything besides the quotation marks. I'm sure you are doing it right, I just can't think of any other solution/problem
Actually one more thing you can try, can you remove any spaces from your class names. Maybe replace them with _ . Do that both in the config file and on the MyStudyLife website.
Sorry for the late response. I created a new account with just 2 classes. Math and Reading. Math is on a Day and reading is on Bday. I tried loading the module again but all I get is loading.
`{ module: "MMM-MyStudyLife", position: "bottom_bar", config: { code: "my code in between the quotes", showSchedule: true, showExams: true, showTasks: true, useCycles: true, useTerms: true, classes: { "English":[1], "Math":[0], } } }, '
I also did api tester and no errors, Is it possible that the changes you made to a branch didnt go through. Can you go through the steps of how to download that specific branch?
I also tried creating a schedule where I had "Math" on days 1,3,5, and "Reading" on 2,4. I have the same thing on My Study life but when I load the mirror up it is still on loading.
Hmmm that is interesting. Sometime soon, hopefully tonight, I will make a clean install and new account and try to see if it errors on my end. Ill then proceed from there and give you some updates
Best, Ethan On Sep 17, 2020, 12:02 PM -0500, Beastlynoob notifications@github.com, wrote:
I also tried creating a schedule where I had "Math" on days 1,3,5, and "Reading" on 2,4. I have the same thing on My Study life but when I load the mirror up it is still on loading. — You are receiving this because you commented. Reply to this email directly, view it on GitHub, or unsubscribe.
Yeah I just made a clean account using cycles and didn't receive any errors...
Steps to be up to date on git:
git branch
(make sure cycles is even an option)git checkout cycle
git add .
(Steps 3-4 shouldn't be necessary but I'm paranoid at this point)git stash
git pull
Then try replacing the modules section of your config with the following:
modules: [
{
module: "MMM-MyStudyLife",
position: "top_right",
config: {
code: "QZVECH2J6231L6MZNL1U:ermiopWuaK8eDAZbqqKtFoupwec=",
showSchedule: true,
showExams: true,
showTasks: true,
useCycles: true,
daysOff: [0,6],
// offset: 0,
// classFontScale: 1,
// examFontScale: 2,
// taskFontScale: .2,
// averageScheduleHeight: 1000,
classes: {
"Test1": [0],
"Test2": [1],
},
}
}
]
If you don't see this till a little while later, message me and ill get you a new code.
I can try this today. Once again sorry for the late response.
Code should still be active right?
Possibly? Did it work on your end?
Best, Ethan On Sep 30, 2020, 3:15 PM -0500, Beastlynoob notifications@github.com, wrote:
Code should still be active right? — You are receiving this because you commented. Reply to this email directly, view it on GitHub, or unsubscribe.
Hi, I love your module so much and I am so glad you made it. I am having an issue. I am currently in high school so we have days and bdays in our school so I have day classes on Monday, Wednesday, Friday, Tuesday and Thursday. and B day classes on Tuesday Thursday, Monday, Wednesday, and Friday. So my classes alternate. Is there a way I could put that into the config file?