Help Convert Module Pages to the New Module Library

We have no way of knowing what the authors meant by “long” or “short”. Project owners can edit the durations later if they wish.

I guess you rejected / can’t use the BGG data?

1 Like

The following code can query the BGG API (XML) for game information - either by BGG identifier or by name (possible with a year)

#!/usr/bin/env python

# --------------------------------------------------------------------
def request(query,base='https://boardgamegeek.com/xmlapi/'):
    '''Do a request against BGG API

    Parameters
    ----------
    query : str
        Query string - need to be URL encoded

    Returns
    -------
    response : str
        Response text (XML)
    '''
    from requests import get
    
    url = base + query
    response = get(url)
    return response.text

# --------------------------------------------------------------------
def parse(text):
    '''Parse XML reponse text and return as dictonary

    Parameters
    ----------
    text : str
        XML response text

    Returns
    -------
    db : dict 
        Dictionary of reponse
    '''
    from xml.dom.minidom import parseString

    doc = parseString(text)
    top = doc.documentElement
    
    return {top.tagName:parseNode(top)}['boardgames']

# --------------------------------------------------------------------
def parseNode(node):
    '''Parse a single node and recurse

    Node attributes are stored in returned dictionary.

    Child nodes are stored as dictionaries.  In case there's more than
    one child node of a particular type, then those nodes are stored
    in a list.

    Parameters
    ----------
    node : xml.dom.minidom.Node
        Node to parse

    Return
    ------
    db : dict
        Dictionary of attributes and children
    '''
    from xml.dom.minidom import Text, Document

    ret   = {}
    attrs = node.attributes
    for ind in range(len(attrs)):
        attribute = attrs.item(ind)
        ret[attribute.name] = attribute.value
        
    for child in node.childNodes:
        if isinstance(child,Text):
            data = child.data.strip('\t').strip('\n')
            if len(data) > 0:
                ret['text'] = data
            continue

        dct = parseNode(child)
        tag = child.tagName
        if tag in ret:
            if isinstance(ret[tag],dict):
                old = ret[tag]
                ret[tag] = [old]
            ret[tag].append(dct)
        else:
            ret[tag] = dct

    return ret


# --------------------------------------------------------------------
def get_info(name,iden,year=None,exact=True):
    '''Get information about a game, by name or identifier

    Names are looked up.  If year is given, then filter by year.  If
    exact is true, then match names exactly.

    Parameters
    ----------
    iden : int
        Game identifier
    name : str
        Name of game
    year : int
        Optional year to narrow searces with
    exact : boolean
        If true, match exact name

    Return
    ------
    db : dict 
        Dictionary of game
    opt : list
        List of options found

    '''
    
    idens = [iden]
    if iden is None:
        from urllib.parse import quote_plus
        qname = quote_plus(name)
        info  = parse(request(f'search?search={qname}'
                              f'&exact={1 if exact else 0}'))
        cand  = info.get('boardgame',None)

        if cand is None:
            raise RuntimeError(f'"{name}" not found')


        if isinstance(cand,list):
            idens = [c.get('objectid',None) for c in cand
                     if year is None or
                     year == int(c.get('yearpublished',{}).get('text',0))]

    ret = [parse(request(f'boardgame/{iden}'))
           for iden in idens if iden is not None]

    if len(ret) == 1:
        return ret[0]

    return ret
        
# ====================================================================
def show(info):
    '''Print final result of the query'''
    from pprint import pprint

    if not isinstance(info,list):
        pprint(info)
        return
        
    print(f'Got back {len(info)} replies, please narrrow')
    for inf in info:
        # print(inf)
        dct = inf.get('boardgame',{})
        nam = dct.get('name',None)
        if isinstance(nam,list):
            nams = nam
            for n in nams:
                nam = n
                if 'primary' in n and n['primary'] == 'true':
                    break

        nam  = nam.get('text','<<?>>')
        iden = int(dct.get('objectid',0))
        year = int(dct.get('yearpublished',{}).get('text',0))
        print(f'{iden:8d}: {nam} ({year})')

# ====================================================================
if __name__ == '__main__':
    from argparse import ArgumentParser
    from pprint import pprint
    
    ap = ArgumentParser(description='Get info from BGG')
    ap.add_argument('-i','--id',type=int,
                    help='Get by board game ID')
    ap.add_argument('-n','--name',type=str,
                    help='Get by name')
    ap.add_argument('-y','--year',type=int,
                    help='Narrow name search by year')
    gr = ap.add_mutually_exclusive_group()
    gr.add_argument('--any', action='store_false',dest='exact',default=True,
                    help='Loose matching of name')
    gr.add_argument('--exact', action='store_true',
                    help='Exact matching of name')

    args = ap.parse_args()
    # print(vars(args))
    

    if args.name is None and args.id is None:
        raise RuntimeError('Please specify a name or id')
    
    show(get_info(args.name,args.id,args.year,args.exact))

# --------------------------------------------------------------------

Use it if you like - perhaps that can help fill some stuff on the game pages too.

See also here for more on the BGG API.

Yours,
Christian

1 Like

Compare Afrika Korps (old vs new)

According to a previous thread variants of modules by the same maintainer should show up as different packages within the same project (and projects are split by maintainers - but I gues you haven’t done that yet). For Afrika Korps, that means that

  • AfrikaKorps-2.1-ch.vmod, AfrikaKorps-2.0-ch.vmod, and AfrikaKorps-1.1-ch.vmod should be one package, and
  • AfrikaKorps-2.1-ch-oldschool.vmod, AfrikaKorps-2.0-ch-oldschool.vmod, and AfrikaKorps-1.1-ch-oldschool.vmod should be a different package.

with obvious version numbers. Similar for D-Day ch project.Thanks.

Yours,
Christian

1 Like

Good point. I was actually comparing the two, anyway (I noticed both versions of Talisman were missing from the new library), but I will explicitly commit to all the "T"s up to “Terrible Swift Sword” as listed in the old library, instead.

1 Like

I will take the rest of the "C"s - all those not starting with “Co…” (which marktb1961 is looking at).

1 Like

Some developer (& player) emails have been replaced by links to user pages, like this:-

https://forum.vassalengine.org/u/<username>

But I can’t see any emails on the user pages so I can’t check if they are correct.

Example: In Caesar’s Legions Stephen Oliver’s email is replaced by user “iam2509” - are they the same person?

All of them should be. If you find any which are not, I’d like to know.

We’ve matched wiki users to forum users by email address so where that has happened, I’m confident that the users are the same.

Yes, that’s correct. I have not worked through all the problems with pages listed as checked. The purpose of checking is to find the problems.

1 Like

I like this if we match the identifier (which is their prime identifier iirc). We should be leveraging this.

1 Like

The new “Project” section shows owners but does not mention any contributors - even when they are listed in the old “Module Information” section - is that correct?

Hi,

Fair enough. Some thoughts - also pertaining to

The current database schema for the Game Library Service looks like

I propose, to accommodate the “same module” discussion a schema like

(changed tables have a * next to their name).

  • New games table that is the parent of projects. This subsumes “game” data from the projects table, and includes the bgg_id field to refer back to BoardGameGeek. The front-end can also use that to look-up additional information if so desired. The games rows has two fields summary and text which should contain a short and longer description, respectively, of the game. This could be lifted from BGG - either in the back-end or front-end as needed.
  • projects table is a lot smaller as most information is stored in the games table. Also note that each projects row has summary and text fields - similar to the games rows. The summary field could be shown by the front end so that users may quickly and easily get an overview of the various projects of a single game.
  • files do not point to projects but only to packages as each file will belong to a package - not a project.

I think it would be a good idea to get something like this in place before you start to consolidate the database, let alone deploy it. It will be a huge hassle to remake the database to accommodate the “same module” categorisation of “projects”.

Yours,
Christian

In the current database scheme, the game_length field is configured as TEXT, so it seems that there’s no reason why you couldn’t store short, medium, long there. Perhaps you need another field game_minutes which records the average number of minutes a game takes, if given.

Yours,
Christian

Here are the "C"s (other than the "Co"s)

C.V: A game of the Battle of Midway

  • missing version number (1.0) in Packages

C.A. Tactical Naval Warfare in the Pacific, 1941-45

  • I can’t find this in the old library - so no checks were possible

[edit] (I found it in the old library)

  • too many Packages

[/edit]

Cacao

  • the manual pdf is in the Version 1.0 area in the old library but is marked 0.0.0 in the new

Caesar in Alexandria

  • version 1.0: new date says “15 years ago” old library says “2014”

Caesar’s Gallic War

  • Version 3.1 is in a separate Package with the wrong version number
  • Version 2.3 has wrong version number
  • Version 2.2 module is missing
  • Version 1.0 is in a separate Package

Caesar’s Legions

  • Version 2.4 is in a separate Package

Caesar: Epic Battle of Alesia

  • Packages Alesia & ceasar - no version numbers
  • ceasar setup files are in a separate Package & have no version number
  • the heading “Alternate Version” from Files section is moved to the Readme section

Caesar: Rome vs Gaul

  • version 1.1 has wrong version number
  • version 1.0 module is missing

A Call to Arms: Babylon 5 Space Combat

  • Acta_2e_v1.36release - no version number
  • Acta_2e_v1.3release - no version number
  • versions 1.2, 1.3 & 1.36 all in different Packages

Camelot

  • the era is obviously wrong

Campaign Commander Volume I: Roads to Stalingrad

  • Versions 1.2 & 1.3 are in a separate Package

Campaign Commander Volume II: Coral Sea

  • Versions 2.0 & 2.1 have wrong version numbers and are in a separate Package

Campaign Commander Volume III: Punic Island

  • Version number and Packaging problems - 1.0 & 1.03b

The Campaign for North Africa: The Desert War 1940-43

  • Version 0.93 setup file has no version number

The Campaigns of King David

  • Topic missing

Canadian Crucible: Brigade Fortress at Norrey

  • Versions 1.1.33 & 1.1.34 are in separate Packages

Cannonball Colony

  • Missing version numbers

Canope 1801

  • Version 1.4 has wrong version number & in separate Package

Captain’s Sea

  • Wrong version number

Carcassonne

  • Versions 1.2, 2.0, 2.0.1, 2.0.2 in separate Packages
  • Documents are specific to versions but have no version numbers

Cards Against Humanity

  • “CardsAgainstHumanity1_0+Custom.vmod” probably should be version 1.0
  • “Cards_against_humanity_custom.vmod” missing
  • extensions are missing compatibility
  • red box text “I have personally…” is missing

Carrier

  • all versions in separate Packages, missing/wrong version numbers

Carson City

  • module “Carson City.vmod” is in a separate Package

Carthage: The First Punic War

  • module “Carthage.vmod” is in a separate Package & has no version number

Case Blue / Guderian’s Blitzkrieg II

  • module “CaseBlue_GBII_v510.vmod” has wrong version number
  • modules “CaseBlue_GBII_v4_25_rc4.vmod” & “CaseBlue_GBII_v6_17-01.vmod” have wrong version numbers and are in separate Packages
  • extension “OCS_HQ_0_2.vmdx” is missing compatibility

Case Yellow, 1940: The German Blitzkrieg in the West

  • headings “Scenarios 1 and 2” & “Scenario 3” in the old files section have been moved to Readme
  • “CY_SC_3_v1_0.vmod” is in separate Package

Cassino 1944

  • module “Cassino 1944 Italian Front.vmod” has wrong version number

Castle Panic

  • version numbers 1.0 & 2.0 in separate Packages

Cataclysm: A Second World War

  • module “Cataclysm v1’1a.vmod” has wrong version number and is in a separate Package

Cataphract / Attila

  • module “Cataphract.vmod” has no version number and is in separate Package
  • extension “Attila.vmdx” & file “CataphractReadme.txt” are part of version 2.1 but have been moved to files Package and lost this connection
  • headings “Cataphract Saved Games” & “Attila Saved Games” have been lost

The Caucasus Campaign: The Russo-German War in the Caucasus, 1942

  • module “The_caucasus_campaign_1_3.vmod” is in a separate Package

Cedar Mountain: The Prelude to Bull Run, August 9, 1862

  • modules have wrong version numbers and are in separate Packages

Central America

  • module “Central_America_v.1.12.vmod” has wrong version number
  • modules spread over 5 different Packages

Central Front Series

  • pdf & txt files have been put in Files Package and lost connections to their modules
  • red box text missing

CEP: Combate en el Espacio Profundo

  • red box text missing
  • Readme: links to Pedro-Juan Ferrer & Ediciones Sombra missing

Chabyrinthe

  • version number missing

Chaco

  • “Chaco_Notes.txt” missing version number

Chainsaw Warrior

  • red box text missing

Champs de Bataille

  • image missing from Readme

Chancellorsville: Bloody May, 1863

  • module version 1.1 missing, 1.2 has wrong version number

Chandragupta

  • version 2.0.0 developer has been changed
  • Readme has some formatting problems with asterisks v. dots

Chaostle

  • there are no VASSAL modules here (after 11 years)

Charioteer

  • no entry in the new library

Chariots of Fire

  • too many Packages

Cherburg of Somnium

  • too many Packages

Chicago Express

  • no entry in the new library

Chieftain, An Assault Series Module

  • no entry in new library
  • old library says this is an extension to Assault & gives link

Chitin: I

  • too many Packages
  • Players list omits “davidk64”

Chu Shogi

  • version number missing

Circle of Fire: The Siege of Cholm, 1942

  • too many Packages

Circus Maximus

  • too many Packages

Citadel of Blood

  • missing link for “(Other modules by brian448)”
  • Players list omits “davidk64”

Citadels

  • too many Packages
  • appears to be 4 English versions (“Citadels”) & 2 Spanish (“Ciudadelas”)
  • “Citadels1.2.2_Eng.vmod” has wrong version number

City of Guilds

  • missing version number

Cité

  • missing version number

Civil War

  • missing link for “(Other modules by brian448)”

Civil War Game 1863

  • missing version number

Clash of Monarchs

  • module “CoM_1.31.vmod” wrong version number - should be 1.3.1

Climate change – the board game

  • too many Packages
  • module “ClimateChange.vmod” wrong version number - should be 1.0
  • missing link for “(Other modules by Alecrespi)”

Clixers

  • the vassalengine.org link in Readme does not work

Clontarf

  • heading “1.0” in old “Files and Module Information” section is moved to Readme

Close Action

  • too many Packages

Close Assault

  • module “Close_Assault.vmod” missing version number

Cluedo

  • module not uploaded in old library, no Packages in new library

All games beginning “Co…” will be checked by marktb1961

Crash Tackle

  • module “Ct_module_3.21.vmod” wrong version number - should be 3.2.1

Crescendo of Doom (& Cross of Iron)

  • no entry in new library
  • old library says this is an extension to Squad Leader & gives link

Crimean War Battles

  • modules “CrimQuad TchernayaR 1-1.vmod” & “CrimQuad Inkerman 1.vmod” missing

Cripmaquion

  • modules “Cripmaquion_1.2.vmod”, “Cripmaquion_1.1.vmod” & “Cripmaquion.vmod” missing
  • module “Cripmaquion_1.3.vmod” wrong version number

Crisis: Sinai 1973

  • too many Packages
  • spurious '" in Readme, after black dots

Critical Collapse

  • red box text missing

Crossing the Line: Aachen 1944

  • too many Packages

Crusade and Revolution: The Spanish Civil War, 1936-1939

  • Package & version number problems

Crusader

  • too many Packages

Cry Havoc

  • module “CryHavoc11.vmod” wrong version number
  • all extensions have been placed in the Files section - the distinction between official & unofficial ones has been lost
  • Players list omits “davidk64”

Cuba Libre

  • Readme, following “Version 1.3.2 Update:” - empty ().

Cudgel Duel: Franco’s first counterstrikes at the Ebro, Aug-Sep 1938

  • module “cudgel_duel_1.01.vmod” missing
  • module “cudgel_duel_1.02.vmod” wrong version number

Apologies in advance if some of these are red herrings/expected behaviour.

1 Like

This is expected. The frontend doesn’t list contributors at present.

You’re referring to a stale database schema; game_length was removed on 13 July. The current one has game_length_min and game_length_max.

I am going to tackle the "D"s.

1 Like

I need to look at that a lot more when I have time but I believe we are on the same page.
Ultimately we could eat their db and even create the module pages where we have no actual module in existence and place a method of making the page “currently inactive” until such time somebody makes the module and uploads and gets an option" hi btw is this the game you are referring to ?.."

Take out all the legwork from the developer as far as page creation goes and for us…

I will review the “E” group over the holiday weekend

1 Like

Results from “D” section:-

D-Day

  • too many Packages (possibly - many different modules present, difficult to tell the relationships between them)
  • multiple incorrect version numbers
  • Readme, final para - text & link “File:D-Day-v3.0a.vmod” missing

D-Day - Smithsonian Edition

  • Package & version number problems

DAK2

  • Package problems

The Damned Die Hard: Philippines '41

  • wrong version numbers

Damocles Mission

  • missing - (Other modules by brian448) link

Dante’s Inferno

  • missing - (Other modules by brian448) link

Dark Emperor

  • missing - (Other modules by brian448) link

Dark Nebula

  • missing - (Other modules by Mycenae) link

The Dark Valley

  • too many Packages?
  • version numbers missing

Das Boot: Der deutsche U-Bootkrieg, 1939-1943

  • no entry in new library
  • German language version of Steel Wolves, old library has link to Steel Wolves page

Dauntless

  • no entry in new library
  • old library has “included as part of this base module” + link

Dawn of the Zeds (Third edition)

  • 1.1 module date (in old lib) & age (in new lib) don’t tally

Dawn Patrol: Role Playing Game of WW I Air Combat

  • module version number problems

DC Comics Dice Masters: Justice League & DC Comics Dice Masters: War of Light

  • no entry in new library
  • in old library included in another module & linked

Dead of Winter

  • too many Packages

Deadlands:Doomtown

  • Players: “davidk64” missing

Death in the Trenches: The Great War 1914-1918 (Second Edition)

  • too many Packages
  • module “DitT_1.1b.vmod” missing (added since copy made?)

Death Ride Kursk: Gross Deutschland

  • the zip files are associated with different module versions in the old library - in the new one they are in Files & this distinction is lost

DeathMaze

  • file dates/ages: old says “unknown”, new says “4 years”

Defiant Russia: Operation Barbarossa, 1941

  • not in new library

Dejarik

  • missing - (Other modules by brian448) link

Delve the Card Game

  • red box text missing

Delve: The Dice Game

  • version number missing
  • Vassal Factory link broken

Demonlord

  • images in Readme missing
  • red box text missing

Demons

  • missing - (Other modules by brian448) link
  • Players: “davidk64” missing

Dennewitz 20

  • green box/link to Grossbeeren 20 is broken

Derelicts of Sin: Heresy

  • box cover image missing

Descent on Crete: May 1941

  • module version number missing

Desert War

  • no entry in new library
  • in old library included in another module & linked

Destruction of Army Group Center: The Soviet Summer Offensive

  • missing version number

Devil Boats: PT Boats in the Solomons

  • too many Packages

The Devil’s Cauldron

  • version 6.4.6 missing (2 copies in old lib!)
  • version 6.5 compatibility error
  • zip file version number errors

Devil’s Horsemen

  • module “DH.vmod” in separate Package and missing version number

Dice Masters Draft

  • no entry in new library
  • in old library modules removed

The Devil’s To Pay

  • module “Devils2PayR3a.vmod” in separate Package & wrong version number
  • pdf files have lost their version 2/3 distinctions

Dien Bien Phu: The Final Gamble

  • too many Packages

Dig

  • missing - (Other modules by brian448) link

Dinosaurs of the Lost World

  • Players: “davidk64” missing

District Commander Maracas: Virtualia 2019

  • too many Packages

Divided America: The Next Civil war

  • module has wrong version number
  • extra player in new listing Players

Divine Right

  • too many Packages
  • extension “Immunity_1.1.vmdx” has lost its compatibility
  • module “Divineright 4.0.4.vmod” - wrong version number
  • module “Divineright_3.2.3.1.vmod” - in separate Package and wrong version number (4 part version number!)

Dixit

  • module “Dixit 0.7eng beta.vmod” - missing version number
  • module “Dixit 0.8 beta.vmod” - missing version number
  • module “Dixit 0.7 beta.vmod” missing

DNPS

  • wrong version number

Dominant Species

  • module “DominantSpecies_v1-1fs.vmod” missing version number

Dominion

  • extensions have lost their version numbers & compatibility values

Dominion: Alchemy, Dominion: Intrigue, Dominion: Prosperity & Dominion: Seaside

  • no entries in new library, old library has links back to base game

Dominoes

  • missing - (Other modules by brian448) link

Donau Front

  • no entries in new library, old library has links back to base game

Door2Door

  • no Packages in new library, missing module file in old library

Double-Play Baseball

  • missing - (Other modules by brian448) link

Downfall of Empires

  • module “DoE_1.1.vmod” missing
  • module “DoE_1.2.vmod” wrong version number
  • compatibility values are suspect

The Downfall of Pompeii

  • too many Packages

Downtown: Air War Over Hanoi, 1965 - 1972

  • module “Downtown-2-99l.vmod” is in separate Package & missing version number
  • compatibility values are missing or suspect

Dragon Pass

  • Players: “davidk64” missing

Dragonlance

  • in new library: version number & age suspect

Dragonriders of Pern

  • Players: “davidk64” missing

Dragons of Glory

  • in new library: version number & age suspect

Drang Nach Osten!

  • version number wrong

The Draugr

  • missing - (Other modules by brian448) link

Dreadball

  • version number wrong

Dreamblade

  • too many Packages
  • module “Dreamblade_2-4beta.vmod” missing version number
  • some formatting problems & missing screen shot images in Readme

Drive on Paris

  • too many Packages

Drive on Washington: The Battle of Monocacy Junction, July 9, 1864

  • too many Packages

Druid: Boudicca’s Rebellion, 61 A.D.

  • too many Packages
  • module “DRUID.vmod” missing version number

DSE-Death Can Wait

  • module “Death_Can_Wait_MMAS_v1.vmod” wrong version number

Duel for Kharkov

  • module “Duel_for_Kharkov_0.9.vmod” wrong version number

Duel of Ages II

  • too many Packages

Dune

  • too many Packages
  • extensions have lost compatibility values & linkage to their module

Dune Adventure Game

  • extensions have lost compatibility values
  • missing - (Other modules by Mycenae) link
  • Players: “davidk64” missing

Dune Express

  • missing version number

Dune: War for Arrakis

  • not in new library

Dungeon

  • missing - (Other modules by brian448) link
  • Players: “davidk64” missing

Dungeon Alliance

  • module “Dungeon_Alliance_1.0.vmod” missing
  • module “Dungeon_Alliance_1.1.vmod” wrong version number

Dungeon Command: Blood of Gruumsh, Dungeon Command: Curse of Undeath, Dungeon Command: Heart of Cormyr, Dungeon Command: Sting of Lolth & Dungeon Command: Tyranny of Goblins

  • no entries in new library, old library has links back to base game

Dungeon Crawler

  • deck files have lost compatibility values

Dungeon Plungin’

  • missing - (Other modules by brian448) link

Dungeon Run

  • missing - (Other modules by brian448) link

Dungeon Universalis

  • extension has lost compatibility value
  • module “Dungeon Universalis Campaign Sheet 2.0.vmod” wrong version number
  • Files section headings “Extension” & “Module” moved to Readme

Dungeoneer: Tomb of the Lich Lord

  • missing version numbers

Dungeonquest

  • red box text missing

Dungeons & Dragons Dice Masters: Battle for Faerûn

  • no entries in new library, old library has links back to base game

Dungeons & Dragons Miniatures

  • module “RPGMapper.vmod” missing version number
  • extensions “DDM2 Extension.vmdx” & “Scenario_cache.vmdx” no version numbers

Dungeons & Dragons: Attack Wing

  • module version number??

Durrenstein & Schongraben 1805

  • too many Packages
  • module “Schongraben_JDG_1.4.vmod” wrong version number

Dust Halo

  • module “Dusthalo.vmod” missing version number

Déluges

  • module “Deluges.vmod” missing version number

.

1 Like