Put the beans in a medium saucepan, then add water, the carrot, the celery, and one chopped slice of onion.
When the water begins to boil, add the salt.
Cover the pot and cook for about 45 minutes.
Sample the beans, checking for doneness and for salt; when they are ready, season with more salt if necessary.
Drain the beans and reserve the cooking water; set both aside.
Mound the flour on a kitchen work surface and make a well in the middle.
Pour the water and salt into the well.
Begin to incorporate the flour, starting with the inner rim of the well.
When all the water has been absorbed by the flour, start kneading with your hands. Note that this can be challenging, because the dough is quite hard to work and tends to crumble. To make it easier, pick up the little pieces of dough and, with the help of a little bit of water, incorporate them using the palm of your hand until the dough becomes a cohesive mass.
Divide the dough into six pieces.
Dust the work surface with flour, then take one piece of dough and push down on it with the palm of your hand.
Set the pasta machine’s roller at its widest setting. Feed the dough through the roller, then fold the strip into thirds and continue feeding it at the widest setting until the dough is smooth and has a perfect rectangular shape.
Now set the pasta machine’s roller at position 2, then feed the strip of dough through once again.
Dust the work surface with flour and let the dough rest.
Process the other five pieces of dough in the same way as the first.
Let the pasta strips dry for about 20 minutes.
Take a strip of dough and divide it into three lengthwise. Dust the strips with flour and place them on top of one another, cutting the sagne into strips from the shortest side. Size should generally be 1 cm in width, 6-8 cm in length, and 1.5 mm thick.
Place the sagne in a large tray dusted with flour and set aside.
Sauce and dish preparation
Wash and peel the tomatoes, then remove and discard the seeds. Cut the flesh into very small pieces, place them in a bowl, and add a pinch of salt.
Heat olive oil and garlic in a large saucepan on low, then add the bacon.
Remove the bacon when it is crispy, then add the remaining slice of chopped onion.
Remove the excess water from the bowl of tomatoes, then add the tomatoes to the pan with the onion.
Continue to cook for about 10 minutes.
Add the beans and a ladle of the beans’ cooking water. Continue cooking for about 10 minutes.
Remove the pan from the heat.
Bring water to a boil in a large pot, then add salt and your homemade sagne. Stir gently.
Bring the water back to a boil for two minutes.
Taste a piece of pasta to check if it is al dente, and when the pasta is ready, drain it and place it in the saucepan with the beans, onion, and tomato.
Add another ladle of the beans’ cooking water. Cook and stir for a few minutes, adjusting the consistency to your liking.
Add the bacon and drizzle with a robust extra-virgin olive oil.