Feature - Implemented Add version / build# to Main Interface titlebar

Please, could we have the [version or build] number in KoLmafia's Main Interface titlebar? It's a tiny little thing, but it would be so nice to have it there.
Thank you.
 

fronobulax

Developer
Staff member
Just out of curiosity, why is that so important? The version number is in the Copyright page so it is only one click away. Revision number would be something new but would probably require that everyone build mafia the same way using the same tools.
 

Spiny

Member
You could also type the word version into the CLI :) Or in my case, take a peek at the shell session I launched mafia with to see what my last command was :)
 

fronobulax

Developer
Staff member
You could also type the word version into the CLI :) Or in my case, take a peek at the shell session I launched mafia with to see what my last command was :)

The version cli command gives the same answer as the copyright page. Your "last command" suggestion does require that your shell remembers what you did and that you run builds with the revision number in the file name ;-)
 
Just out of curiosity, why is that so important? The version number is in the Copyright page so it is only one click away. Revision number would be something new but would probably require that everyone build mafia the same way using the same tools.
"So important"? Well... I don't know how important you think that I think it is.... lol. It was important enough to me to suggest it. It has been important enough to be in the KoLmafia loging window's titlebar for a very long time now. It has been important enough to have version in the titlebar of programs for decades, now. Well, some programs.

Since the version number of KoLmafia changes relatively quite frequently, and because the reasons it changes are sometimes related to KoL changes that make large parts of KoLmafia stop working, and since the version number can be very important (critical) when someone asks for help with it, and because I'm hoping it would be trivial to have the program display information in the titlebar that is already shown elsewhere within the program (and I have NO idea what I'm really asking for, just hoping), and finally because (believe it or not) I do feel like that pair of clicks (not just one, mind you) is annoying to do when I want something that was already sitting right there in front of me, in the titlebar of the login window (if only I had paid attention) -- well, these are the reasons I suggest it as a feature.

I feel that the version number is important enough in KoLmafia that it's almost like part of the name -- to me, that is. I guess I might ask, "How unimportant or harmful must it be, in order for putting it in the Main Interface titlebar to be a bad idea?" Or to put it another way, if it's not hard to do, what could it possibly hurt?

I just hope it's not hard to do. :D
 

fronobulax

Developer
Staff member
Just to be clear. Let's call the version number something of the form dd.d and the current version is 14.1. Let's call the revision number the four (soon to be five) digit identifier returned by Subversion when code is updated. This number is used to identify daily builds.

You say something changes "frequently". That is not the version number, in my opinion, because releases which change the version number tend to be monthly. In a world where the first response to many bug reports is to tell the poster to DL a daily build and then reproduce the problem, the version number really is not all that helpful. Furthermore unless you share a computer with someone else who also uses mafia and might update it, the version number is unlikely to change without you knowing. Furthermore it is available on the login screen, in the Help and in the gCLI. As for version numbers in titlebar Firefox doesn't, Thunderbird doesn't, and IE doesn't, to name three that are open right now.

All this said - my inner snark is now at rest - does your request reduce to adding the version number to the main window title bar so that where it now says "Main Interface (fronobulax)" it says something like "v14.1 Main Interface (fronobulax)"?

That can be investigated.

If the request deals with the revision number, that is somewhat more difficult.

Update: r8650. I spent more time being snarky about it than it took me to make the change. I'm not in the developers group here so someone else will have to change the status to implemented.
 
Last edited:

Bale

Minion
r8650 was implemented, but it does not work as suggested.

Adding 14.1 to the titlebar when I'm using r8560 is a bad thing. It is misleading. I'm definitely not using v14.1 and this implication that I am running that version is confusing to me. I suspect it will also get confusing to people who are asked to upgrade to the latest build. We can tell them to upgrade to r8560, but they might not understand that it worked when they see it is v14.1.

Either report the revision number properly, or revert this. Please.
 

fronobulax

Developer
Staff member
I'll certainly wait for other opinions but it is easy to revert if it really was a mistake. First I think we need to make a distinction between the version number (14.1) - which changes about monthly and is only changed when Veracity or Jason spins a release and posts it to SourceForge - and a revision number which is is assigned by Subversion when code is extracted from the repository and used to build mafia. The professional way to label a mafia jar file would be something like "v14.1 r8560".

The request was for the version number and I implemented it because the information is already reported in three other user visible places in mafia - the main screen before login, the gCLI command and the Copyright page. All I did was make it more visible by adding it to one more place, a title bar. I do not believe that is any more misleading than the three places it was previously reported. More visible, perhaps, but not misleading. I can even make a case for it by observing that, with the version number visible, the smart user will be able to report the version number in the initial report rather than having to go back and look at another page.

The real problem here is that "release" and "version" are terms that should only apply to jar files downloaded from Sourceforge and "build" and "revision" are terms that should only be applied to Daily Builds or other code built directly from source by knowledgeable users. Of course, no one is going to observe that distinction in practice and it really only matters if someone is trying to run or debug a Daily Build.

The real solution would be to have mafia report a version and a revision number. The latter would have to be generated using information from Subversion whenever the code is built and regardless of who builds it and how. My Subversion skills, Java skills and available time are not up to that, although if the partial solution immediately generates a call to revert it from someone I respect, it may be time to re-investigate the feasibility of the correct solution.

Does this mean you would like me to edit the quote in my sig? ;)
 

heeheehee

Developer
Staff member
Methinks line 98 should be

PHP:
super(StaticEntity.getVersion()+" Main Interface" );

(Man, I really suck at Java! Most of this was just stolen from VersionCommand.java.)

Edit: I don't get what's up with " "+"Main Interface", as opposed to just " Main Interface". Yeah.
 
Last edited:

lostcalpolydude

Developer
Staff member
Actually, the change to the title bar provides the only place where mafia tells me 14.1. All the other places you mention list r8560. And I wouldn't be surprised if all of those other places use what heeheehee posted.
 

Spiny

Member
I understand what Fronabulax was trying to say and after grabbing a copy of r8560 I was expecting to see what he was talking about, that the title bar of the main mafia window would show v14.1, r8560. Such is not the case.

The login screen's title bar displayed r8560. The title bar on the Main interface displays v14.1 This is indeed confusing. It should display both the version and the revision numbers if the version number is being displayed at all. Both the cli command version and the copyright data reflect r8560. I don't think there would be a problem if both version and revision numbers are displayed, so long as when the revision occurs that equates to a version update, both are incremented accordingly.

I'm also hazarding a guess that StorellaDeville's request to see the version number was to accommodate for both potential pieces of data. I think in another post she had said that she hadn't updated in a while and had experienced some problem for a long time and didn't realize the version number was relevant. As it turns out a daily build revision had already taken care of fixing said problem. If I'm remembering a situation with someone else entirely, my sincere apologies.

Showing both version and revision number would also alleviate my own confusion of what version a build is in. This is really only relevant to me when a new version is released and people are posting bug reports and issues in the KoL forums. It alleviates my need from having to look up the daily build revisions to see which specific build equated to a version update.
 

heeheehee

Developer
Staff member
The only problem that I can see is that there's no way to get the revision number if you're using one of the official builds. Would a better solution be:
PHP:
private string version = StaticEntity.getRevision()=0?"":", r" + StaticEntity.getRevision();
super("KoLmafia "+KoLConstants.VERSION_NAME+version+" Main Interface" );
?
 
Last edited:
The only problem that I can see is that there's no way to get the revision number if you're using one of the official builds. Would a better solution be:
PHP:
private string version = StaticEntity.getRevision()=0?"":", r" + StaticEntity.getRevision();
super("KoLmafia "+KoLConstants.VERSION_NAME+version+" Main Interface" );
?
Oh, no. From your wording.... Are you calling a KoLmafia file that has a "version" number associated with it an "official build"? I think that makes sense to me. But unfortunately it adds to my confusion, too. Is a version always a build? Or is it better to say a version always HAS a build number? Does a build always have a version associated with it? Is a revision always a build, or is it a version, or both a version and a build?

If all of these words (revision, version and build) are used to mean the same thing -- even just sometimes -- for KoLmafia, then why are they used separately, as if they don't mean the same thing? I ask because I'd like to stop being confused; it bothers me a lot. And I want to be able to understand what people say when they talk about KoLmafia. If they speak of a build, does that mean it's never a "version"? Or sometimes is a version, or might be, but not always? Does every version have a build? When I type "version" into the GCLI of "version" 14.1, it responds with only this:
KoLmafia v14.1
Does this mean this version has no build number? If it has no build number, then how can it be a build? Or on the other hand, if it is a "build," then why doesn't it have a build number?
I have always suspected the "r" at the start of a KoLmafia build number stood for either "revision" or maybe even "release." I have wondered, "If it is a 'build,' then why doesn't it start with a B???" When I supported QuickBooks (sorry, I'm limited to my own experience or things I understand from the experience of others), the "release number" was critical and always started with an R (although R is not a number...). However, a perfectly valid name for these releases was "patches." But the version would be reported as "2000 R8," for instance. So is every KoLmafia build also a revision?

If my words seem rambling, or the whole thing (this post) seems complex, then you (the reader) have some idea of what I'm going through. And before anyone can accuse me of "making this harder than it really is," let me say I found things this way; I did not make them this way. I am only trying to understand what I have found.

Maybe I'll understand all this if I just have answers to 3 questions:
When is something related to KoLmafia called a "version"?
When is something related to KoLmafia called a "build"?
When is something related to KoLmafia called a "revision"?


EDIT: Please understand that I am asking these things because I am confused. I love KoLmafia and think that everyone who contributes to its ongoing greatness is wonderful! I am not saying there is anything wrong or bad with it, or that there is something wrong with anyone. So please know that I am asking for help, not complaining or accusing. I like to help people! But right now I'm just asking for some help to understand. Thank you.
 
Last edited:

Bale

Minion
Maybe I'll understand all this if I just have answers to 3 questions:
When is something related to KoLmafia called a "version"?
When is something related to KoLmafia called a "build"?
When is something related to KoLmafia called a "revision"?

revision: This refers to a specific point in the development of KoLmafia. The latest revisions are listed here and the most recent was r8560

build: Refers to the process of assembling an executable program from a revision. It is sometimes used interchangeably with revision as in the sentence, "The latest build was r8560." Perhaps it should not be used that way.

version: This refers to the official releases by Veracity. It is an official version because of Veracity's decision. The most recent was version 14.1

Version 14.1 was revision 8497. They are the same. It was called a version because Veracity made it official.
 
Last edited:

Veracity

Developer
Staff member
Revision 8561 does this:

Title bar for a released version: KoLmafia v14.1
Title bar for a daily or debug build: KoLmafia v14.1 r8560

Two new ash functions:
string get_version() -> KoLmafia v14.1
int get_revision() -> 8460

Note that get_revision for an official release returns the actual last revision that went into the release, even though we don't display it in the title bar.
 

Veracity

Developer
Staff member
Works for me.

How did you build that?

ant jar -> make a "released" version named KoLmafia.jar
ant debug -> make an unreleased version named KoLmafia.jar
ant daily -> make an unreleased version with name KoLmafia-xxx.jar

The default if you simply type "ant" is "ant debug".
 

Bale

Minion
How did you build that?

ant jar -> make a "released" version named KoLmafia.jar
ant debug -> make an unreleased version named KoLmafia.jar
ant daily -> make an unreleased version with name KoLmafia-xxx.jar

The default if you simply type "ant" is "ant debug".

I built it with ant daily. What should I use?
(I confirm that the release at http://builds.kolmafia.us/ worked perfectly.)

I appreciate you guys so much.
Where "guys" means "people."

This "people" is happy to have helped.
 
Top