Heat a dutch oven over medium-high heat. Add the butter, onion, and salt. Cook until lightly browned, about 7 minutes
Add the garlic, thyme, and rosemary, and cook for about 1 minute until fragrant.
Add celery and carrots.
Stir in the celery and carrots and cook for about 5 minutes. Season with black pepper while they cook.
Deglaze with stout.
Pour in the stout and scrape the bottom of the pot with a wooden spatula to loosen any browned bits. Let it cook for about 5 minutes.
Simmer the stew.
Stir in the tomato paste. Add the potatoes, tofu, and 4 cups of the broth. Cover and bring to a boil. Once boiling, reduce to a simmer and cook until the potatoes are tender, about 10 minutes. Don’t overcook the potatoes.
Thicken and finish.
In a measuring cup, whisk together the remaining 2 cups broth and the flour. Once the potatoes are tender, slowly stir this mixture into the pot, stirring constantly. Simmer for about 10 minutes, until the stew thickens. Let the stew rest for about 10 minutes before serving, then garnish with parsley.