Everything I learned | Week 13| Encora/Nearsoft Academy

Gibran Herrera
2 min readJul 6, 2021

Hi everyone! πŸ€—

I’m approaching an important due date, the end of the open-source phase, and the beginning of my future as a software engineer.

β€” β€” β€” 🦦 Go 🦦 β€” β€” β€”

I’d like to share fancier things as the previous week's topic with the sync pool data structure but now I’ve learned more about how strings in Go work.

This time I had to solve a little bug within an open-source project where an RSS (Really Simple Syndication), which is used to allow users and applications to access website updates in a standardized way, was returning Medium article titles with newline characters β€œ\n”

That caused issues on the UI for the application, and to fix it, I should replace the newline characters with simple spaces. One way I thought to fix it was changing them directly through a for loop, but of course, Go strings are immutable. But instead of writing more code that may not be well optimized, I decided to dive through the Go documentation and I found the perfect method to it in the strings package, β€œReplaceAll”.

package mainimport (
"fmt"
"strings"
)
func main() {
fmt.Println(strings.ReplaceAll("My\nAwesome Title", "\n", " "))
}

β€” β€” β€” πŸ¦‘ The Status Of My Open Source Projects πŸ¦‘ β€” β€” β€”

This week I got done with my third and almost fourth contribution, my progress was slower than I thought but the amount of research and work to be done for each of my issues was an important part to take into consideration, also I had to re-engineer my solution for my first PR like three times due to new edge cases and additional testing, I count them and it was 25.

Fortunately, I have a maintainer that is always considerate of my point of view and helps me through my questions about the project.

β€” β€” β€” β›° Final Thoughts β›° β€” β€” β€”

Open source has its charming, when you find the right project you fall in love and want to contribute more. But I also have to consider that the number of projects and topics are overwhelming for everyone, and the community should think of a better way to attract beginner developers.

Thank you for reading until here!

See you! πŸ‘‹πŸ½

--

--

Gibran Herrera

Software Engineer πŸ‘¨β€πŸ’» β€” Pythonist 🐍 β€” Linux lover 🐧 β€” Learning πŸ¦€πŸ‹