mirror of
https://github.com/probberechts/soccerdata.git
synced 2026-04-25 18:15:58 +03:00
[PR #420] [MERGED] [WhoScored] Ignore cached events file if empty #542
Labels
No labels
ESPN
FBref
FotMob
MatchHistory
SoFIFA
Sofascore
WhoScored
WhoScored
bug
build
common
dependencies
discussion
documentation
duplicate
enhancement
good first issue
invalid
performance
pull-request
question
question
removal
understat
wontfix
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference
starred/soccerdata#542
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
📋 Pull Request Information
Original PR: https://github.com/probberechts/soccerdata/pull/420
Author: @shufinskiy
Created: 10/26/2023
Status: ✅ Merged
Merged: 11/9/2023
Merged by: @probberechts
Base:
master← Head:size_cache📝 Commits (6)
c1a8c2aadd _size_file method to BaseReader classc43395dMerge branch 'master' of github.com:probberechts/soccerdata into size_cacheaeb1229fix description for flake8 and blackc8930f5Merge branch 'master' of github.com:probberechts/soccerdata into size_cache3eb9c36rm _size_file method from BaseReader7975d00check that Whoscored reader is not null📊 Changes
1 file changed (+8 additions, -0 deletions)
View changed files
📝
soccerdata/whoscored.py(+8 -0)📄 Description
Hello, @probberechts.
I propose a solution to the problem of empty files in the cache for Whoscored.
In issue 98 you suggest delete empty file with bash command by file size.
I made method
_size_filewhich does same withPath.stat().st_size. If the file is smaller than threshold, we believe that it is not cached🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.