Closed dirkgomez closed 4 years ago
Thanks for trying sportdb and reporting the error and the analysis. If this line is the cause than the error must be the score format:
1-1 a.e.t. 1-1
I will double check as soon as I get to it, see https://github.com/sportdb/sport.db/blob/master/score-formats/lib/score-formats/formats.rb for all suported formats. A quick "hack" fix might be changing to:
1-1 a.e.t. (1-1)
You can try it locally e.g. unzip the archive or git clone - than change / patch the .txt datafile and than call sportdb build
. Cheers. Prost.
These commits fix quite a lot of the score recognition issues: https://github.com/dirkgomez/world-cup/commit/17abad5fb46f45bd6aa6570b284cd99289b8df89 and https://github.com/dirkgomez/world-cup/commit/b0c5eea09cb5062dc65e16d380138e69386b768b
However now I am troubled by this:
["Saudi Arabia", "Spain"]
[debug] [parse_matchdata] hash: >{:day_name=>"Fri", :month_name=>"Jun", :day=>"23"}<
[debug] [calc_year] ????-6-23 -- start: 2006-01-01
[debug] date: >2006-06-23<
(auto config) try matching teams:
["Ukraine", "Tunisia"]
** !!! ERROR - no match for national team >Serbia and Montenegro< found
The entry for Serbia and Montenegro seems to be missing somewhere else - it is not a parsing issue here (e. g. simply replacing it with Trinidad and Tobago works fine)
Wow. Thanks for taking the time and your help with updating the score to a more uniform format.
** !!! ERROR - no match for national team >Serbia and Montenegro< found
Sorry, yes - that (historic) country name is missing in the history section of the built-in / pre-configured countries, see https://github.com/sportdb/football.db/blob/master/fifa/config/countries.txt. I will add it later today and try to push out a new fifa gem / library. Thanks again.
Update: FYI: I have pulled in and committed your score format changes (thanks again!), see https://github.com/openfootball/world-cup/commits/master and added some more fixes for reported errors (while linting).
FYI: I pushed / uploaded a new fifa gem / library, see https://rubygems.org/gems/fifa/versions/2020.9.13. If you update plus pull in the latest score format fixes all should be good. The linter reports 0 errros and the built went through (with my dev setup). If you still run into any errors, please report. Thanks again. Cheers.
Thanks again for the score format fixes. Have a great weekend. Cheers.
Here's what I did, I created this Datafile:
Ran
which results in this:
I think this line cannot be parsed: https://github.com/openfootball/world-cup/blob/master/1954--switzerland/cup.txt#L21