Live data from Hacker News

Deleting 50k Lines of Code in 3 Days

aakashns.com

1–10 of 62 posts

Re: Deleting 50k Lines of Code in 3 Days

#3
> While I knew that some pages were less frequently visited than others, I was surprised to see that there were modules that accounted for less than 0.1% of page visits. This meant I could remove them entirely without affecting 99.9% of users. I could delete entire directories containing dozens of files and thousands of lines of code.

I don't know about the author's application, but a data driven approach is not going to give good results. In my podcast hosting software, the "delete podcast" button is used maybe once every other week (by the numbers). But if I got rid of it, I'd be fielding support requests for every user who wants to delete a show. And that's a highly manual cleanup process to do by hand.

Which is to say, features don't need to be a high percentage of traffic to be important.

Re: Deleting 50k Lines of Code in 3 Days

#6
> modules that accounted for less than 0.1% of page visits. This meant I could remove them entirely without affecting 99.9% of users.

No it doesn't, these are different metrics, same user that does those 99.9% visits could once in a blue moon want to visit a very important page, and be negatively affected. And this could (in theory) be the case for every single user

The Word screenshot is another illustration of the misplaced nature of this criticism: you wouldn't enable all of those toolbars in reality to obscure everything! If you wanted something, the beauty is you could just drag a needed button from a toolbar to a more condensed version

Or enable a toolbar for when you needed it, and then disable it

Re: Deleting 50k Lines of Code in 3 Days

#7

> While I knew that some pages were less frequently visited than others, I was surprised to see that there were modules that accounted for less than 0.1% of page visits. This meant I could remove them entirely without affecting 99.9% of users. I could delete entire directories containing dozens of files and thousands of lines of code. I don't know about the author's application, but a data driven approach is not goin…

If you could somehow track the frequency spectrum of usage, then you could mostly handle that problem. "Oh, the frequency spectrum strongly peaks at about once a week? I guess users regularly need to use this feature. Probably important somehow." vs "Huh, the frequency spectrum isn't strongly peaked anywhere, but is substantially lower at high frequencies. We can probably remove this."

Re: Deleting 50k Lines of Code in 3 Days

#9
post #5
post #2

I accidentally imported a 3rd party library twice. Deleted the extra. Got a nice badge for deleting over 500k lines of code.

Is it a common practice to commit dependencies into the project repo? If so what type of projects do that?

I think projects in C would be a good contender here.

Re: Deleting 50k Lines of Code in 3 Days

#10
post #5
post #2

I accidentally imported a 3rd party library twice. Deleted the extra. Got a nice badge for deleting over 500k lines of code.

Is it a common practice to commit dependencies into the project repo? If so what type of projects do that?

Common? Perhaps in less than ideal or legacy situations. Best practice, definitely not.

A lot of website projects I have worked on in the past included composer or node dependencies in the repository. It really slows down the whole git system.

Post reply on HN