[PR #461] [MERGED] Add support for scraping FotMob #580

Closed
opened 2026-03-02 15:58:36 +03:00 by kerem · 0 comments
Owner

📋 Pull Request Information

Original PR: https://github.com/probberechts/soccerdata/pull/461
Author: @marcjbaron
Created: 1/17/2024
Status: Merged
Merged: 2/7/2024
Merged by: @probberechts

Base: masterHead: fotmob


📝 Commits (10+)

📊 Changes

14 files changed (+1259 additions, -4 deletions)

View changed files

📝 .github/labels.yml (+3 -0)
📝 README.rst (+4 -3)
docs/datasources/FotMob.ipynb (+749 -0)
📝 docs/datasources/index.rst (+1 -0)
📝 docs/howto/custom-leagues.rst (+7 -0)
📝 docs/index.rst (+3 -1)
docs/reference/fotmob.rst (+8 -0)
📝 docs/reference/index.rst (+1 -0)
📝 soccerdata/__init__.py (+2 -0)
📝 soccerdata/_config.py (+7 -0)
📝 soccerdata/fbref.py (+1 -0)
soccerdata/fotmob.py (+437 -0)
📝 tests/conftest.py (+6 -0)
tests/test_FotMob.py (+30 -0)

📄 Description

Hello,

This is an attempt at adding Fotmob as a data source to soccerdata. The nox test suite passed without errors, with the exception of the python-3.8 tests (but the current python dependency in the pyproject.toml file is >=3.9, so I don't know if this can be safely ignored). Unit tests were also created and passed successfully.

The current methods are:

  • read_seasons(), read_leagues(), read_schedule() (similar to the other data sources)
  • read_match_stats() -> reads stats for an individual game
  • read_league_table() -> this functionality is not included in the other data sources, but I needed it for a personal project, so kept it in.

There are obviously other methods that could be added (e.g. season stats), but did not want to go much further until early issues are dealt with.


🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.

## 📋 Pull Request Information **Original PR:** https://github.com/probberechts/soccerdata/pull/461 **Author:** [@marcjbaron](https://github.com/marcjbaron) **Created:** 1/17/2024 **Status:** ✅ Merged **Merged:** 2/7/2024 **Merged by:** [@probberechts](https://github.com/probberechts) **Base:** `master` ← **Head:** `fotmob` --- ### 📝 Commits (10+) - [`70c8ee0`](https://github.com/probberechts/soccerdata/commit/70c8ee0e2e79f723d0dec3f36b76cc1d0ba07aa8) Initial commit - [`cd533c9`](https://github.com/probberechts/soccerdata/commit/cd533c95e10fcf6a9771df9f583d26b36ca3a066) Merge branch 'fotmob' of https://github.com/marcjbaron/soccerdata into fotmob - [`6d8a6f6`](https://github.com/probberechts/soccerdata/commit/6d8a6f62f422ef9e02aa5ad325459337dffcb707) Add fotmob tests; add 'read_game_match_stats' method - [`3c2771d`](https://github.com/probberechts/soccerdata/commit/3c2771dfb4b0c168e798d6a64da71be7dafed880) Merge branch 'probberechts:master' into fotmob - [`1e01e72`](https://github.com/probberechts/soccerdata/commit/1e01e725fa3b4a6d36cbeaaef2257876fbf027d8) Merge branch 'probberechts:master' into fotmob - [`8ece422`](https://github.com/probberechts/soccerdata/commit/8ece4228c4215164a43732bf2cd3c6e47addd337) fix: read_league_table() for leagues without playoffs - [`d3d3b9f`](https://github.com/probberechts/soccerdata/commit/d3d3b9f33eaae0c054c206d1a87baa89177d61f3) Merge branch 'fotmob' of https://github.com/marcjbaron/soccerdata into fotmob - [`90224ec`](https://github.com/probberechts/soccerdata/commit/90224ec6e6a534f79bcccfadddd4a0f7c28c8592) Update tests; change formatting; use translate_leagues - [`9d4365e`](https://github.com/probberechts/soccerdata/commit/9d4365ef12c488df749a6ab082414376a65be31b) Fix formatting - [`b1a0f5f`](https://github.com/probberechts/soccerdata/commit/b1a0f5f37516bceeb15dd7bbecc7b2c5a7ce6975) Reduce complexity of read_league_table function ### 📊 Changes **14 files changed** (+1259 additions, -4 deletions) <details> <summary>View changed files</summary> 📝 `.github/labels.yml` (+3 -0) 📝 `README.rst` (+4 -3) ➕ `docs/datasources/FotMob.ipynb` (+749 -0) 📝 `docs/datasources/index.rst` (+1 -0) 📝 `docs/howto/custom-leagues.rst` (+7 -0) 📝 `docs/index.rst` (+3 -1) ➕ `docs/reference/fotmob.rst` (+8 -0) 📝 `docs/reference/index.rst` (+1 -0) 📝 `soccerdata/__init__.py` (+2 -0) 📝 `soccerdata/_config.py` (+7 -0) 📝 `soccerdata/fbref.py` (+1 -0) ➕ `soccerdata/fotmob.py` (+437 -0) 📝 `tests/conftest.py` (+6 -0) ➕ `tests/test_FotMob.py` (+30 -0) </details> ### 📄 Description Hello, This is an attempt at adding Fotmob as a data source to soccerdata. The nox test suite passed without errors, with the exception of the python-3.8 tests (but the current python dependency in the pyproject.toml file is >=3.9, so I don't know if this can be safely ignored). Unit tests were also created and passed successfully. The current methods are: - read_seasons(), read_leagues(), read_schedule() (similar to the other data sources) - read_match_stats() -> reads stats for an individual game - read_league_table() -> this functionality is not included in the other data sources, but I needed it for a personal project, so kept it in. There are obviously other methods that could be added (e.g. season stats), but did not want to go much further until early issues are dealt with. --- <sub>🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.</sub>
kerem 2026-03-02 15:58:36 +03:00
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
starred/soccerdata#580
No description provided.