Bug - Fixed McClusky File not being correctly auto-created

When automating during ronin at the hidden office building in the hidden city, KoLMafia v19.7 is not correctly creating the McClusky file after finding all 5 pages and the binder clip. I'm not sure why.
From the CLI:
Request 15 of 25 (HiddenCity: The Hidden Office Building) in progress...

[838] The Hidden Office Building
Encounter: Working Holiday
Encounter: pygmy witch accountant
Round 0: ClubbingKelp wins initiative!
Round 0: ClubbingKelp casts BAKE!
Round 1: pygmy witch accountant takes 35 damage.
Round 1: You lose 31 hit points
Round 1: ClubbingKelp casts CHOP!
Round 2: pygmy witch accountant takes 75 damage.
Round 2: pygmy witch accountant takes 33 damage.
Round 2: ClubbingKelp wins the fight!
You gain 148 Meat
You acquire an item: bone abacus
You acquire an item: adder
You acquire an item: McClusky file (page 5)
Verifying ingredients for McClusky file (complete) (1)...
Creating McClusky file (complete) (1)...
You are currently in a choice.
After Battle: You gain 16 Beefiness
You gain a Muscle point!
After Battle: You gain 22 Enchantedness
After Battle: You gain 9 Sarcasm

Mafia stopped automation and told me "You are currently in a choice", even though I wasn't. Examining my inventory reveals the unassembled file. What's going on here? I'm currently on an Avatar of Jarlsberg path, but I remember this happening on other paths before.
 

Magus_Prime

Well-known member
It auto-created properly for me, yesterday, with 19.7 r19551 in a Kingdom of Exploathing run. I won't be in a position to test it again for another day or two.
 
Last edited:
I looked through my session log, and it says something different from the CLI:
[838] The Hidden Office Building
Encounter: Working Holiday
Took choice 786/3: Fight pygmy witch accountant
choice.php?whichchoice=786&option=3&pwd
Encounter: pygmy witch accountant
Round 0: ClubbingKelp wins initiative!
Round 0: ClubbingKelp casts BAKE!
Round 1: pygmy witch accountant takes 35 damage.
Round 1: You lose 31 hit points
Round 1: ClubbingKelp casts CHOP!
Round 2: pygmy witch accountant takes 75 damage.
Round 2: pygmy witch accountant takes 33 damage.
Round 2: ClubbingKelp wins the fight!
You gain 148 Meat
You acquire an item: bone abacus
You acquire an item: adder
You acquire an item: McClusky file (page 5)
After Battle: You gain 16 Beefiness
You gain a Muscle point!
After Battle: You gain 22 Enchantedness
After Battle: You gain 9 Sarcasm
So I'm wondering if gaining the last page of the McClusky file from a combat entered through the Working Holiday choice adventure causes it to not be created correctly.
 

Veracity

Developer
Staff member
Which version of KoLmafia are you using? You say 19.7, but which revision? Are you using a daily build?

There are 3 paths to getting all the ingredients:

1) Get all 5 accountants (apartment building, office building) before you take the choice and get the binder clip. My session log from 2019/09/01:

Code:
[525] The Hidden Office Building
Encounter: Working Holiday
Took choice 786/2: Get boring binder clip
choice.php?pwd&whichchoice=786&option=2
You acquire an item: boring binder clip

Use 1 boring binder clip + 1 McClusky file (page 1) + 1 McClusky file (page 2) + 1 McClusky file (page 3) + 1 McClusky file (page 4) + 1 McClusky file (page 5)
You acquire an item: McClusky file (complete)

2) You get the boring binder clip and then fight the 5th accountant. My session log from 2019/09/09:

Code:
[535] The Hidden Office Building
Encounter: Working Holiday
Took choice 786/2: Get boring binder clip
choice.php?pwd&whichchoice=786&option=2
You acquire an item: boring binder clip

[536] The Hidden Office Building
Encounter: pygmy witch accountant
Round 0: Veracity wins initiative!
...
Round 3: Veracity wins the fight!
...
You acquire an item: McClusky file (page 5)

Use 1 boring binder clip + 1 McClusky file (page 1) + 1 McClusky file (page 2) + 1 McClusky file (page 3) + 1 McClusky file (page 4) + 1 McClusky file (page 5)
You acquire an item: McClusky file (complete)
After Battle: You gain 22 Strongness
After Battle: You gain 16 Magicalness
After Battle: You gain 35 Cheek
3) You take the choice and get the 5th accountant. My session log from 2019/07/01:

Code:
[709] The Hidden Office Building
Encounter: Working Holiday
Took choice 786/3: Fight pygmy witch accountant
choice.php?pwd&whichchoice=786&option=3
Encounter: pygmy witch accountant
Round 0: Veracity wins initiative!
...
Round 5: Veracity wins the fight!
...
You acquire an item: McClusky file (page 5)

Use 1 boring binder clip + 1 McClusky file (page 1) + 1 McClusky file (page 2) + 1 McClusky file (page 3) + 1 McClusky file (page 4) + 1 McClusky file (page 5)
You acquire an item: McClusky file (complete)
After Battle: You gain 15 Muscleboundness
After Battle: You gain 13 Mysteriousness
After Battle: You gain 28 Smarm
So, at one point, all three paths worked correctly.
However, in the last week or so, I have been changing a lot of stuff in choice processing, and I started seeing inappropriate "you are in a choice" messages - even from places where it shouldn't have cared, as opposed to this case, where it is actually creating an item and does care.

Yesterday, I submitted revision 19554 which tries to make sure that when a choice redirects to a fight (like this one), it immediately clears the "I am in a choice" flag.

Which is to say, I probably broke this, but I also probably fixed it.
 

Veracity

Developer
Staff member
I suppose a way to test:

1) Fight 4 accountants in the apartment building and office building.
2) Run away from any others until you get the binder clip
3) Run away from any others until you take the Working Holiday choice again, and fight an accountant.
4) See if creates the McClusky File (complete), as expected.

That would slow down a run by up to 5 turns (an extra cycle in the office building).
I say "up to" because bad luck could have forced you into the extra cycle anyway, due to lack of accountants, as it did for me on 2019/07/01...
 
Which version of KoLmafia are you using? You say 19.7, but which revision? Are you using a daily build?
Sorry, I knew I should have specified which revision, but I couldn't seem to find the option in the menu which told me what revision I was on. >_>

There are 3 paths to getting all the ingredients:

1) Get all 5 accountants (apartment building, office building) before you take the choice and get the binder clip. My session log from 2019/09/01:

2) You get the boring binder clip and then fight the 5th accountant. My session log from 2019/09/09:

3) You take the choice and get the 5th accountant. My session log from 2019/07/01:

So, at one point, all three paths worked correctly.
Yeah, it's weird how you got that third choice and got the fifth page and it created the file for you, but not for me. ?_?

However, in the last week or so, I have been changing a lot of stuff in choice processing, and I started seeing inappropriate "you are in a choice" messages - even from places where it shouldn't have cared, as opposed to this case, where it is actually creating an item and does care.

Yesterday, I submitted revision 19554 which tries to make sure that when a choice redirects to a fight (like this one), it immediately clears the "I am in a choice" flag.

Which is to say, I probably broke this, but I also probably fixed it.
Well, I'll grab the latest revision then, and hope it doesn't come up again. Thanks!
 
I suppose a way to test:

1) Fight 4 accountants in the apartment building and office building.
2) Run away from any others until you get the binder clip
3) Run away from any others until you take the Working Holiday choice again, and fight an accountant.
4) See if creates the McClusky File (complete), as expected.

That would slow down a run by up to 5 turns (an extra cycle in the office building).
I say "up to" because bad luck could have forced you into the extra cycle anyway, due to lack of accountants, as it did for me on 2019/07/01...
I could try that on my next run, sure. Does Mafia still try to auto-create the file even if I'm manually adventuring?
I'm definitely not a run optimizer, so 5 turns doesn't matter an iota to me. =P
 

Veracity

Developer
Staff member
I always adventure manually in the Relay Browser. All the (working) examples I showed you are aut-creation after adventuring in the Relay Browser.
 

Ryo_Sangnoir

Developer
Staff member
Last run, creating the McClusky File worked, but creating the Talisman o' Namsilat failed: I beat Ron, then Shen later, and got the "You are currently in a choice." failure message. After that, I made a meat paste and a "create Talisman o' Namsilat" worked to create it.

That was on the 17th, and some of the changes since then might have fixed it.
 

Veracity

Developer
Staff member
Fascinating.

I've always done Shen first - and gotten his half of the Talisman as the result of a choice - and then Ron - and gotten his half after the fight. You just did that in the opposite order.

Looking at the code, I can't see how that would have ever worked. The autoCreate happens in result processing - when we notice that we have picked up the talisman piece - but we are still definitely handling the choice during result processing.

Which is to say, this is not a new bug.

I'll look in to creating the Talisman in postChoice2.
 

Veracity

Developer
Staff member
Revision 19572 should fix that.

I tested by making the Pirate Cove choices that give you an outfit piece autoCreate an enchanted eyepatch as part of the choice handling - the same mechanism needed for the Talisman.

Code:
[5958] The Obligatory Pirate's Cove
Encounter: The Arrrbitrator
Took choice 22/1: eyepatch
choice.php?pwd&whichchoice=22&option=1
You acquire an item: eyepatch

pull: 1 meat paste

Combine 1 eyepatch + 1 lihc eye
You acquire an item: enchanted eyepatch
Crafting used 1 each of lihc eye and eyepatch
I am amused to see that I had meat paste in storage.
 

Veracity

Developer
Staff member
It could. You are the original poster. I was waiting for you to confirm it works for you.
Did it work for you? :)
 
It could. You are the original poster. I was waiting for you to confirm it works for you.
Did it work for you? :)

Ah, sorry, I didn't realize that that was necessary. I haven't yet gotten back to the hidden office building since posting this (it was a long run, okay??), but when I do, I'll keep an eye on it and see that it works correctly. However, you said that you fixed it, and I'm absolutely certain you know what you're doing, so I'll trust you enough to declare this problem solved. =D
 

Veracity

Developer
Staff member
I suppose a way to test:

1) Fight 4 accountants in the apartment building and office building.
2) Run away from any others until you get the binder clip
3) Run away from any others until you take the Working Holiday choice again, and fight an accountant.
4) See if creates the McClusky File (complete), as expected.

That would slow down a run by up to 5 turns (an extra cycle in the office building).
I say "up to" because bad luck could have forced you into the extra cycle anyway, due to lack of accountants, as it did for me on 2019/07/01...
Bump since I might ascend today so I can farm more glitch swagger, just to get another glitch reward, for no good reason.
 

Veracity

Developer
Staff member
Tested. Got my 4th page by "Fighting a cubicle drone"and it auto-created the McClusky File (complete).
 
Top