dondi / GRNsight

Web app and service for modeling and visualizing gene regulatory networks.
http://dondi.github.io/GRNsight
BSD 3-Clause "New" or "Revised" License
17 stars 8 forks source link

Node menu inactivated after loading network from database #977

Closed kdahlquist closed 1 year ago

kdahlquist commented 1 year ago

If the first thing I do upon landing on the GRNsight page is to load a network from a database, the node menu is disabled, so I am unable to color the nodes with expression data from the expression database.

I think that now that we have an expression database, the node menu should always be enabled because even if a user doesn't have their own data, they can use the database data.

dondi commented 1 year ago

Although it is possible to work around this by loading a demo first, and then loading a network from a database, there is now a follow-up issue where node coloring actually doesn’t take place until a dataset is chosen

ahmad00m commented 1 year ago

I believe if the node coloring should always be enabled this function need to be always enabled. This function is in setup-handlers.js, I tried to test it on localhost but I could not connect to it through the multiple attempts I made. So, first I hope to troubleshoot connecting to localhost and then check whether this is the right piece of code that needs to be changed.

Screen Shot 2022-09-14 at 4 56 44 AM
ahmad00m commented 1 year ago

UPDATE I tried to run the localhost on my laptop and it was able to connect to the server; however, I still got an error in my console and I was unable to load demos.

Screen Shot 2022-09-14 at 9 25 17 AM
dondi commented 1 year ago

@ahmad00m Regarding node coloring, I would agree that it is appropriate for it to be always enabled now, except where there is no network loaded

Go ahead and start a branch to work on it, or possible pair w/ @Sarronnn since she will also benefit from doing more of these types of fixes

dondi commented 1 year ago

For the demo errors, both @Onariaginosa and @dondi confirmed that their local builds are loading demos successfully, so that looks like a localized issue

dondi commented 1 year ago

Local build remains unresolved but bug fix could be done as a pair w/ @Sarronnn

dondi commented 1 year ago

Local issue with @ahmad00m has been fixed. Turns out that it was a specific problem with Node 17. Switching to Node 16 or 18 resolves it; @ahmad00m chose to go to 18 and GRNsight ran successfully

ahmad00m commented 1 year ago

Here is the linked that helped resolve this issue. https://stackoverflow.com/a/69789658

dondi commented 1 year ago

Thanks! I have updated the wiki.

Sarronnn commented 1 year ago

I wanted to first try @ahmad00m 's fix. But the local host can not connect to the database since it is local, therefore I am not able to see changes I made to the code unless I change my branch to beta.

Big thank you to @ahmad00m for all the help so far!

kdahlquist commented 1 year ago

@Sarronnn, I could be wrong, but I think you need to pull the beta code into your branch. This is always a good idea so that you can make sure that your code is up-to-date and also to make sure that there are not any conflicts with what you are doing. I also think that you will need to run a local copy of the database when you are running your code locally.

@dondi or @Onariaginosa can chime in if I'm wrong or to clarify the process.

ahmad00m commented 1 year ago

This bug is associated with database and in order to determine the change in code fixes the bug we need to tunnel to database using the ssh key or make a pull request to merge with beta (if you are sure the code written fixes the bug). Thanks to @Onariaginosa for spending time to teach me how to do this process, but as of right now the primary fix didn't fix this issue and I require more time to look where the code needs to be changed. I have some time later in the week to meet with @Sarronnn to go over the process and perhaps fix this bug together.

dondi commented 1 year ago

After discussing this issue during the meeting, the preferred approach for developers on the team will be to install and run their own copy of PostgreSQL on their respective devices

@Onariaginosa, @ahmad00m, and @Sarronnn will plan a meeting during the week to walk through process, with @dondi being available to consult just in case. Original data files have been linked to under separate cover and may need to updated to @Onariaginosa’s latest copy

We will also take advantage of this to review our database documentation and loader scripts in the database folder of the repository. The hope is to get the documentation to a point where new members can also walk through it in order to get up and running (perhaps something for @ntran18 to try in the future)

dondi commented 1 year ago

Above comment has been pulled out as a separate issue, #988

ahmad00m commented 1 year ago

I believe this issue is resolved. I was able to locate the node coloring function in the update-app.js and make it to be always on (it will default to expression data from Barreto_2012_wt data) when genes are being selected from database.

Here is how it looks. I can also demonstrate this during the meeting. 1

2

Sarronnn commented 1 year ago
Sarronnn commented 1 year ago
dondi commented 1 year ago

Already merged and placed in beta; got distracted by time zone issue