Skip to content

[1861/1867] Auto-pass immediately after a minor auction is won is rejected by the server. #12033

@roseundy

Description

@roseundy

What's your Game ID?

I don't have one. This has the same root cause as #12023

How to Reproduce the Bug?

In the first SR, auction any minor, then if a player auto-passes immediately afterward the server throws the following error:

The server did not accept this action due to: Illegal action: Auto actions do not match... refreshing.

Which Browser / Platform?

Firefox or Chrome / Ubuntu

In order to see it, a player has to enable auto-pass as the very next action after an minor auction was won. In that case - and I'm really not sure why - the time stamp of the generated Par for the minor has a later time stamp than the auto-pass enable which causes the auto-pass to cancel and generate an error.

I fixed the corresponding bug in System18 by changing the call to the synthesized Par action caused by the auction win to this:

             action = Action::Par.new(entity, corporation: corporation, share_price: share_price)
+            # give the generated Par action the same time stamp as the action that triggered the auction win
+            # this prevents problems with a programmed pass triggering on the Par
+            action.created_at = @game.actions.last.created_at
             process_par(action)

Metadata

Metadata

Assignees

No one assigned

    Labels

    18611867auto actionsProblems/requests relating to auto(programmed) actions

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions