Heat the olive oil and butter in a large pot over medium heat.
Add the sliced onions and sugar, stirring occasionally until onions are caramelized and golden brown (about 25-30 minutes).
Add the minced garlic and cook for another 2 minutes.
Sprinkle the flour over the onions, stir well, and cook for an additional 2-3 minutes.
Pour in the white wine to deglaze the pot, then add in the beef broth, salt, and black pepper.
Reduce the heat and simmer for 30-40 minutes.
While the soup simmers, preheat the oven broiler, and toast the baguette slices until golden brown.
Ladle the soup into oven-safe bowls, top each with a slice of toasted baguette, and generously sprinkle with Gruyère and Parmesan cheese.
Place the bowls under the broiler until the cheese is melted and bubbly.