+ 11

[Solved] Python SoloLearn Database Access

Is there some kind of blank database I could write to/retrieve from with Python in SoloLearn?

5th Jul 2018, 6:00 AM
Nathan Lewis
Nathan Lewis - avatar
7 odpowiedzi
+ 15
To achieve Python persistence, I used a Google Sheet, Google Site (for public view), App Script (like server-side javascript) and sockets. Notes: https isn't a problem--Python ignores CORS. App Scripts must be published after saving (no autopublish). Site + Sheet view here (Jafca tests at 10m!) https://sites.google.com/site/sllkspersist/ Rows before 2017-03-14 are from "pypersist" + very early socket ideas: https://code.sololearn.com/cJTcw0o5WgaZ/#py Home version, easier import "requests": https://code.sololearn.com/c37XERvwb2Cz/#py Text maze persistence / JSON (after 2017-03-14) from: https://code.sololearn.com/cx84c2P4zMgt/#py App Script (Sheets menu: Tools | Script Editor): https://code.sololearn.com/W0uupH4nuCnG/#html API+etc links: * https://developers.google.com/sheets/api/ * https://developers.google.com/apps-script/ * https://developers.google.com/apps-script/guides/sheets * https://developers.google.com/apps-script/reference/spreadsheet/ * https://script.google.com/home
6th Jul 2018, 1:52 AM
Kirk Schafer
Kirk Schafer - avatar
+ 15
I'm afraid not. But you can create it on the fly: https://code.sololearn.com/csyhsIovmZJ3/?ref=app
5th Jul 2018, 6:11 AM
Kuba Siekierzyński
Kuba Siekierzyński - avatar
+ 11
That might be a problem because of security reasons. I had problems with retrieving files through https from within SoloLearn. Downloading remote files via http works like a charm, though. Perhaps Kirk Schafer could help here?
5th Jul 2018, 7:07 AM
Kuba Siekierzyński
Kuba Siekierzyński - avatar
+ 8
By the way, if you have questions, no problem; I was just trying to fit everything into ONE post so that elaborations fall back to one answer :)
6th Jul 2018, 5:58 AM
Kirk Schafer
Kirk Schafer - avatar
+ 7
Nathan, you might want to add [SOLVED] before the question title if it helps you. That seems like a huge enhancement of Python codes in Sololearn. Thanks, Kirk!
6th Jul 2018, 6:55 AM
Kuba Siekierzyński
Kuba Siekierzyński - avatar
+ 5
Thanks! Just wanted to take out the step of having people fill out a separate Google Form, and being unable to access the Google Sheets from Sololearn
5th Jul 2018, 6:13 AM
Nathan Lewis
Nathan Lewis - avatar
+ 5
thank you kirk! i will take the time to look over all your responses, they seem extremely helpful!!!
6th Jul 2018, 6:01 AM
Nathan Lewis
Nathan Lewis - avatar