publiclab / plots2

a collaborative knowledge-exchange platform in Rails; we welcome first-time contributors! :balloon:
https://publiclab.org
GNU General Public License v3.0
957 stars 1.83k forks source link

GSoC '22: "Legacy Code Deprecation" Project Planning #11185

Open anirudhprabhakaran3 opened 2 years ago

anirudhprabhakaran3 commented 2 years ago

Hello everyone! 🎉

This is the planning issue for my project "Legacy Code Deprecation" which I am going to work on over the summer. Comments, suggestions and improvements to everything mentioned in this are welcome and will be very useful for me!

My project proposal can be found here.

Before Coding

DrupalNodeImage

Issue: https://github.com/publiclab/plots2/issues/76

Gallery Code

Issue: https://github.com/publiclab/plots2/issues/4074

Tilda's PR (https://github.com/publiclab/plots2/pull/9980) regarding that was also closed (not merged), can look into that and take some inspiration from it.

Answers model

Issue: https://github.com/publiclab/plots2/issues/956

Map notes

Issues: https://github.com/publiclab/plots2/issues/4072, https://github.com/publiclab/plots2/issues/10830 (closed now)

DrupalFile and DrupalUpload

Issues: https://github.com/publiclab/plots2/issues/4076

anirudhprabhakaran3 commented 2 years ago

All feedback is welcome! Thank you!

jywarren commented 2 years ago

Hi @anirudhprabhakaran3 this is looking great. I like how you've broken things up into groups, and see that you're using the existing deprecation milestone :tada:

In some places there are notes on whether records have been converted already, and I'm not sure about DrupalImages -- have you seen anything? As we go through these, probably best to link to the last known notes/status of these migrations. In some cases I think we have already moved the records and now just need to remove the tables and/or code.

Were you thinking to go through these as they're written, top to bottom? Thanks!!!

anirudhprabhakaran3 commented 2 years ago

Yes, I'll add links to the previous issues, so that anyone viewing it can easily see the current status.

Regarding the DrupalImages, this was the last comment I found: https://github.com/publiclab/plots2/issues/76#issuecomment-481749324

I believe we have identified what has to be done but actually haven't done it yet. Is my understanding correct?

Yes, I was thinking of going through the list top-down. If there is a group to which you believe I should give priority, please let me know so that I'll work on that first! Thank you!

TildaDares commented 2 years ago

This looks great @anirudhprabhakaran3. I agree with @jywarren's comments on how you grouped your tasks into groups. Great work 🎉

jywarren commented 2 years ago

Regarding the DrupalImages, this was the last comment I found: #76 (comment)

I believe we have identified what has to be done but actually haven't done it yet. Is my understanding correct?

Yes that seems correct to me. I will leave another comment there, but given the challenge of downloading the images, i wonder if you wanted to start on an easier one? Your choice!

anirudhprabhakaran3 commented 2 years ago

Oh okay. I'll look into that. Thanks for the heads up!

Also left a comment on that issue. Is it fine if I put any issue specific conversations on the issue itself, and then put like a summary on this issue? I feel it'll be easier for tracking status.

cesswairimu commented 2 years ago

@anirudhprabhakaran3, yeah, that is totally fine

jywarren commented 2 years ago

Hi @anirudhprabhakaran3 can you update us on where you are on your project right now? Midterm evaluations are coming up this week so I want to have a good understanding of where you're at, and let us know if you are stuck on anything! Thank you!

anirudhprabhakaran3 commented 2 years ago

Hello! Yes, it has been quite some time since I have updated this issue. My apologies!

I am currently looking into the DrupalNodeImage issue (#76). I'm going through all the different approaches mentioned on the thread to see which is the best, which is taking more time than I expected. That is the cause of the delay.

I was wondering if I should come up with the migration for the Answers model (#956 ), since most of the work in that is complete - the only part left is to remove the actual table and any references to it in the code. That should not take too much time, and I can create an MR for the same.

Do you think that is a good idea? Or should I stick to that, try to find a solution, and then jump to the more straightforward script?

Thank you!

jywarren commented 2 years ago

Hi @anirudhprabhakaran3 sorry for slow response here but I'm glad to see you are working on the answers model too! It can be good to have 2 projects going in case you feel stuck on one, or just to give your brain a break (being able to switch between a bit). I'll look at your answers PR too!

anirudhprabhakaran3 commented 2 years ago

I am planning on finishing nearly all the tasks on the list! However, the DrupalNodeImage one might not be finished in time :(. I do plan on completing that task even after GSoC though. Thanks!

jywarren commented 2 years ago

Hi @anirudhprabhakaran3 -- since your work in #11225 is done, I opened a PR for removing all map node files!

https://github.com/publiclab/plots2/pull/11414

I'm also going to set a reminder to convert /app/views/map/index.html.erb to redirect to /tag/map-archive, and to copy the text from publiclab.org/archive to the /wiki/map-archive page.

OK, made the page: https://publiclab.org/wiki/map-archive