Decreasing campaign-maintenance overhead with new tools
Moderator: Forum Moderators
- esr
- Retired Developer
- Posts: 228
- Joined: November 26th, 2006, 6:40 pm
- Location: Pennsylvania, USA
- Contact:
Decreasing campaign-maintenance overhead with new tools
The just-released 1.3.2 contains two new tools, macroscope and upconvert, aimed at making it easier to sanity-check and maintain WML.
As a player, I want us to carry a lot more more stuff in mainline. As a developer, I know this is not realistic if it means devs and designers would have to sink hugely many more hours into campaign-maintenance work.
Therefore, I've set myself the goal of drastically decreasing the overhead of maintainer-hours required per campaign per year. The purpose of macroscope, broadly speaking, is to automate as much sanity checking as possible. The purpose of upconvert, broadly speaking, is to automate the fiddly bits of forward-porting campaigns as WML and the resource files in Wesnoth mainline change.
If any of you have ideas for more tools that would decrease maintainers' burdens, I'd like to hear those ideas.
What else would make the job easier? What other time-intensive tasks might be mechanized? Please speculate and brainstorm.
As a player, I want us to carry a lot more more stuff in mainline. As a developer, I know this is not realistic if it means devs and designers would have to sink hugely many more hours into campaign-maintenance work.
Therefore, I've set myself the goal of drastically decreasing the overhead of maintainer-hours required per campaign per year. The purpose of macroscope, broadly speaking, is to automate as much sanity checking as possible. The purpose of upconvert, broadly speaking, is to automate the fiddly bits of forward-porting campaigns as WML and the resource files in Wesnoth mainline change.
If any of you have ideas for more tools that would decrease maintainers' burdens, I'd like to hear those ideas.
What else would make the job easier? What other time-intensive tasks might be mechanized? Please speculate and brainstorm.
- vonHalenbach
- Translator
- Posts: 398
- Joined: May 3rd, 2006, 10:23 am
- Location: united europe
I can just think of a device, that is attached to the campaign maintainers computer, which gives light electric shocks to them if they upload broken stuff on the campaign server. It should be called unlazydevice, or something. 

http://brilliantanyway.blogspot.com/ Brilliant Anyway
This assumes that there is a universally accepted system of indentation for WML... there's not, from what I can tell.zookeeper wrote:A tool to convert all WML to be properly indented and formatted.
And I personally would find it rather frustrating to have to write WML in an indentation format that I'm not used to.

For I am Turin Turambar - Master of Doom, by doom mastered. On permanent Wesbreak. Will not respond to private messages. Sorry!
And I hate stupid people.
The World of Orbivm
And I hate stupid people.
The World of Orbivm
- Viliam
- Translator
- Posts: 1341
- Joined: January 30th, 2004, 11:07 am
- Location: Bratislava, Slovakia
- Contact:
I do not know if any of the existing tools does it, but IMHO it would be good to have:
1) WML syntax check, also for included files and expanding macros. Also check whether links to images are correct.
2) check whether all tags and attributes are from a specified set (specified in a configuration file; it will be different for different versions). Something like a DTD check for XML files. In addition to errors, it could also give warnings about atrributes that should/shoudn't be localized (for example unit id must not be localized; unit name should be localized).
The tools should give a human-readable output, which can be sent by e-mail to campaign maintainer.
1) WML syntax check, also for included files and expanding macros. Also check whether links to images are correct.
2) check whether all tags and attributes are from a specified set (specified in a configuration file; it will be different for different versions). Something like a DTD check for XML files. In addition to errors, it could also give warnings about atrributes that should/shoudn't be localized (for example unit id must not be localized; unit name should be localized).
The tools should give a human-readable output, which can be sent by e-mail to campaign maintainer.
- esr
- Retired Developer
- Posts: 228
- Joined: November 26th, 2006, 6:40 pm
- Location: Pennsylvania, USA
- Contact:
Thanks, Villam, this exactly the sort of thing I was looking for.
Macroscope already does much of what you're asking for, and could
be made to do more.
Macroscope already does much of what you're asking for, and could
be made to do more.
- * WML syntax check -- no, that would require a full WML parser
* included files -- no, though I'm thinking hard about it
* expanding macros -- yes, checks for bad references or unused macros
* check whether links to images are correct -- yes
* check whether all tags and attributes are from a specified set -- yes
* DTD check for XML files -- no, what XML files do we have?
* warnings about attributes that should/shouldn't be localized -- no.
* human-readable output -- yes
- esr
- Retired Developer
- Posts: 228
- Joined: November 26th, 2006, 6:40 pm
- Location: Pennsylvania, USA
- Contact:
Formatter and syntax checker are the same problem
Writing a WML formatter and writing a WML syntax checker are essentially the same problem, and fairly difficult to get right. I might do it, but I'd rather identify and do all the easier useful things first.
Both problems would require an XML parser in Python. Rather than write one from scratch, I might at some point swipe campgen's parser or refactor campgen so its parser becomes reusable.
Both problems would require an XML parser in Python. Rather than write one from scratch, I might at some point swipe campgen's parser or refactor campgen so its parser becomes reusable.
Re: Formatter and syntax checker are the same problem
Well, my WML editor can already do both, I just have to find some time to fix some minor problems with WML parsing so rewriting such a tool is probably wasted time.esr wrote:Writing a WML formatter and writing a WML syntax checker are essentially the same problem, and fairly difficult to get right. I might do it, but I'd rather identify and do all the easier useful things first.
Both problems would require an XML parser in Python. Rather than write one from scratch, I might at some point swipe campgen's parser or refactor campgen so its parser becomes reusable.
Just use a decent text editor (I use vim).ju5t1n wrote:A line counter would be really handy as well (I find a use up 15-30 mins or so just counting lines for common typos, like messgae instead of message).
I was working on the proof of one of my poems all the morning, and took out a comma. In the afternoon I put it back again. -- Oscar Wilde
- Temuchin Khan
- Posts: 1845
- Joined: September 3rd, 2004, 6:35 pm
- Location: Player 6 on the original Agaia map
I do not doubt the usefulness of this tool, but I've noticed that sometimes when I play a multiplayer game a list of five or six instances of "Deprecated WML found" partially obscures portions of the map. Is there any way to make these notices go away, short of revising the maps, once they have been noted? In other words, do you have to stop the game and make the required corrections every time one of these notices appears, or can you leave them for later?
Check out my book!
https://www.amazon.com/dp/1956715029/re ... oks&sr=1-1
https://www.amazon.com/dp/1956715029/re ... oks&sr=1-1
- Eleazar
- Retired Terrain Art Director
- Posts: 2481
- Joined: July 16th, 2004, 1:47 am
- Location: US Midwest
- Contact:
I don't believe that's the result of macroscope.Temuchin Khan wrote:I do not doubt the usefulness of this tool, but I've noticed that sometimes when I play a multiplayer game a list of five or six instances of "Deprecated WML found" partially obscures portions of the map. Is there any way to make these notices go away, short of revising the maps, once they have been noted? In other words, do you have to stop the game and make the required corrections every time one of these notices appears, or can you leave them for later?
":clear" will bring you temporary relief.
Feel free to PM me if you start a new terrain oriented thread. It's easy for me to miss them among all the other art threads.
-> What i might be working on
Attempting Lucidity
-> What i might be working on
Attempting Lucidity