dopecodez / Wikipedia

Wikipedia for node and the browser
MIT License
82 stars 19 forks source link

Incorrect data parsed from Infobox #33

Closed admehta01 closed 2 years ago

admehta01 commented 2 years ago

https://en.wikipedia.org/wiki/All_Around_the_World_(Lisa_Stansfield_song)

const page = await wiki.page(pageTitle);
return page.infobox({ redirect: false });

returns

{
  name: 'All Around the World',
  cover: 'Lisa Stansfield - All Around the World.jpg',
  border: true,
  caption: 'Artwork for releases outside North America',
  type: 'Singles',
  artist: '2003',
  album: 'Affection (Lisa Stansfield album)',
  bSide: '"Wake Up Baby" (7"),"The Way You Want It" (12")',
  released: '16 October 1989',
  recorded: '1989',
  length: 'Duration',
  label: 'Arista Records',
  writer: [ 'Lisa Stansfield', 'Ian Devaney', 'Andy Morris' ],
  producer: [ 'Ian Devaney', 'Andy Morris' ],
  prevTitle: '8-3-1',
  prevYear: '2001',
  nextTitle: 'Too Hot (Kool & the Gang song)',
  nextYear: 'External music video',
  misc: 'Extra chronology',
  title: 'All Around the World (Norty Cotto Mixes)',
  year: '2003'
}

artist: '2003' is off

admehta01 commented 2 years ago

Closing and opening an issue here instead: https://github.com/dijs/infobox-parser/issues/33

dopecodez commented 2 years ago

Have you tried using the summary in wikipedia, it will give you the neccesary details. In case you want to use the infobox explicitly, we need a fix from dijs/infobox-parser#33