WikiEducationFoundation / WikiEduDashboard

Wiki Education Foundation's Wikipedia course dashboard system
https://dashboard.wikiedu.org
MIT License
392 stars 630 forks source link

No survey notifications are being created #783

Closed ragesoss closed 8 years ago

ragesoss commented 8 years ago

I'm trying to test it out on staging, and even though it shows lots of in-scope notifications on the survey assignment I made, clicking 'Create notifications' does not create any.

See SurveyAssignment 4: https://dashboard-testing.wikiedu.org/surveys/assignments

ragesoss commented 8 years ago

Okay, I think I figured out the issue. They don't get created (necessarily) if you navigate away before the rake task has done its work. I guess maybe the rake task exits if the request stops before resolving?

ragesoss commented 8 years ago

Actually, that's not it. I still can't get it to create new notifications.

jonathanhudak commented 8 years ago

@ragesoss I was just able to run the rake task manually from the server on the command line. The task is working. The issue seems to be in the controller action that is trying to call it.

https://dashboard-testing.wikiedu.org/surveys/assignments

ragesoss commented 8 years ago

@hudakdidit if that's the case, then maybe it just doesn't like calling rake tasks via controller? If so, my PR might fix it.

jonathanhudak commented 8 years ago

@ragesoss those buttons seem to be working locally for me now after the SurveyNotificationsManager addition. I tried to setup a small test on staging with a new dummy course and test cohort, but adding a new cohort to the application.production.yml and restarting didn't seem to have any effect. Is there something I'm missing?

ragesoss commented 8 years ago

@hudakdidit to add cohorts, you must manually run rake cohort:add_cohorts. But yeah, it seems to be fixed.

ragesoss commented 8 years ago

Works on staging now.

ragesoss commented 8 years ago

@hudakdidit also, application.production.yml is just an archived, sanitized copy of the application.yml from production. New cohorts would need to be added to application.yml before the rake task.

I'll probably create a simple frontend for creating cohorts soon.