I don't think the quality of the source material, or in this case the quality/lack of story, automatically suggests that it can't make for a good film. You can still attempt to tell a compelling, enjoyable narrative even if you don't have a lot to work with (a casual reminder that the Shawshank Redemption is based on a short story, and is considered a classic). Heck, even if you don't wanna focus on the narrative and want to go for doing what the games do, you can still make a well-crafted film that echoes the series' appeal through a new medium.
A pretty well-known example of the latter would be the Street Fighter II animated movie produced in 1994 by Group TAC and directed Gisaburō Sugii (the same man who also directed Night of the Galactic Railroad, believe it or not). Street Fighter is not typically known for its plot, but the movie gets away with it by instead focusing on having a variety of well-made, enjoyable fights that each have their own unique vibe and pacing (Chun-Li fighting against Vega's a classic, even amongst people who dislike the film). It doesn't have much of a story beyond whatever's needed to get certain characters to fight each other, but it doesn't really matter when it pulls off the fight scenes as well as it does.
And I think it's absolutely possible for the same to apply to Sonic. No, the games themselves have never cared too much for plot (or a consistent universe and characters, which is something I'd argue is a good thing but that's a whole other topic), but that doesn't mean a film based on them has to rubbish. It can tell a good story that hits all the right beats and accomplishes what the developers would never set out to do; it can make a shallow but well-made action film that nails what fans love about the series; it can do both, or it can do something else altogether to make a good film.
While it can be difficult to make a good Sonic film, that's only because it's difficult in general to make a good film about anything - especially when it's adapting a work from one medium to another. But I know it can be done, and the issue is that the approach being taken with this film; the live-action/animation hybrid, the hyper-realistic CGI, the return to the "Sonic in a world of humans" nonsense that's been divisive at best and loathed at worse; is one that will more than likely result in a mediocre nothing of a movie that will be forgotten in years' time. I'd rather we get a good movie that shows what people love about Sonic, and is at the very least a well-made film that can appeal to everyone just through pure filmmaking craft (I'm not a superhero nut, but at least Into The Spider-Verse understood that and make a technically brilliant film).