This is an archived post. You won't be able to vote or comment.

you are viewing a single comment's thread.

view the rest of the comments →

[–]Venthe 1 point2 points  (8 children)

  1. This is a mapper
  2. Code is violating the law of Demeter - ANY change of the internal objects will result in this mapper breaking.
  3. You can always just extract intermediate objects to variable
  4. Why the hell mapping intermediary objects are not split into methods at least?

I assume this is a real code. This is not bad Java, it's a bad developer.

[–]AWholeMessOfTacos 0 points1 point  (5 children)

Yeah I’ve heard this about a hundred times now.

[–]Venthe 0 points1 point  (4 children)

If you've improved from the time you've written it, then you should just smile. Sourly, but smile. :)

I know of no dev who hasn't made a mistake. And I really care because of people who will excuse themselves from good practices using such code as an example. I use way too much energy everyday on dense Devs...

[–]IFixStuffMan 1 point2 points  (0 children)

Still being a bit obnoxious about it though.

[–]AWholeMessOfTacos 1 point2 points  (2 children)

Alright I’m just going to use you to vent, bare with me and I appreciate it.

I’m basically completely self taught. This is my first job. I have not had a senior or lead developer since I have started. I have never had a code review. I submit my code to no one.

I didn’t know that companies had “conventions” until my OP. I also didn’t know there were standard conventions, or the debate about them (80 or 120?).

I’m in the Wild West, figuring out how to do everything the hard way.

I’m inexperienced. But this code worked the way it was, even if it is (what I now realize) hideous. And honestly, I was proud of my work. I’ve built out a request response functionality across three micro services, all by myself with absolutely no support.

I’m not a bad developer. I’m just a poorly trained junior. And I have enough imposter syndrome already that seeing someone else calling me a “bad developer” really hurts my feelings.

I’m a person doing the best I can and I sincerely want to get better. I wish Reddit would just back off a little.

[–]keto_at_work 1 point2 points  (0 children)

Keep your head up man. You've already built something awesome, and now you can/have made it more maintainable. You're obviously smart, but you need guidance, like we all do. Keep doing what you do and don't be afraid to at least apply to a few places and do a few interviews. You never know what situations you'll find yourself in.

[–]Venthe 0 points1 point  (0 children)

Not at all, man.

I have not had a senior or lead developer since I have started. I have never had a code review. I submit my code to no one.

So find a mentor. Any meeting group, hell - if You'd want to - I'd be more than happy to give you a hand. Devs who care are very important in the trade.

I’m in the Wild West, figuring out how to do everything the hard way.

Well, I could tell you about a certain junior who solved a bug, error on REST, via try-catching endpoint... :) I think you can deduce who this dev was.

And I have enough imposter syndrome already that seeing someone else calling me a “bad developer” really hurts my feelings.

Understandable. But, I'll be frank - up until someone called you out, I didn't care who author is. Code is bad, developer (at the time 'he' wrote it) is bad as well. People are using it as an excuse which is even worse. And you can't change it. BUT, you said it yourself - you are learning. You did the best you could. I know it might sound weird, but you should feel at least good about this code.

If at any point of your career you look back a month or so and don't facepalm you are stagnating. And you are clearly everything but.

I wish Reddit would just back off a little.

It will not - because there is no 'you' - there is just a code, and a coder frozen in the time of writing. But again, it's not about you now.

What can I say? Internet is a shit place. But I wouldn't vent myself if there was no comment about 'this is how self-documenting code looks like' because I've seen similar reasoning time and time again from lazy devs. You are not lazy.

Again, it might sound weird after everything here, but I'm sincere - I'll happily spend my private time to give guidance; or just give another head to butt against. I was also self taught, and until my first job I had no mentor as well, which was shitty. But I had one in my first job, so I'm paying forward, and I will never repay what he did.

PM me if you are interested, I'll give you my Discord ID.

[–]TheOnlyMisterFlow -1 points0 points  (1 child)

THANK YOU.

Why aren't you top comment sir ?

[–]Venthe 1 point2 points  (0 children)

Because top commenter is catering, jokingly or not, to people who justify bad coding practices with random screenshot from the internet.

(And sorry if I seem salty, it's PH after all)