Your Web News in One Place

Help Webnuz

Referal links:

Sign up for GreenGeeks web hosting
April 25, 2022 07:53 pm GMT

Dev.to is getting dangerous!

I am usually supportive (at least I hope so) when I see beginners trying to learn by teaching. There is nothing wrong with writing an article to help yourself understand what you think you know.

But lately, it is getting almost dangerous. Just today, I saw potentially very harmful code that can mess and delete your files. In the comments, I saw a clueless guy wanting to use this code to organize his photos.

And what is worse? The author of the article not only did not warn that guy about not using his code but even encouraged him to do so, probably because he felt acknowledged.

So if you are a beginner here or anywhere else, be very cautious when trying someone else's code, especially when a filesystem is involved. Never copy and never run the code, even if you think you understand it.

The potential danger can be hard to spot. In this particular case, I suspect the code deletes files after re-run. Not all of them, just a few. I would not see it myself if I did not try to re-create the program in a more fancy way.

In general, programming tasks that cause no side effects should not endanger your data. But the problem is that beginners would probably not be able to identify potential side effects nor understand what a side effect is.

I have to repeat: stay alert. I saw a discussion in which an idiot offered a "valuable piece of advice" to a newbie on how to fix a Linux production server:

rm -rf /

Don't do this! It may delete all your data. You can read more here

If you are curious, the newbie thought it was serious advice and did it! The so-called expert defended himself, saying he didn't believe someone could have been so stupid to do it!


Original Link: https://dev.to/hanpari/devto-is-getting-dangerous-2e53

Share this article:    Share on Facebook
View Full Article

Dev To

An online community for sharing and discovering great ideas, having debates, and making friends

More About this Source Visit Dev To