chriskyfung / qwiklabs-completed-labs-tracker

Label completed labs and quests on Qwiklabs
https://chriskyfung.github.io/blog/qwiklabs/userscript-for-labelling-completed-qwiklabs
GNU General Public License v3.0
8 stars 3 forks source link

Sync data accross Qwiklasb subdomains (www., aws., google., and run.qwiklabs.com) #22

Open chriskyfung opened 3 years ago

chriskyfung commented 3 years ago

The lab and quest completion data is currently stored using IndexedDB.

Like most web storage solutions, IndexedDB follows a same-origin policy. So while you can access stored data within a domain, you cannot access data across different domains. - MDN

This means that different Qwiklabs subdomains, e.g. www.qwiklabs.com, aws.qwiklabs.com, google.qwiklabs.com, and run.qwiklabs.comm, do not share the same IndexedDB.

The issue becomes critical after Qwiklabs made a web design update in April 2021. Before that, it was easy to work around by using our one-click update to parse all lab and quest completion status from the /my_learning/labs and /my_learning/courses pages.

The new Qwiklabs web design no longer contains labs' identifier or permalink in the My Learning Activity section. This change makes difficult to associate each activity records with the database data without any unique identitier.

The lab title is temporarily used as the key to look up the database in the the latest version (v0.5.4). It is, however, not an ideal method because the Qwiklabs team changes the lab title from time to time. This will give a poor track of the learning activities.

We do need a better solution for the issue to make all tracking records being correct as well as syncing accross those subdomains. I wish someone could provide me a help.

If you have any ideas on improving this area, please share your thoughts below. Thanks 🙏

rickpoonin commented 1 year ago

href has been changed to https://www.cloudskillsboost.google/catalog