Bring a large pot of heavily salted water to a boil and cook the penne until just al dente according to package directions; reserve 1/2 cup pasta cooking water, then drain the pasta, rinse with cool water, and toss with a drizzle of olive oil. Set aside.
While the pasta cooks, heat 1/4 cup olive oil in a large saucepan, braiser, or Dutch oven over medium-high heat.
Add the diced onion and sauté until softened, about 5–7 minutes.
Add the minced garlic and crushed red pepper flakes (start with less if desired) and sauté for 1 minute more.
Stir in the tomato paste and cook for 1 minute to deepen the flavor.
Add the can of whole tomatoes with their juices, breaking the tomatoes up with your hands or a spoon; stir in the dried oregano, thyme, and salt.
Bring the sauce to a vigorous simmer, then lower the heat to maintain a gentle simmer and cook, occasionally mashing the tomatoes, for 15–20 minutes until slightly reduced; add reserved pasta water a little at a time if you prefer a thinner sauce.
Stir in the minced fresh basil and parsley, then add the drained pasta to the sauce and toss to combine. Adjust seasoning with salt, pepper, a pinch of sugar for sweetness, or extra red pepper flakes for heat.
Serve immediately with plenty of freshly grated Pecorino Romano or Parmesan cheese.