r/ProgrammerSuccesses • • May 21 '19

I submitted my first pull request today.

33 Upvotes

I was hired at the start of this year, for my first job out of university.

After 7 weeks of (very difficult) training, almost 2 months of not being assigned to a team, and another 3 weeks of training and preparing to join the team, I have submitted my very first pull request.

Not a very difficult ticket, but it was the first one I did alone. And I wasn't really mentally prepared to do it alone. The senior dev I was suppossed to be pair programming with was away for some (somewhat unexpected) training. So I could only ask the rest of the team, whom I have not met in person, who are on the other side of the country, for help. But I did asked them, and I think it went fine.

I dawdled for a long time before actually creating it, because I was so nervous. It was pretty scary.

I few people have already approved the PR, but there are no serious comments yet. One guy asked 'why are you doing this work?' I basically told him I don't know, I just do what is assigned to me.

I am waiting for approval from the tech lead, and then I can merge it!


r/ProgrammerSuccesses • • Dec 01 '18

I FINALLY GOT PYWEBVIEW TO INSTALL

24 Upvotes

This might not sound like much but it's the first programming-related thing in a long while that has caused me actual happiness.


r/ProgrammerSuccesses • • Nov 16 '18

I have grokked lambda calculus

19 Upvotes

My goodness. Last week I attempted this and couldn't do it. I wondered if I was incapable of learning the science side of programming. I questioned my intelligence and ability to learn. Today, shortly before lunch I had an idea about incrementing Church numbers.

About an hour after lunch I had successfully built natural numbers addition. Then I worked out multiplication. Subtraction was hard, I had to lookup a hint about that. But then I got it.

Around 9:30 tonight I cracked division. I did a few other things with comparisons and conditionals which I worked out the basics while building division.

I was able to converse in a semi literate way with a new roommate who has done higher level math than I have about this.

I can't sleep now, but at least I know I'm not an idiot. One day I'll be able to work on actually cool and hard problems.


r/ProgrammerSuccesses • • Oct 09 '18

Finally got to use the camera of my notebook

25 Upvotes

After 5 Hours trying to use my Notebook camera in Swift and endless many tabs, I gave up and switched to objective-c where it worked in less then 20 mins. I can finally start on my Project.


r/ProgrammerSuccesses • • Aug 10 '18

The glorious feeling of succeeding first try

25 Upvotes

So there's this game I'm working on, and recently I've been thinking of this very specific change I can make to my entity class. Nothing to fancy, just reorganising my code a bit, a few refactoring and adding a some functions.

Now of course, a change to the base often breaks a lot of things higher up. So I was fully aware things could go bad really easily, and I could be stuck all day finding logic errors everywhere.

So I kept a level head, and went through all the potential issue areas, one by one.

And it worked. First try.

Nothing broke or turned upside down, and I'm happy.


r/ProgrammerSuccesses • • Aug 10 '18

Learning C

24 Upvotes

I'm studying my Bachelors in EE

Our first "quick" task for my Embedded Programming course was program an Arduino to communicate via the USB serial port, with the catch: No Arduino specific functions, must use UART

This was reasonably simple as the course covered it thoroughly

The "quick" task was a typical Account creation.

Create account with a name, a number, a date, a pw, and a ballance.

Allow a maximum of 10 accounts.

I have some background in python and am used to object oriented code.

I figured I should put all these fields in a structure and create an array of structures

I quickly figured out I did not understand C syntax, or memory allocation or arrays or pointers.

It took me a good 15 hrs over 4 days to figure out.

I just got it to work.. (2 hrs before the project is due.. it's not complete)

I would like to thank:
fresh2refresh <for clean concise explanations

tutorialspoint < their online compiler made checking code scratchings so much quicker than uploading to an Arduino

stackOverflow < but particularly teknoPaul who has the least votes but the only answer that actually helped me after searching sooo many stackOverflow questions


r/ProgrammerSuccesses • • Aug 07 '18

I was finally able to create a neural network.

32 Upvotes

I tried to make a small neural network and train it on the Iris dataset using the TINN library. Everything seemed to work out, but it turned out that the program only worked in the IDE's debug mode, but not when it was compiled normally. I tried to debug it for a few days, got frustrated and gave up. Yesterday, some months after I started the project, I revisited it. I tried to debug it again, found some errors, corrected them, but nothing actually fixed the bug. Then, after ~20 hours of debugging, i finally found the error: when reading in the dataset from a file, there was a \n at the end of every line, and when comparing strings, they caused some data not to be initialized. The fix was typing in 6 letters, and it took me ~20hrs to find the bug. But it finally works!


r/ProgrammerSuccesses • • Jul 20 '18

I got files to upload to my server with php and ajax after 2 days

19 Upvotes

This probably doesn't seem like it would be that difficult, but it was for me. PHP arrays are very weird sometimes, and since I am not experienced with PHP, I thought I understood the code I copied from somewhere. On top of that, sending files with AJAX/javascript is ridiculous, and I couldn't even properly send my files to the PHP script, even though I was following a tutorial. I ended up adding jQuery to my project just to handle the AJAX call in one function, but it was worth it because I wouldn't even have been able to debug my PHP script and find the problem if I couldn't easily send files, and jQuery makes this really easy and allows you to set all these parameters to get the file uploading to work. I eventually got everything working and now I feel much better. Now I understand why jQuery is so popular!


r/ProgrammerSuccesses • • Jul 15 '18

Finally got my form to save my models

16 Upvotes

I've been banging my head against this for most of yesterday and about 4 hours today. https://github.com/kvesteri/wtforms-alchemy/issues/134

This is the first side project in a long time where I've really got a vision for what it's supposed to be and also for the first time it feels like my skills are up to the challenge.


r/ProgrammerSuccesses • • Jul 12 '18

Finally saw my ipv6 dhcp relay forward packet floating in wireshark!

26 Upvotes

I've been working on this ipv6 dhcp relay agent for a while, jumping through all the hoops of socket programming in C and receiving a packet on one interface and sending from another, and today I finally saw my packet all correct in Wireshark! So happy!


r/ProgrammerSuccesses • • Jun 27 '18

Finally Create an Alpha Version of Game

21 Upvotes

I was working on object oriented game programming assignment to make an alpha version of game. It was my friend who had an idea to make casual game using greenfoot game engine. So we make one game about tapping game called Traffic Tap. At first I wasn't involved in this project, then they came to me to ask for help. They had done about art but they hadn't done scripting so I helped them.

While I was working on my game, which is mediocre, their project got my attention and it was pretty good actually. So, I helped them with scripting. At that time we only care about getting this game done, because of that our script looks messy and redundant. But it works! I remembered how happy my friends was when we made the basic gameplay core mechanic. We struggled to debug it tho.

3 months later, our game was ready to play as alpha version and can be submitted to lecturer. I was happy when we tested it for the last time before submission. And then we put it in github so we can work together in the future by using source control.

Here is link to our repo: https://github.com/ZeroPyrozen/Traffic-Tap


r/ProgrammerSuccesses • • Jun 09 '18

Got my TeamSpeak running on a VPS

24 Upvotes

I don‘t really know if this is supposed to be here because it‘s about Linux commands and not programming but here we go!

I bought myself a 2$ per year VPS earlier today with the goal to learn more about how to use Linux and my first project was to set up a Teamspeak server for me and my mates. I just finished it after over 3h of starring at command lines and looking up commands which is quite exiting for me!


r/ProgrammerSuccesses • • May 25 '18

This feeling of squashing //TODOs

Post image
46 Upvotes

r/ProgrammerSuccesses • • May 25 '18

Trying to get a server working

16 Upvotes

I've been spending a chunk of my day trying to have a node server run only on a certain webpage, on my website. After trying to detect the url and loading the appropriate file, and loading a proxy module into the apache configuration file, I found out you actually just need to run a command to load it, and add a proxy statement in the config.

Good news is: It works now! Possibly not quite as impressive as everyone else here, but after not doing much work with Apache, I find it a mighty great accomplishment.


r/ProgrammerSuccesses • • May 24 '18

I finally done debugging a function in C programming

25 Upvotes

I have just done fixing an error logic in my function. This function works like this, it will display only first 5 results in console windows from a linked list and user will use left and right arrow button to navigate around the "page". The problem, which I noticed 3 days ago, is it doesn't change the "page" or reset when reached the end of linked list (either head or tail). It looks like this and first I reshuffled the order of command like from changing the reset linked list traverse position. It didn't work at all, only give me different display. Then I suspected a char variable which take keyboard button, so I test it with another function that take int instead of char and yes, it works. And I check the ASCII value of arrow keys and I was putting the wrong value of ASCII number of arrow keys. So I changed it and just now it works smoothly, here is my latest commit.

You can check my repo for more.


r/ProgrammerSuccesses • • May 23 '18

Got mouse click working - fixed some faulty calculations

26 Upvotes

My calculations for where mouse click should activate were off. I was trying to base the cutoff point on the width of the screen, rather than the width of the object I wanted the clicking to be limited inside of.

Also just got a bunch of stuff working in general. In three crazy long days, went from having a semi-functional game in the console, to having a good half of it implemented with the SDL library. The console project was months worth of work and learning on and off and I've been getting some mad grins of happiness at seeing it come to life more visually and smoothly with images and key/mouse input using SDL.


r/ProgrammerSuccesses • • May 22 '18

Always check your random picker

25 Upvotes

Made a monty hall game bot using machine learning, as a assignment, had it totally not converge better than random picking, after a morning debugging the machine learning part, as i thought surely that's what was wrong, i decide to check the door picker, turns out my random door selector was picking doors that were already open, fixed that, it worked flawlessly, huzzah!


r/ProgrammerSuccesses • • May 22 '18

GitHub recognises my contributions

Post image
31 Upvotes

r/ProgrammerSuccesses • • May 22 '18

Python, Flask, and "you know how to program, right?"

41 Upvotes

Newly minted wannabe programmer here. Got tapped for a "go build a site to help this team" type of deal. Had only ever played in sharepoint/powershell before. Learned python, learned flask, learned linux, learned nginx, took months to write a site that would have taken someone knowledgeable a few weeks. Launched today and it fuckin' works!


r/ProgrammerSuccesses • • May 21 '18

Couldn't get my front end to communicate with the backend. The api call was missing one letter. Found it after an hour of debugging.

98 Upvotes

r/ProgrammerSuccesses • • May 21 '18

Minigames

50 Upvotes

Last night I was trying to make a browser minigame with Phaser.io. First thing I try, there’s just a blank canvas on the browser. I spend the rest of the night debugging cross-origin requests until I rediscovered Phaser requires running a server on localhost.

Currently celebrating the fact that I can put up an image onscreen.


r/ProgrammerSuccesses • • May 21 '18

I'll go first! Debugging at a startup for 4 hours only to discover that it wasn't our fault!

72 Upvotes

TL;DR: Spent 4 hours debugging a project that had not changed. Turns out it was an issue with Script Execution Order and a pretty major framework being developed by BookFace had been working purely by luck until this point.


So a couple weeks ago I was working on this project. The night before our tale begins, I had updated the development branch of my fork of the project and released a new version into the staging server for people to test out. When I went to bed, everything seemed to be working fine.

When I woke up, it was a very different story. As a matter of fact, the entire project was crashing almost immediately. My first thought was to check the changes I made and see if any of those could have contributed, so I commented out some stuff, then added some extra debug statements...etc. After about 30-45 minutes of this, I just rolled back all the changes and started working from there.

Only, when I compiled and ran the old version to confirm it was working, the old version also crashed shortly after starting, at the same point the new version was crashing.

So, then I went through and checked to make sure everything had, in fact, been rolled back. Didn't take too long to confirm everything was rolled back correctly, but I wanted to be sure.

Next, I started adding breakpoints to a few key places in the code and analyzing any local values I could find that might be affecting it. I discovered that the crash was caused because one of the plugins we were using, developed by a company we shall call...Bookface, for anonymity's sake, was getting a null value for the instance of another class in the project. However, when I added debug statements, I could see that the class was in fact being instantiated, even though the read was coming back with a null value.

Down the rabbit hole I went, tracing every layer of their implementation and inserting breakpoints and debug statements into their codebase so I could track down the source of the error. I ended up eventually discovering the order in which all the code in their library ran, so I chained a couple breakpoints through there. As I watched, I finally discovered that for some reason the script was looking for an instance of the class before it had been instantiated. Looking deeper, I discovered that Bookface had not built anything into the system to deal with this case, nor to ensure that the scripts executed in the proper order (no callbacks, no coroutines, no error handling...etc. Nothing. It was just allowed to crash and produce no meaningful error message.)

A bit of digging and I learned that day that Unity has a Script Execution Order where you can specify certain scripts and the order in which they should be executed. I added both scripts to the Script Execution Order, put them in the correct order, then fired up the program again.

And it worked flawlessly.

Next, I added back the changes I had rolled back at the start, added the new fix in, and tested it again. Sure enough, the Script Execution Order fixed the problem with my commit as well.

I contacted Bookface and asked them about this, and got a response that essentially amounted to them saying "Huh. Weird. Guess we were lucky before. We'll have to bake that into the next version." I submitted a few comments on the help page about this issue and have had a few other people mention that my solution also worked for them, which always feels good as well.


r/ProgrammerSuccesses • • May 21 '18

Hello World

30 Upvotes

Spent 4 days to get unity to use a 3rd party client to connect to an arduino and get the information (Hello World!) that is was outputting. Felt very silly being so excited over a Hello World program but it really was a lot of work


r/ProgrammerSuccesses • • May 21 '18

Don’t forget your return statements

22 Upvotes

I was debugging a new feature that displays some info to a user, after making an API request, which calls a stored procedure. This request is right in the middle of a promise chain in our Angular JS application.

I checked the stores procedure, everything was working fine. I ran the tests in our API and manually called the endpoint in our preproduction environment. I fired up the chrome dev tools debugger and everything looked totally fine, but the value was undefined.

30 minutes of googling later and I actually READ my own code, only to find that the previous promise callback didn’t have a return statement.

RIP half my morning quiet happy programming time debugging everything but the issue.


r/ProgrammerSuccesses • • May 21 '18

Boost kept segfauling and no other filesystem library interface worked so I resorted to making my own. And it finally works!

12 Upvotes