Thursday, October 19, 2017

Small step for developer giant leap for community

Every person who has tried to fix some code he/she didn't write, knows that the real fun begins after the build...

Most of the projects have straight forward documentation that covers the build part. But when it comes to code editing: you are on your own. Now your success depends on how fast you are going to understand the logic of the mysterious lines written by some strangers.

I have noticed that it's much easier to improve/debug/add features to the code written by a single person, because he/she sees the big picture and idea, so it's easier to follow those.

Unfortunately when it comes to work on a project with hundreds or thousands of contributors, understanding the full logic is almost impossible and would take ages to fully know what is going on.

Luckily for me and other open source contributors, every project like that has communication channels. For example, Mozilla Dev Tools team is using Slack. That's the place where one can ask questions and get help. When you talk to people there you need to keep in mind that you are not the only one who is looking for help.
So if you want to get a straight forward answer, you need to ask a clear question.

Developing code is not an easy thing, but working with something written by a large amount of people is even harder. At the same time project may be more successful if more people contribute to it.

And as my open source journey continues, I hope, I will be one of the many who are working on something important, who are defining the future of the technology.

And the next stop is fixing code. My bug wasn't really a hard one, but it took some time to understand the logic of the flow. Fortunately, Jason Laster was there to answer my questions or to refer to the right person.

And now I am trying to pass tests and push the code to my GitHub forked repository. The first time I run tests I got the following output:

Snapshot Summary
 › 11 snapshot tests failed in 1 test suite. Inspect your code changes or run with `yarn test -- -u` to update them.

Test Suites: 2 failed, 59 passed, 61 total
Tests:       12 failed, 332 passed, 344 total
Snapshots:   11 failed, 101 passed, 112 total
Time:        96.983s, estimated 100s
Ran all test suites.

error Command failed with exit code 1.

info Visit for documentation about this command.

It amazes me how something small like changing a color of an icon can cause problems!
After asking how to get started with fixing failed test, I was told that there was an issue with line endings, so after git pull: -1 failed test suit and -1 failed test!

Jason advised me to ignore the failed tests, so git push!!! I have never though that such a simple git command can bring so much satisfaction!

I am almost there, my next step is to create pull request.

My code did not fail any of the PR checks! That feeling is amazing!
Do you know what feels even better? When real developers approve your code and give you some pleasant comments!

No comments:

Post a Comment

TIL: How to use DatePickerAndroid and TimePickerAndroid in React Native?

While working with React Native, I always tried to use built-in components instead of "reinventing" the bicycle. So today the d...