Scraping and analysis of the leetcode-compensations
page (for India).
Check out https://github.com/kuutsav/LeetComp for an interactive version of this report.
-- Fixed salary: 29th Dec 2022 - 17th Dec 2023
-- Total salary: 29th Dec 2022 - 17th Dec 2023
-- Fixed salary(Dark mode): 29th Dec 2022 - 17th Dec 2023
-- Total salary(Dark mode): 29th Dec 2022 - 17th Dec 2023
-- Fixed salary: 5th Jan 2019 - 18th Jan 2022
-- Total salary: 5th Jan 2019 - 18th Jan 2022
-- Fixed salary(Dark mode): 5th Jan 2019 - 18th Jan 2022
-- Total salary(Dark mode): 5th Jan 2019 - 18th Jan 2022
$ git clone <repo>
$ python3 -m venv .venv
$ source .venv/bin/activate
$ pip install -r requirements.txt
First we need to fetch the posts metadata. This inlvolves fetching the post ids from each page (till_date -> today).
$ source .venv/bin/activate
$ PYTHONPATH=. python leetcode/posts_meta.py --till_date 2023/01/01
The next step if to fetch the actual post content for each of the post ids from the previous step.
$ source .venv/bin/activate
$ PYTHONPATH=. python leetcode/posts.py --posts_meta F
$ source .venv/bin/activate
$ python scripts/plots.py # generate fixed comp. plots
$ python scripts/report.py # fixed comp.
$ python scripts/report_dark.py # fixed comp., dark mode
$ python scripts/plots_total.py # generate total comp. plots
$ python scripts/report_total.py # total comp.
$ python scripts/report_dark_total.py # total comp., dark mode