Open bobular opened 3 months ago
I figured out why the section is always collapsed by default: https://github.com/VEuPathDB/web-monorepo/blob/26807b89d8f8a131984a63f67da68a70e83309f2/packages/sites/ortho-site/webapp/wdkCustomization/js/client/store-modules/RecordStoreModule.ts#L19-L29
I don't know why this was done, but I suppose we can remove this entire case.
Brilliant - thanks - yes that will help a lot! @dmfalke
There's nothing left after removing that case
.
Should we track down where the reduce
is called, or just eviscerate this function and make it no op?
There's nothing left after removing that
case
.Should we track down where the
reduce
is called, or just eviscerate this function and make it no op?
I think we can just remove the reduce
function.
Not sure why I didn't see this comment sooner... sorry for the delay!
I
There's nothing left after removing that
case
. Should we track down where thereduce
is called, or just eviscerate this function and make it no op?I think we can just remove the
reduce
function.Not sure why I didn't see this comment sooner... sorry for the delay!
Hi @dmfalke - I can't find where that reduce
is imported. It's not part of an object. I'm at a dead end, sorry.
It's imported here:
I'm pretty sure you can just delete the reduce and don't need to make any other changes.
Ah, thanks, I was missing something fundamental that I get now.
It looks like we can't avoid the "We're sorry, something went wrong." modal being rendered if the wdkService back end call returns a 404. That hook (useWdkService/useOrthoService) doesn't handle errors the same way as the EDA's usePromise
.
However, we can avoid asking for a tree when there are too few sequences, thus avoiding some user-facing errors. Will push a commit soon to address this and make sure the regular table still renders.
const numSequences = mesaRows.length;
const treeResponse = useOrthoService(
numSequences > 2
? (orthoService) => orthoService.getGroupTree(groupName)
: () => Promise.resolve(undefined),
[groupName, numSequences]
);
Testing:
There are only a few tree files available on the back end, so only a few orthogroups work. Here's are the valid OGs at the moment:
Run
ortho-site
locally and access the path/app/record/group/OG6_102443
Back end config for.env
isTo do:
UX suggestions