higlass icon indicating copy to clipboard operation
higlass copied to clipboard

HiGlass 1.8.5 appears to not work with StackedBarTrack

Open alexpreynolds opened this issue 4 years ago • 2 comments

Commit:

Tag v1.8.5 of higlass Branch master of higlass-multivec

Steps to reproduce

To see the error, I load a new viewconf into a HiGlassComponent container. The changes to the viewconf do not seem connected to when the error occurs. (If I manually reload the new viewconf, then the page renders correctly.)

Observed behavior

On average, once on every three updates to the viewconf of a HiGlassComponent, I get the following exceptions thrown, which appear to be connected to TiledPixiTrack.js and DataFetcher.js in higlass, and their interaction with StackedBarTrackClass in higlass-multivec:

Screen Shot 2020-03-13 at 2 00 13 PM

Here's the error message displayed on the application in which I am embedding an epilogos track:

Screen Shot 2020-03-13 at 2 02 33 PM

I'm not sure if this is an error in higlass or an error in higlass-multivec.

I tried the advice in this Pixi.js thread (https://github.com/pixijs/pixi.js/issues/6263), modifying the scene property in PixiTrack.js in higlass, but the error still appears intermittently.

Expected behavior

No Unhandled Rejection (TypeError): Cannot read property 'transform' of null errors.

alexpreynolds avatar Mar 13 '20 21:03 alexpreynolds

Hey Alex, do you have a sample viewconf I could try this with?

pkerpedjiev avatar Mar 14 '20 04:03 pkerpedjiev

Hi Pete, thanks for checking things out.

I don't understand the source of the bug, but wrapping calls to drawVerticalBars and pixiRenderer.generateTexture in try/catch blocks in the higlass-multivec plugin helps get past this exception. The functionality of the application seems normal, so far.

Here is a test viewconf:

viewconf.test.pretty.json.zip

Following your recommendation on Slack, this includes a track that uses a categorical variant of the heatmapValueScaling track option, for the horizontal-multivec track type.

I started to make some code changes to support color mapping that references the color array in the track's colorRange option.

These changes are unrelated to use of the higlass-multivec plugin for rendering the epilogos track, as the exception errors show, but if it helps I am including a link to my fork of higlass to help make this reproducible:

https://github.com/alexpreynolds/higlass/tree/categorical-color-scheme

My fork is branched off of the v1.8.5 tag of higlass/higlass. This is to avoid errors from using higlass-multivec with v1.9.0 (reported on Slack and on another issue here).

My React application's package.json file uses the file://path/to/higlass and file://path/to/higlass-multivec pattern to use customized versions of these packages.

alexpreynolds avatar Mar 16 '20 18:03 alexpreynolds