Project Description: The project focuses on extending the functionality of Appwrite server using Appwrite Functions and Open Runtimes, and contributors are invited to enhance the Open Runtimes Examples repository.
Issue Description
https://github.com/appwrite/appwrite/issues/4122
Compress Image: The issue involves implementing the `compressImage()` function using Python within the Open Runtimes Examples repository. The function aims to perform lossless compression of an image by introducing support for tinypng and krakenio providers. The function should receive an image in base64 format and return the compressed version in base64 format, with appropriate success or error responses.
https://github.com/appwrite/appwrite/issues/4155
Text to Speech: Generate spoken audio from a written text. Introduce support for google, aws, as well as azure APIs. If necessary, introduce their secret keys as function variables. Provider to use, language, and a text to convert into audio should be received as payload, and an audio version should be returned in base64 format. If no language is provided, the language should be automatically figured out (if possible). Please use iso639-2 format for language codes.
How much experience does your group have? Does the project use anything (art, music, starter kits) you didn't create?
CodeDay Labs team in the advanced track.
In terms of my background, I've gained a certain level of familiarity with Python and Github through the Computing Talent Initiative. However, my exposure to Docker has been quite limited, with no prior hands-on experience. On the other hand, Ngoc brings a valuable set of skills to the table, including experience in Python, Docker, and Github.
In the initial stages of our collaboration, Ngoc and I went on a journey watching Youtube Videos, Articles, and Documentation to understand the background context. Through this effort, we aimed to build a foundational understanding that would enable us to effectively apply these concepts to the Compress Image and Text to Speech issues we were tackling.
What challenges did you encounter?
Client Errors with API's:
One of the key challenges we encountered during the project revolved around client errors associated with APIs, specifically focusing on KrakenIO and TinyPNG. These APIs typically rely on client libraries to establish endpoints and connect seamlessly with their servers. However, a considerable roadblock emerged when we realized that the KrakenIO API client was outdated, dating back almost seven years.
To tackle this challenge, we devised a solution. We opted to leverage the "requests" library, enabling us to craft direct POST calls directed at KrakenIO's endpoints. This workaround allowed us to engage with the KrakenIO API in a manner that circumvented the lack of a suitable client, thereby overcoming the client-related hurdle.
GitHub Errors:
Another noteworthy challenge we encountered centered around the usage of GitHub as our primary version control system. Despite our familiarity with implementing specific functions, our relative inexperience with GitHub led to a series of difficulties. Merge conflicts and issues related to rebasing arose as we endeavored to synchronize our individual code contributions effectively.
The process became further complicated due to inconsistent pushes and commits, resulting in a cascade of errors that slowed our progress. Recognizing the need for expert guidance, we sought assistance from our mentor. He introduced us to best practices, such as squashing commits and adopting a structured GitHub workflow for safe and efficient push and pull operations across our respective branches.