Skip to content

game_lineups crawler assigns incorrect club ID #83

@dcaribou

Description

@dcaribou

In the scenario of a missing lineup information for some of the teams, the logic assigning lineups and substitutes for home/away clubs does not work. This causes some players to be incorrectly assigned to the wrong team in the game.

For example, for this game, Alexander Baun is assigned to the home club (5781), while it should've been assigned to the away club (33872).

image
{
  "type": "game_lineups",
  "parent": {
    "href": "/spielbericht/index/spielbericht/2874429",
    "type": "game"
  },
  "href": "/spielbericht/aufstellung/spielbericht/2874429",
  "game_id": 2874429,
  "home_club": {
    "href": "/vejlby-risskov-idraetsklub/startseite/verein/33872/saison_id/2017",
    "formation": "3-4-3",
    "starting_lineup": [
      {
        "number": "24",
        "href": "/emil-kobberup/profil/spieler/385437",
        "name": "Emil Kobberup",
        "team_captain": 0,
        "position": "Goalkeeper"
      },
      {
        "number": "23",
        "href": "/christoffer-ostergaard/profil/spieler/261886",
        "name": "Christoffer Östergaard",
        "team_captain": 0,
        "position": "Centre-Back"
      },
      {
        "number": "45",
        "href": "/magnus-jensen/profil/spieler/448471",
        "name": "Magnus Jensen",
        "team_captain": 0,
        "position": "Centre-Back"
      },
      {
        "number": "88",
        "href": "/lasse-sorensen/profil/spieler/527825",
        "name": "Lasse Sörensen",
        "team_captain": 0,
        "position": "Centre-Back"
      },
      {
        "number": "8",
        "href": "/jesper-henriksen/profil/spieler/95754",
        "name": "Jesper Henriksen",
        "team_captain": 0,
        "position": "Central Midfield"
      },
      {
        "number": "19",
        "href": "/jeppe-bjerregaard/profil/spieler/427490",
        "name": "Jeppe Bjerregaard",
        "team_captain": 0,
        "position": "Central Midfield"
      },
      {
        "number": "18",
        "href": "/frederik-buur/profil/spieler/375797",
        "name": "Frederik Buur",
        "team_captain": 0,
        "position": "Right Midfield"
      },
      {
        "number": "20",
        "href": "/thomas-santos/profil/spieler/523476",
        "name": "Thomas Santos",
        "team_captain": 0,
        "position": "Attacking Midfield"
      },
      {
        "number": "33",
        "href": "/simon-sterring/profil/spieler/283218",
        "name": "Simon Sterring",
        "team_captain": 0,
        "position": "Left Winger"
      },
      {
        "number": "7",
        "href": "/oliver-pedersen/profil/spieler/394491",
        "name": "Oliver Pedersen",
        "team_captain": 0,
        "position": "Centre-Forward"
      },
      {
        "number": "21",
        "href": "/andreas-kock/profil/spieler/375798",
        "name": "Andreas Kock",
        "team_captain": 0,
        "position": "Centre-Forward"
      }
    ],
    "substitutes": [
      {
        "number": "30",
        "href": "/andreas-raahauge/profil/spieler/283232",
        "name": "Andreas Raahauge",
        "team_captain": 0,
        "position": "Goalkeeper"
      },
      {
        "number": "10",
        "href": "/mathias-pedersen/profil/spieler/202732",
        "name": "Mathias Pedersen",
        "team_captain": 0,
        "position": "Central Midfield"
      },
      {
        "number": "77",
        "href": "/alexander-baun/profil/spieler/485732",
        "name": "Alexander Baun",
        "team_captain": 0,
        "position": "Right Winger"
      },
      {
        "number": "11",
        "href": "/jeppe-mogensen/profil/spieler/321872",
        "name": "Jeppe Mogensen",
        "team_captain": 0,
        "position": "Centre-Forward"
      }
    ]
  },
  "away_club": {
    "href": "/skive-ik/startseite/verein/5781/saison_id/2017",
    "formation": "Starting Line-up: 3-5-2",
    "starting_lineup": [],
    "substitutes": []
  }
}

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions