In a large sauté pan over medium heat, melt the butter. Add the sliced onions and cook until they are soft and caramelized, about 15-20 minutes. Stir frequently to avoid burning.
Once the onions are caramelized, add the minced garlic, sugar, salt, pepper, and dried thyme. Cook for an additional 2 minutes until fragrant.
Transfer the onion mixture to the crock pot. Pour in the beef broth and white wine. Stir gently to combine.
Cover the crock pot and cook on low for 6 hours, allowing the flavors to meld and the soup to develop a rich taste.
When ready to serve, preheat the oven to broil. Ladle the soup into oven-safe bowls and top each with a few slices of baguette.
Sprinkle Gruyère and Parmesan cheese generously over the bread. Place the bowls on a baking sheet and broil in the oven for 2-3 minutes, or until the cheese is bubbly and golden.
Carefully remove from the oven and let cool slightly before serving.