You’re right—humidity is the enemy of candy makers. In the perfect candy-making climate, relative humidity is less than 35 percent. If you live in an area where it is seldom that dry, consider using your air-conditioner or a dehumidifier for a day or so before you make candy.
Since excess softness in candy is the result of high relative humidity, you can also cook hard candies, such as peanut brittle, to 2 degrees higher than the temperature your recipe calls for. The additional 2 degrees in cooking temperature will compensate for the moisture in the air.