Page MenuHomePhabricator

[Proposal] Commons App: Improve upload queue management
Open, Needs TriagePublic

Description

Profile Information

Name: Kanahia
Email: kaushalkanahia@gmail.com
Location: Patna, Bihar, India
Time zone: GMT+5:30 (Kolkata)
Education: Indian Institute of Technology, Patna (IIT-P) (Expected Graduation Year: 2026)
LinkedIn: kanahia-kaushal
GitHub: kanahia1
Other Communication modes: Discord, Zulip, Telegram
Typical Working hours: 9 am to 9 pm (IST) UTC+5:30

Synopsis

Wikimedia Commons is an Android app that enables users to upload and view pictures from their Android phone/tablet on the Commons server. Aim of this project is to improve upload queue management, and modernize the app.

Mentors - @Nicolas_Raoul @RitikaPahwa4444

Have you contacted the mentors already ?

Yes.

Deliverables and Implementation Strategy

Picture1.png (816×1 px, 110 KB)
Frame 53.png (1×3 px, 274 KB)

  • Implement new design for upload queue management
  • Implement Real Queue and Write Test Cases for newly Added Functionality
  • Fix queued upload gets stuck and restarting the app does not make it start
  • Prevent retries for genuinely failed uploads
  • Fix the app erroneously showing successfully uploaded images as "Failed"
    • Since app shows “Failed” due to cutting off internet a right time. This should be fixed by verifying the information of current uploads with server on network change and changing the UI as per the data received.
  • Prevent Duplicates
  • Nearby: Load pins as the user moves the screen, cache pins, remove "search this area" button
  • Split Nearby into a fast query for coordinates + a details query for each pin.
  • Feedback about a Wikidata item
  • Write Documentation and Create Test Cases for all the functionality created.

Timeline

PeriodTask
May 4 to May 26Community bonding period
- Wikimedia Hackathon’24 (May 4 to May 8)
- Introduce myself to mentors and other contributors (May 9 to May 26)
- Feedback about a Wikidata item Issue #2425
- Split Nearby into a fast query for coordinates + a details query for each pin Issue #4560
- Nearby: Load pins as the user moves the screen, cache pins, remove "search this area" button
- Write test cases for newly added functionality
May 27 to June 12- Develop new UI for upload queue management in Figma
- Take feedback from others (Contributors + Mentors) regarding new UI
- Implement new design
- Write test cases for the newly implemented design
- Fix failing test cases caused due to replacement
June 13 to June 26- Implement real queue in which uploads should be performed one by one
June 27 to July 5- Fix queued upload getting stuck and restarting the app does not make it start Issue #5603
July 5 to July 7- Prevent retries for genuinely failed uploads Issue #5284
July 8 to July 12Mid-Term Evaluations
July 13 to July 17- Prevent retries for genuinely failed uploads Issue #5284
July 18 to July 25- Prevent duplicates Issue #5608
July 26 to August 3- Fix the app erroneously showing successfully uploaded images as "Failed" Issue #5280
August 4 to August 15- Enqueue failed uploads, rather than uploading them simultaneously with the ongoing upload Issue #5283
August 16 to August 28- Write documentation and update appropriate guides for implemented functionalities
- Complete any backlog
August 26 to September 2- Mentors submit final GSoC contributor evaluations
September 3Initial results of Google Summer of Code 2024 announced

Participation

  • Communicate with the mentors through Github or Zulip and incorporate all the suggestions.
  • I will be online on my working hours 9 am to 9 pm (GMT+5:30)
  • Write blog on medium on completion of every task.
  • I am also available to be contacted through my email.

About Me

I am Kanahia, a student of Mathematics and Computing at the Indian Institute of Technology, Patna (IIT Patna), I am a coding enthusiast. It has been 2 years since I started working with Android, I am comfortable with Firebase, Git, UI Development, Retrofit, and Canvas. I have also worked with NodeJS, Express, and MongoDB. I gained my experience by working with the Android team of my college that creates apps for Inter-IIT competitions and created apps for fests that take place in the college.

How did you hear about this program?

I got to know about this program from my seniors.

We advise all candidates eligible for Google Summer of Code and Outreachy to apply for both programs. Are you planning to apply to both programs and, if so, with what organization(s)?

I am only applying for Google Summer of Code.

Past Experience

Research Intern, Sveučilište u Zagrebu:

  • Developed Android App for visualization of Smart House in Augmented Reality.
  • Created React Website to create, edit houses which can be later on visualized on the Android Device

Research Intern, CSE Department IITP:

  • Mapped the heritage site of Nalanda University using LiDAR technology.
  • Reconstructed Nalanda University in Virtual Reality using Unity.
  • Developed an Android application aimed at aiding evacuation procedures during earthquakes.

My Personal Projects:
Boolian: The main idea of this app is help users to learn NFTs with the help of Images, Articles, and Videos. The course in the app is created to help users learn perfectly. The project is different as there are few resources to learn NFTs. In this project, I created custom UI components that are not available in Android itself. In this project I used Firebase Auth, Firebase and I created the UI for this app.

Med.io: The app specializes in utilizing a decentralized database to enhance transparency in the healthcare sector using cryptographic measures. Primary focus areas include ensuring interoperability, maintaining a decentralized secure database, implementing cryptographic measures, providing hassle-free service, and incorporating AI/ML models to enhance user feasibility.

More information is available here.

Achievements

  • Led the team of finalists at Smart India Hackathon’23
  • Got selected for a research project funded by Department of Science and Technology, Government of India
  • Showcased research projects at India Mobile Congress, at Pragati Maidan, Delhi
  • Secured a rank in the Top 1% of all students who appeared for the JEE ADVANCED exam.

Volunteer Experience

  • Sub-Coordinator, NJack:
    • Took sessions of 200+ students regarding Git and Android Development.
    • Organised Codepeak - It is month-long program that helps students understand the paradigm of Open-Source contribution.
  • Sub-Coordinator, E-Cell:
    • Helped in organizing the Hult Prize OnCampus program on the campus.
    • Organised fun events for the members of the E-Cell.

Relevant Skills

  • Experience in Android development with Kotlin, Java
  • Proficiency in using SQL and Room Database
  • Git and GitHub
  • Testing in Android: Instrumented as well as local tests
  • Understanding of Retrofit, Jetpack Compose
  • Experience with Wikimedia APIs and SPARKQL

Previous Contributions to Commons

I have been contributing to the Commons Android app since October 2023. You can find all my pull requests here.

Total: 19
Merged: 18
Open: 1

++4,424 --3,598

Pull Requests

S. No.PR No.DescriptionStatus
1.#5475Replace Mapbox with OSMDroid (Explore Activity)Merged
2.#5403Replaced Mapbox with osmdroid (Nearby activity)Merged
3.#5443Replaced mapbox to osmdroid (Upload Activity)Merged
4.#5645Added functionality to export location of nearby missing pictures to GPX file and KML fileMerged
5.#5415Added voice input for caption and descriptionMerged
6.#5658Fixes Nearby export: Pins not all around meMerged
7.#5652Changed Created by in Neaby exportMerged
8.#5654Improved UX for Nearby ExportMerged
9.#5356Fixed Grey empty screen at Upload wizardMerged
10.#5670Fixes App crashes on clicking Save (EditActivity)Merged
11.#5464Fixes on Edit button, there is + sign overlayed over letter EMerged
12.#5450Fixes #5439 by capitalizing first letter of voice inputMerged
13.#5481Fixed javadoc issueMerged
14.#5635Fixed reproducible crash when marking last pictures as "not for upload"Merged
15.#5555Removed MAPBOX Access tokenMerged
16.#5631Removed MapBox related importsMerged
17.#5553Made Nearby show all pins that could be presented on the screen, rather than a circleMerged
18.#5616Fixed Blue square appears at end of description of image uploadedMerged
19.#5575Fixed Clicking on edit photo shows default rotationOpened

New Issues Raised

S. No.Issue No.Issue DescriptionStatus
1.#5458Replace Mapbox with OSMDroid in Explore ActivityCompleted
2.#5457App crashes on pressing the "My Location" icon in the upload wizardCompleted
3.#5566Remove the Mapbox-related imports in Java/Kotlin/GradleCompleted
4.#5611Remove Mapbox from CREDITSCompleted
5.#5625Change snackbar's error message in the User PageCompleted
6.#5457[Bug]: Attempt to read from null error in Explore -> Map fragmentCompleted
7.#5531Circular Progress bar keeps on moving even though nomination for deletion is successfulOpened
8.#5502Clicking on edit photo shows default rotation (Upload Activity)Opened

Availability

Are you eligible for Google Summer of Code?

Yes.

Do you have any other plans during the period of GSoC?

No, I do not have any other plans during the contribution period.

How many hours per week can you dedicate to this?

Since I will be having summer break till 20 July I will be available for at least 40 hours a week through online platforms and am ready to extend whenever needed. I would be working full-time for GSoC.

Have you been accepted to GSoC before?

No. I am applying in GSoC for the first time.

After GSoC

I would like to keep contributing to Wikimedia after GSoC and will be available to resolve issues and manage pull requests. Even if I am not selected this year, I would like to help this project by resolving issues, suggesting new ideas, and participating in discussions. I usually help people with code. I would like to keep contributing to the Wikimedia organization and do whatever I can to help.

Event Timeline

Great proposal! I've a few observations to share.

Since app shows “Failed” due to cutting off internet a right time. This should be fixed by verifying the information of current uploads with server on network change and changing the UI as per the data received.

This issue isn't just about UI changes as far as I remember, we lose some data in the process. So, the server doesn't have that data either.

@RitikaPahwa4444 Ah! I got it since the request has not been completed, the server will not send any data. What I feel could be a possible solution for now could be introducing timeouts (similar to what most downloaders do in case there is a network change) when the user reconnects with the internet we can start reuploading (but that will be done from the start) otherwise we can cancel the upload after certain timeout.

when the user reconnects with the internet we can start reuploading (but that will be done from the start)

Unfortunately, that causes duplicates on the server. Cancelling it will make the users go through the same process again (and we'll have duplicates again).

It's alright if we don't have an exact implementation strategy at this stage, please feel free to go with a generic strategy for now :)

We can discuss that in detail later and come up with a feasible solution. I just mentioned it so that it could be accommodated well within the timeline (unlike UI changes which seem relatively simpler and can be wrapped up quickly).

Sure, We can do a well-over research on the approach during the Summer :-)

Week 1 : Weekly Internship Report (27 May -2 June)

  1. Overview of Tasks Completed: Provide a summary of the main tasks you worked on this week.
    • Added WikiTalk Page
    • Made Split to Nearby Query into a fast query for coordinates + a details query for each pin
  1. Key Accomplishments: Highlight any significant achievements or milestones reached during the week.
    • Added the ability for the contributors to give feedback about places in the nearby
    • Improved the loading of the pins in the nearby
    • Removed toggle chips and fixed the pins not loading from the center
  1. Challenges Faced: Describe any difficulties or obstacles you encountered and how you addressed them.
    • Working with API for page editing/creating was one of the challenges.
  1. Goals for Next Week: Set specific goals or tasks you aim to accomplish in the upcoming week.
    • Implement the new UI design for the upload queue management.
    • Work on the current opened Pull Requests and make changes as suggested by the mentors.

Week 2: Weekly Internship Report (3 June - 9 June)

  1. Overview of Tasks Completed: Provide a summary of the main tasks you worked on this week.
    • Improved the design of pending uploads
  1. Key Accomplishments: Highlight any significant achievements or milestones reached during the week.
    • Added pending uploads screen
    • Added failed uploads fragment
    • Added upload icon in Main Activity to display failed/pending uploads and remove limited connection mode
  1. Goals for Next Week: Set specific goals or tasks you aim to accomplish in the upcoming week.
    • Implement uploads as a real queue and implement resume/pause
    • Work on the current opened Pull Requests and make changes as suggested by the mentors.