-
Notifications
You must be signed in to change notification settings - Fork 270
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Do not retrieve tags for virtual studies #2548
Do not retrieve tags for virtual studies #2548
Conversation
}; | ||
|
||
@observer | ||
default class BuildOverlay extends React.Component<BuildOverlayTooltipProps, {}> { | ||
@observable readonly studyMetadata = remoteData({ | ||
invoke: async () => { | ||
if (this.props.isVirtualStudy) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
you should just deal with this condition down in the render method instead of muddying the promise with it.
@@ -43,12 +44,16 @@ export type StudyTagsTooltipProps = { | |||
export type BuildOverlayTooltipProps = { | |||
studyDescription: string; | |||
studyId: string; | |||
isVirtualStudy: boolean; | |||
}; | |||
|
|||
@observer | |||
default class BuildOverlay extends React.Component<BuildOverlayTooltipProps, {}> { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
While we're at it, might as well change this to StudyInfoOverlay
53a1d1e
to
91540c7
Compare
What? Why?
Fix for cBioPortal/cbioportal#6285. There is a bug when using virtual studies and hovering the info icon in the query page: the endpoint
/studies/{studyId}/tags
returns an error after attempting to retrieve the tags given the virtual study ID (instead of an expected non-virtual study ID). Since virtual studies can be made of multiple studies, I think the best way to deal with the error is not to retrieve tags for virtual studies. Feel free to comment if you think there is a better solution to deal with the issue.