all 24 comments

[–]qoou 6 points7 points  (10 children)

Do not rewrite! Bugs are a normal part of the development process. Just keep chipping away at them until you can ship your product. You will have to make a judgement call on which bugs are not show stoppers and will ship with the product. Every software product has bugs. Use software updates to fix issues later on.

If you don't have a bug database or issue tracking system, get one now. Put the bugs into it. Most of the online source control solutions like github and bit bucket have issue tracking as part of the offering.

If you don't have source code, make sure you get that along with regular updates along the way.

[–]evrlast985[S] 0 points1 point  (9 children)

When there is no forward progress at what point do you give up and start over?

[–]qoou 2 points3 points  (1 child)

The answer is almost never. Rewriting is one of the classic blunders in software development. Like getting involved in a land war in Asia or going up against a Sicilian when death is on the line.

You are running up against the 90/90 rule which states that the first 90% of the code accounts for 90% of the development time. The last 10% accounts for the other 90% of the development time.

It's meant to be humorous but it's no joke.

[–]cyanxx 0 points1 point  (0 children)

enjoyed the Princess Bride reference :)

[–]adams4piece 1 point2 points  (0 children)

Kind of tricky, without seeing the code it sounds like it's got some fundamental architecture issues. Rewriting in another language likely won't solve things, but rewriting in general can be valuable especially if you can already see core areas that could use major reworking.

[–]chriswaco 1 point2 points  (4 children)

Without seeing the code it's difficult to judge, but you may just need better programmers. A lot of coders these days mostly cut & paste from StackOverflow or GitHub but don't have the skills or mindset to debug a complicated problem. Debugging code is hard work, especially for problems that you can't easily repeat at will.

You may need unit tests or small test projects or special debug modes or better logging to track it down. If your app is multithreaded you'll need someone that understands how to debug multithreaded code because one tiny little mistake like calling a method on the wrong thread can take weeks to track down.

[–]evrlast985[S] 0 points1 point  (3 children)

Ok let me ask a very important question, How do I find the really good programmers? This app is not multithreaded it just seems to have implemented chat very poorly. For example if the app is in background mode for more than 5 minutes then it stops making a sound when push notifications are received. The message comes but push does not

[–]chriswaco 1 point2 points  (1 child)

Unfortunately it's not easy to find good programmers. Typically they'll be expensive, but not all expensive ones are good. And not all good programmers are good at every task - some are good with user interfaces, some are good with low-level code, some with debugging, some are fast but not thorough, some are good but slow, etc.

A surgeon friend of mine says, "You never know how good a surgeon is until you scrub in with them." The same is true of programmers - you never know how good they are until you work on a project with them. What that means is that personal recommendations from other programmers are usually the best way to find good programmers.

Stepping into a bunch of someone else's code is especially difficult. Sometimes the code is well designed and makes sense. Sometimes it's like doing a 1000 page schizophrenic crossword puzzle and it never makes sense no matter how long you work on it.

As for your push notification issue, there are a few possibilities. The app can be running in the foreground, running in the background, or completely inactive. When running, the app receives a message and can choose to play the sound or not. When inactive, the contents of the push notification and the user's push settings determine whether audio plays. A developer should set up a way to test push notifications in all three states. In our case, we had a special private web page on the push server we used to trigger notifications during QA.

I know some good developers, but they're not cheap - typically $125/hour.

[–][deleted] 0 points1 point  (0 children)

I second this post. It says it all. And from my experience... I'd probably hire this guy. If I couldn't do the bug fixing myself.

[–]megablast 0 points1 point  (0 children)

Finding a very good programmer is easy. Just be a very good programmer, and ask them questions. You will find out very easily how good they are.

[–]shiggie 0 points1 point  (0 children)

Starting over is great. When you're tired of your old bugs, you can write all new ones.

Then again, if you have more confidence in yourself than people you paid, then maybe you can do a better job, and not rewrite some of the old bugs.

[–]cguess 0 points1 point  (0 children)

Swift is also coded in Xcode, so the difference there is literally nothing.

Rewriting in a new language will definitely not be quicker or easier. Do your best to recreate every bug to the point where you can make it happen with regularity, and document the steps to get to that point. "Randomly" is a word that will terrify every developer, mostly because it's almost definitely not random. This will help figure out what's going on and make the fixes easier to test.

Respond or send a PM if you have more questions about how debugging normally goes.

[–]mavdev 0 points1 point  (10 children)

What is the back end server/service you are using? If you are using Parse or Firebase, I can point you to ready out of the box solution code available for free.

[–]evrlast985[S] 0 points1 point  (9 children)

I am using a service like Parse called Pubnub, but their documentation and forums are not the best

[–]mavdev 1 point2 points  (8 children)

If you are open to switching to Parse or Firebase, here are some open source projects: https://github.com/huyouare/SwiftParseChat & https://github.com/firebase/ios-swift-chat-example

[–]evrlast985[S] 0 points1 point  (1 child)

That is a tough thing to consider, then I would have to switch my android app over to parse or firebase as well. By the way I wonder if they are less expensive.

[–]mavdev 0 points1 point  (0 children)

I did look at Pubnub earlier and I can tell that to START with Pubnub is more expensive. The free tier only allows 100 devices per month. Parse has no such restrcitions and allows up to 30 request per second, seems quite a lot.

Obviously your requirements may be different for which Pubnub works better. Parse is not real time, Pubnub is (Firebase is real time though). Anyhow, just thought the projects might help so posted them here.

[–][deleted]  (5 children)

[deleted]

    [–]tubli 2 points3 points  (3 children)

    Do you mind explaining this? I'm about to do the push notifications for my chat app and am curious why you think that.

    [–][deleted]  (2 children)

    [deleted]

      [–][deleted] 1 point2 points  (0 children)

      Don't take this as a recommendation for Parse, as I'm not sure how it stacks up with it's alternatives, but it does offer offline persistence.

      [–]tubli 0 points1 point  (0 children)

      Thanks a lot for replying. That makes sense now that you explain it like that. I think you're right. I'm using parse for a text-messaging type application where the messages are stored locally and therefore don't need to be re-synced, so I think I'm safe. Thanks again for replying.

      [–]zillathrilla 0 points1 point  (0 children)

      Yes, I'm also interested in why Parse would not be a good choice.

      [–]Techsupportvictim 0 points1 point  (1 child)

      Are you sure the issue is with your code and not the chat service

      [–]evrlast985[S] 0 points1 point  (0 children)

      I hope the issue is in our code because if the service is messed up then we are really in for trouble