Closed seinecle closed 2 years ago
Nice @seinecle and sorry for the delay. I started looking into it and have some general comments and questions:
hi @mbastian,
Did some verifications:
Gist has a push limit at 100Mb per file (when not using GLFS).
I used the plugin to publish a network which corresponds to a gexf file of 61Mb with 2000 nodes and 279,000 edges.
During the Gephi week I had asked @jacomyal about rough upper limits for the size of a network to be displayed by Retina. It would be around 10k nodes and 20k edges - above this, the browser might get slower on some computers.
So it seems that the first limit is the network size that Retina can handle, not the max file size Gist accepts.
I propose that we set a limit to the size of the network to be published? Like: 20k nodes max, 40k edges max? If any of these limits is reached, the "Publish" button remains greyed out with an explainer.
Your comments are welcome @mbastian @jacomyal
@seinecle Thanks for verifying! It's a good news although it does contradict the Gist documentation, which I find strange. The link you posted is for GitHub and may not apply to Gist.
Regarding the size limit I'm not a fan of forbidding the upload but maybe rather inform the user that the experience is not gonna be optimal. The node/edge counts is also only partially a factor in the file size. The number of attributes and their content can also be a bit factor.
Ok, so no hard limit but a warning then - I'll update the plugin today.
Wow indeed many improvements to make. My comments:
@seinecle I did a deeper refactoring to help decouple the UI from the business logic, which was still tightly coupled. In addition, I uses our LongTask API instead of SwingWorker. With that, you easily get the progress bar too. The two Runnable
classes are now completely decoupled from the UI. The UI updates itself through a LongTaskListener
(success) and LongTaskErrorHandler
(error).
One UI improvement I think you could still make is on the final result. It's really paintful to have to copy-paste the final URL from a text field. Why not having an "Open" button or "Copy to clipboard"? Java can easily open the browser for you with an URL.
@mbastian thanks! LongTask
seems super nice, glad to discover this utility! And thanks for the refactoring.
I have:
LongTask
was returning stringsThanks @seinecle! I just noticed that the access token we get from GitHub expires after 8 hours. This isn't something we can change but there is a flow we can use via refresh tokens to have 6 months tokens. It seems unpractical to have to go through the authentification every day so it would be good to implement that. We shall also change the narrative in the UI. It's a little more complicated than "Setup once".
ok, thanks for identifying this! Will have a look.
@mbastian reading the doc, it seems we can just opt out of expiring tokens? If I understand correctly, the 8 hours limit is just for expiring tokens. So in Gephi's github app ("gephi-lite"), there just needs to opt out expiring tokens. The steps to find this option are detailed in the link you included in your comment. Please let me know if I misunderstand something.
@seinecle Interesting. It still don't really get from the doc what happens when we opt-out? Access token don't expire at all? I opted out now. Let's see how it goes
@mbastian do you think we can move to the publication?
@seinecle Yes, almost :) Looks like you inverted the buttons between gist view versus network viz.
@seinecle The plugin is published https://gephi.org/plugins/#/plugin/web-publish-plugin
Thanks for this great work! cc @jacomyal
@mbastian Thank you for the extensive code review !!
First of all, thanks for developing this plugin @seinecle. I can imagine this being very useful!
The plugin doesn't seem to work for me at the moment, however. The authentication process works flawlessly, but when I try to publish my network, I always get the following 500 error:
Error creating online gexf file. Error code:500; Error message:
Is there any way to fix this? I've tried re-authenticating, using a different network and restarting Gephi, but it doesn't seem to make a difference.
Thanks!
New plugin or plugin update?
What is the purpose of this plugin?
Enable the user to publish the network they are working on, to the web. See this issue for details of the implementation: https://github.com/gephi/gephi-plugins/issues/262#issuecomment-1231627948
How to test your plugin in Gephi?
Checklist before submission
master
branch to get the latest updates?pom.xml
file