and of course mafiosos are or can be anti-heroes; that is, complex human beings with complex motivations.
criminals, believe it or not, are real people with complex stories. you want to dismiss any mafioso as a 'thug' and then shut the book. you sound like an old testament-toting american. that sort of black-and-white manicheanism is not how reality, or the individuals who people it, work. very few people are 'pure evil' or 'simple thugs', and the characters in the sopranos are precisely the sort of everyman thrust into a life of crime, not unhinged serial killers.
that's rather the whole point of my drawing comic movies into the comparison. sopranos, despite the aforementioned cartoonish first season, which was more 'grand theft auto' than the 'magisterial survey of american society' that it became, at least tries to get at reality, you know, the STUFF of human beings and their actions. it's tragi-comic and the main characters are exactly anti-heroes.
this is why there has always been an interest in crime fiction or mafia books, at least for a certain high-brow type, who want to examine human behaviour and the underworld lives of criminals. it is an enduring topic of interest and is so much more than just 'glamorizing violence'. what a lack of imagination you have. transgression is a fascination as old as the world religions.
you are, really, two steps away from the 'watching/playing/reading x/y/z makes people violent' argument, which is tendentious at best. nobody wants to be tony soprano. he is a sociopath who practically loses everyone close to him and (probably) ends up dead. not exactly a ringing endorsement.
and, ironically, the show is so well-written that it even pre-empts your critique: the characters in the show are literally rinsed in mob media. they are forever joking about mob movies, and one of them even tries to write a script for one. they end up making a clownish Saw-like movie about a thriller-killer. the show literally deconstructs the very arguments you are trying to make. 'lazy writing'. fail.