I can’t set up FQL scripts that another person can simply copy and paste in Shell to run in a single go. The reason is that there are delays involved in certain operations and the subsequent command often fails with “Document data not valid” type error or “Reference not found.”
An example can be creating roles and then creating a key for that role. The create key fails.
I have seen similar problems for indexes being made after creating a collection, and more.
This means, I have to carefully divide the script into several parts which need to be run separately and that makes it impossible to make a simple “setup” type procedure to be followed.
I have not seen these problems with GraphQL schema import yet. It works flawlessly, even creating dummy functions when they don’t exist, etc.
Suggestion: The shell should be improved to wait and retry a few times when errors like document data not valid or reference error are encountered. This will help make extensive setup scripts that can be run in one go.