Topic on Extension talk:Lingo/Flow

Warning on global variable

10
Summary by Elcapitan68

Lingo REL1_39 is free of this bug. The issue was SemanticGlossary pulling an outdated Lingo version.

Allanext2 (talkcontribs)

MW 1.39, php 8.1, Lingo extension REL1_39 and I'm getting:

Warning: Undefined global variable $wgParser in/var/www/html/extensions/Lingo/src/Lingo.php on line53

Elcapitan68 (talkcontribs)

Hi @Allanext2, please let me know what installation method did you use (cloning Git repo, composer or something else)?

Allanext2 (talkcontribs)

Hi @Elcapitan68,

I have it installed with a git submodule from the github repo, below the entry in .gitmodules:

[submodule "data/extensions/Lingo"]

path = data/extensions/Lingo

url = https://github.com/wikimedia/mediawiki-extensions-Lingo.git

branch = REL1_39

I then do:

git submodule init

git submodule update

git submodule foreach -q 'branch="$(git config -f $toplevel/.gitmodules submodule.$name.branch)"; echo "Extension $name:"; git switch $branch'

Thank you !

Elcapitan68 (talkcontribs)

Please check paths, REL1_39 of Lingo seems to be free of wgParser:

w/extensions/Lingo$ php -v
PHP 8.1.27 (cli) (built: Dec 21 2023 20:19:54) (NTS)
Copyright (c) The PHP Group
Zend Engine v4.1.27, Copyright (c) Zend Technologies
    with Zend OPcache v8.1.27, Copyright (c), by Zend Technologies

w/extensions/Lingo$ git status
On branch REL1_39
Your branch is up to date with 'origin/REL1_39'.

nothing to commit, working tree clean

w/extensions/Lingo$ grep -R wgParser ./
w/extensions/Lingo$ 

See here.

Is there a chance that you mount an outdated branch some way?

What happens if you checkout the tag?

cd extensions/Lingo

git checkout 3.2.0
Allanext2 (talkcontribs)

@Elcapitan68 You're right the REL1_39 branch in clean of wgParser.

The issue is that when Semantic Glossary is installed (dev-master branch) with `composer update --no-dev` it requires the dependency Lingo 3.1.1 which overrides files

Allanext2 (talkcontribs)
Elcapitan68 (talkcontribs)
Elcapitan68 (talkcontribs)

Please confirm understanding.

Elcapitan68 (talkcontribs)
2A01:11:9210:26B0:258E:CEB:849B:823B (talkcontribs)