Consistently get the AnalysisProject from $self.