I have a few questions and a couple of ideas:
- What type of data source are you using (SQL, Excel, etc)?
- Is your data source published to the Tableau server? is so, are you connecting to that instance for development?
- Are you able to share the specific dimension or the basic logic of the dimension?
- Is your data connected real time or via extract?
- What permissions are you using to publish the data?
- What do permissions look like between the data source and the Tableau server? (If you're using a warehouse and trust between the data source, this could be it.)
I have seen things break when a desktop user with certain permissions to a data set publishes a dashboard and others with different or more restrictive permissions do not have access to a portion of the data. This could also be true for the server, where from your PC you have access, but from the server you do not.
I'm taking a guess that when you publish, the server may be getting hung on the 2 primary ISMEMBEROF statements or there may be something in the first part causing it to glitch and then flatten. I am not an expert on server, so I could be way off base.
If you haven't already, you may try splitting the calcs and seeing how they perform separately. That may help you identify any discrepancies.
Since it looks like you're trying to control what users see from a permissions standpoint, have you tried moving it from row level to source level? Securing User Filters for Web Editing and Data Server | Tableau Software for reference.
Hope this helps and I will continue to scout around for more information.