frontend package

Submodules

frontend.family module

Created on 2021-01-01

@author: wf

class frontend.family.LocalWiki(siteName: str, family=None, localSettings: Optional[str] = None)[source]

Bases: object

a local Wiki

get the local path to the logo file of this wiki

Returns:

the logo path if logo is defined as file else None

Return type:

str

getSetting(varName: str) str[source]

get the setting of the given variableName from the LocalSettings.php

Parameters:

varName (str) – the name of the variable to return

Returns:

the value of the variable

Return type:

str

getStatusCode(timeout=0.5)[source]

get the status Code for my url

Parameters:

timeout (float) – the maximum time to wait for a response

Returns:

html statusCode or -1 if there was a timeout

Return type:

int

class frontend.family.WikiBackup(wikiuser)[source]

Bases: object

find out details about a WikiBackup

potentially this class needs to move upstream to py-3rdparty-MediaWiki

exists() bool[source]

check if this Backup exists

Returns:

True if the self.backupPath directory exists

Return type:

bool

hasGit() bool[source]

check if this Backup has a local git repository

Returns:

True if the self.gitPath directory exists

Return type:

bool

class frontend.family.WikiFamily(sitedir: str = '/var/www/mediawiki/sites')[source]

Bases: object

the wiki family found in the given site dir

frontend.server module

frontend.site module

Created on 2020-12-31

@author: wf

class frontend.site.Site(name: str, defaultPage: str = 'Main Page', lang: str = 'en', debug=False)[source]

Bases: object

migrated from: https://github.com/BITPlan/com.bitplan.wikifrontend/blob/master/src/main/java/com/bitplan/wikifrontend/Site.java

configure(config: dict)[source]

configure me from the given configuration :param config: the configuration to use :type config: dict

open(appWrap=None)[source]

open this site

Parameters:

appWrap (appWrap) – optional fb4 Application Wrapper

frontend.webserver module

frontend.widgets module

frontend.wikicms module

Module contents