After trying a few more variations of my setup, the issues seems to be a script that I run on exit from the current layout to clean up some status variables. If I don't do that, it works fine. This seems related to the discussion in this article:
where it says "Another instance where it may appear that the script step Go to Related Record is not working is if it is not the last step in a script. Actually, it is working. Go to Related Record opens the related database and goes to the relatedrecord but returns to the original file to finish executing the rest of the script. This can be particularly confusing when the script step it is returning to execute is simply End if." In my case, I guess, it's returning to execute the OnLayoutExit script and then returning to wherever it wants in the new layout, forgetting the previous Go to. It doesn't seem to me that it should work this way — the latter script should execute on the way out, not after coming back.
In any case, the solution described in this article doesn't work for me. And I can't just relocate the onLayoutExit script because I need to clean up these variables in a general way, since I don't know how users will move around within the database. So I've come up with this solution to replace the simple Go to Related Record [From table: "Strains"; Using layout: "Strains" (Strains)]:
Set Variable [$$StrainID; Value:Strains::StrainID] # Correctly set from related record
Go to Layout ["Strains" (Strains)]
Perform Find [Restore] # Criteria: Strains::StrainID:[$$StrainID]
Show All Records
Oh, Andy, no ... I suggest that you figure out the inconsistency instead of dropping GTRR from your toolkit and performing a search instead.
When I use triggers to set/clear variables based upon Layout enter or exit, I include a test for in script. I cannot say for sure unless I can see your file but when starting a script such as this, I set a variable to 1 and clear it when script finishes. Script triggers based upon layouts can then include test for the 1 to determine whether to run or not.
Here's a link to a post that attempts to document all the details, limitations, quirks to the Go To Related Records step:
If you haven't already read it, it may help you better understand the expected results for each combination of possible options you can select with this script step.