Wesnoth's Unit Database

Discussion of all aspects of the website, wiki, and forums, including assistance requests and new ideas for them.

Moderator: Forum Moderators

User avatar
Iris
Site Administrator
Posts: 6796
Joined: November 14th, 2006, 5:54 pm
Location: Chile
Contact:

Re: Wesnoth's Unit Database

Post by Iris »

The units database has been rebuilt again. I disabled the weekly rebuild for a while because I was working on some changes that partially landed on master and took forever to finish up — sorry about that.

One major feature I just added is that add-ons processed by the database build script may check for the __WMLUNITS__ preprocessor symbol using #ifdef in order to, for example, use special code to optimize (or even entirely disable) the unit tree display however they see fit. For example, version 0.9.17 of my add-on After the Storm exposes a single dummy campaign menu item instead of the usual three, skips including all scenarios and some code that is only relevant for scenario code, and lets wmlunits see the full unit tree for all three episodes with some minor exceptions.

Additionally, a number of bugs have been fixed.
Author of the unofficial UtBS sequels Invasion from the Unknown and After the Storm.
User avatar
The_Gnat
Posts: 2215
Joined: October 10th, 2016, 3:06 am
Contact:

Re: Wesnoth's Unit Database

Post by The_Gnat »

That is really good!! A while back i looked around for some way to do this, it is great that you have implemented it. :D Thank you!
User avatar
IIIO_METAL
Posts: 202
Joined: January 18th, 2017, 5:03 pm
Location: japan

Re: Wesnoth's Unit Database

Post by IIIO_METAL »

I tried to fix my add-on error, but I am not sure when I encounter the following errors and what to fix next.
The add-on that caused the error is Mountain_Witch and Castle_of_evil_spirit.

internal error (2 lines)

please report as bug
unorderable types: NoneType() < str()

Does anyone know what kind of mistakes I made?
Creator of "Mountain Witch" & "Castle of evil spirit"
User avatar
Ravana
Forum Moderator
Posts: 2933
Joined: January 29th, 2012, 12:49 am
Location: Estonia
Contact:

Re: Wesnoth's Unit Database

Post by Ravana »

Message suggests you did not include some required key.
Prof_Hari_Seldon
Posts: 9
Joined: February 19th, 2018, 12:01 am

Re: Wesnoth's Unit Database

Post by Prof_Hari_Seldon »

Many of the images for the To Lands Unknown units are broken: https://units.wesnoth.org/1.12/To_Lands ... known.html

Even though the Era of Magic (the Age that To Lands Unknown uses) images are not broken: https://units.wesnoth.org/1.12/Era_of_M ... magic.html

What is the easiest way to fix this?
User avatar
josteph
Inactive Developer
Posts: 741
Joined: August 19th, 2017, 6:58 pm

Re: Wesnoth's Unit Database

Post by josteph »

I replied to your other post https://forums.wesnoth.org/viewtopic.ph ... 45#p636784. Please don't double post. If you have specific questions about the script do ask them here though.
User avatar
James_The_Invisible
Posts: 533
Joined: October 28th, 2012, 1:58 pm
Location: Somewhere in the Northlands, fighting dark forces
Contact:

Re: Wesnoth's Unit Database

Post by James_The_Invisible »

I just noticed that 1.14 version does not show units for almost all user-made campaigns and eras, actually even mainline eras are not listed. One can see only all mainline campaigns + 1 user-made one and 3 user-made eras. Build report does not show any error for most add-ons.
1.12 version looks unaffected.
User avatar
Ravana
Forum Moderator
Posts: 2933
Joined: January 29th, 2012, 12:49 am
Location: Estonia
Contact:

Re: Wesnoth's Unit Database

Post by Ravana »

please report as bug
'NoneType' object has no attribute 'rfind'
User avatar
Ravana
Forum Moderator
Posts: 2933
Joined: January 29th, 2012, 12:49 am
Location: Estonia
Contact:

Re: Wesnoth's Unit Database

Post by Ravana »

I got further in locally running wmlunits than my last attempt. Some observations:
- wmlunits requires installing pyyaml
- seems that it requires addon existing in nonaddons directory, from where it is moved to addons directory. I guess it is to separate irrelevant addons
- it does not accept the preprocessing trickery of core_override_start and core_override_end https://github.com/ProditorMagnus/Agele ... de_end.cfg - Cant replicate issue anymore
- wmlunits must first be called with --list to generate yaml file, and then with --batch to execute that file
- using -A does not skip translations of era mainline era_default. I guess -A must be used with --list
- looks like -T is used for list part only, otherwise batch should have timed out for me, spending over 10 min at Ageless with -T 99. I wonder if I should exclude union era from wmlunits

And I succeeded in running wmlunits

Code: Select all

ravana@ravana-think ~/wesnoth/wesnoth-lobby/data/tools $ ./wmlunits -w ~/wesnoth/wesnoth-lobby/wesnoth -a ~/wesnoth/userdata_1_14/data/addons -o ~/tmp/units -D ~/wesnoth/wesnoth-lobby --batch batch.yaml -T 99 -A -l en_US
Too late to start looking into release issue today.
User avatar
BTIsaac
Posts: 428
Joined: December 7th, 2017, 7:30 am

Re: Wesnoth's Unit Database

Post by BTIsaac »

James_The_Invisible wrote: February 18th, 2019, 8:33 pm I just noticed that 1.14 version does not show units for almost all user-made campaigns and eras, actually even mainline eras are not listed. One can see only all mainline campaigns + 1 user-made one and 3 user-made eras. Build report does not show any error for most add-ons.
1.12 version looks unaffected.
So i might have missed it but is this going to be adressed?
User avatar
Pentarctagon
Project Manager
Posts: 5496
Joined: March 22nd, 2009, 10:50 pm
Location: Earth (occasionally)

Re: Wesnoth's Unit Database

Post by Pentarctagon »

BTIsaac wrote: February 21st, 2019, 6:03 pm
James_The_Invisible wrote: February 18th, 2019, 8:33 pm I just noticed that 1.14 version does not show units for almost all user-made campaigns and eras, actually even mainline eras are not listed. One can see only all mainline campaigns + 1 user-made one and 3 user-made eras. Build report does not show any error for most add-ons.
1.12 version looks unaffected.
So i might have missed it but is this going to be adressed?
I assume this fix is related.
99 little bugs in the code, 99 little bugs
take one down, patch it around
-2,147,483,648 little bugs in the code
User avatar
BTIsaac
Posts: 428
Joined: December 7th, 2017, 7:30 am

Re: Wesnoth's Unit Database

Post by BTIsaac »

hm. now it appears to be back to normal.
User avatar
James_The_Invisible
Posts: 533
Joined: October 28th, 2012, 1:58 pm
Location: Somewhere in the Northlands, fighting dark forces
Contact:

Re: Wesnoth's Unit Database

Post by James_The_Invisible »

The bug is back. Is anyone testing things in production?
User avatar
TyBonzer
Translator
Posts: 13
Joined: February 8th, 2019, 12:26 pm
Location: Netherlands
Contact:

Re: Wesnoth's Unit Database

Post by TyBonzer »

I'm currently busy with translating all the files to Dutch (after 10 years of no-one doing that) and 14-03-2019 the unit nl.po file was updated to 100% done. The unit tree updated last saturday 16-03-2019 but not all the names and/or races are updated according the new dutch translation. What can I do about this? Thanks in advance!
Soliton
Site Administrator
Posts: 1678
Joined: April 5th, 2005, 3:25 pm
Location: #wesnoth-mp

Re: Wesnoth's Unit Database

Post by Soliton »

Just wait for the next update. Your translation was committed a bit after the last update of the unit db.
"If gameplay requires it, they can be made to live on Venus." -- scott
Post Reply