Add-on invalid text markup?

The place to post your WML questions and answers.

Moderators: Forum Moderators, Developers

Forum rules
  • Please use [code] BBCode tags in your posts for embedding WML snippets.
  • To keep your code readable so that others can easily help you, make sure to indent it following our conventions.

Add-on invalid text markup?

Postby fmac81 » September 21st, 2017, 9:48 pm

Hello all,
Its been a while since I've posted here. I am trying to upload an era, but the add-on server of both 1.12 and 1.13 reject it for "invalid text markup". I looked in the debug logs and traced it back to Pango (I'm running OS X). I reinstalled Pango and undated XCode, then tried relaunching... to no avail. Apologies in advance for the lengthy post - but its been driving me nuts the past couple days.

First thing: I was curious if there were any changes to .pbl file coding as of late? I had just been following along the wiki page as a refresher but I'm convinced my error is someplace in it. I posted my pbl file setup below (with some omissions).
Spoiler:

The era itself works fine when I load it into multiplayer. I had thought it might have been some of the coding I did for a changelog right-click menu, which did include some pango font formatting, so I removed that in its entirety, but the add-on server still returns an error. Any ideas as to what I'm missing here? I put screenshots under a spoiler of the error screen I get when uploading.
Spoiler:


I scoured the era files without success for what could possibly be the "<span color='#00ff00' ?? Era of Second Chances </span>" that the log is referring to... The issue I keep running into is I never even used pango markup in the _server.pbl file... The rationale it provides is I have an invalid directory that has one or more of
Code: Select all
/\~:
. However, it appears that none of my directories contain those (at most I put in a - for subdivided folders, like human-outlaws, but nothing more)... :?

I can post the _main.cfg file later if that would be more helpful, but like I said, the era itself checks out fine on my end before being uploaded so I am assuming the error is someplace in the pbl file.

Any help would be appreciated!

Thanks,
fmac81
User avatar
fmac81
 
Posts: 66
Joined: February 24th, 2011, 9:55 pm

Re: Add-on invalid text markup?

Postby fmac81 » September 21st, 2017, 10:06 pm

Nevermind problem was solved. Some random special characters had appeared between the quotes for the era name, but weren't visible in the code editor I was using. Woops! :oops:
User avatar
fmac81
 
Posts: 66
Joined: February 24th, 2011, 9:55 pm

Re: Add-on invalid text markup?

Postby Pentarctagon » September 21st, 2017, 10:11 pm

Not related to this, but you're using an icon that isn't part of mainline Wesnoth. This will result in everyone who doesn't have the Era of Second Chances add-on installed seeing no icon at all, and is why rule #5 for the add-ons server states that add-ons need to use icons that come with mainline Wesnoth.
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
Pentarctagon
Forum Administrator
 
Posts: 2921
Joined: March 22nd, 2009, 10:50 pm
Location: Earth (occasionally)

Re: Add-on invalid text markup?

Postby fmac81 » September 21st, 2017, 10:16 pm

Pentarctagon wrote:Not related to this, but you're using an icon that isn't part of mainline Wesnoth. This will result in everyone who doesn't have the Era of Second Chances add-on installed seeing no icon at all, and is why rule #5 for the add-ons server states that add-ons need to use icons that come with mainline Wesnoth.

Oh wow. I totally forgot about that since its been so long since I've uploaded something to the add-on server (probably 3 years or so). Good catch on your part. Will definitely fix that before uploading.

Cheers!
User avatar
fmac81
 
Posts: 66
Joined: February 24th, 2011, 9:55 pm

Re: Add-on invalid text markup?

Postby fmac81 » September 22nd, 2017, 4:46 pm

So... I thought I had fixed my problem... but I am getting the same error even after removing the special characters from the pbl file (and changing the icon of the era too, of course). I tried different text editors (TextWrangler, Emacs, XCode, even went back to TextEdit once), but can't seem to pass by the UTF-8 error, even after setting the text encoding to be UTF-8 :augh:. I normally use Unitron (the code-editor part of the Unity game editing engine), which has worked fine in the past and functions normally with making changes to cfg files.

Any ideas of what else I can do to fix this? I'm lost here :cry:

Thanks,
fmac81
User avatar
fmac81
 
Posts: 66
Joined: February 24th, 2011, 9:55 pm

Re: Add-on invalid text markup?

Postby Pentarctagon » September 22nd, 2017, 5:07 pm

Do you have a hex editor you could use? That would show exactly what is in your pbl file.
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
Pentarctagon
Forum Administrator
 
Posts: 2921
Joined: March 22nd, 2009, 10:50 pm
Location: Earth (occasionally)

Re: Add-on invalid text markup?

Postby fmac81 » September 22nd, 2017, 5:11 pm

Pentarctagon wrote:Do you have a hex editor you could use? That would show exactly what is in your pbl file.

I'm not quite sure what you mean by hex editor... I've always just used a regular text editing program. Is this something that OS X might have or would I have to look around for a cross-platform one to download?

Thanks for the response.

EDIT: After a little Google searching, I found a "hexl mode" in Emacs, which showed the hex encoding of the pbl file... but I have very limited idea of what to look for that might be causing the error. Nothing seemed out of the ordinary from first glance. I can post what it showed and maybe someone will be able to identify it?
User avatar
fmac81
 
Posts: 66
Joined: February 24th, 2011, 9:55 pm

Re: Add-on invalid text markup?

Postby Pentarctagon » September 23rd, 2017, 4:50 am

Sure, that would work - you can also PM me your pbl file if you want, and I can take a look at it myself. Looking at it through a hex editor is useful when trying to find characters that might otherwise not be rendered in a normal editor, whether it's because they're control characters, a Byte Order Mark(BOM), etc.

Also, moved to the WML Workshop, since this seems to be some sort of encoding issue rather than a Wesnoth bug.

edit: This has been solved via PM. The issue was a few images had spaces in their file names.
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
Pentarctagon
Forum Administrator
 
Posts: 2921
Joined: March 22nd, 2009, 10:50 pm
Location: Earth (occasionally)


Return to WML Workshop

Who is online

Users browsing this forum: Baidu [Spider] and 2 guests