Basically anything microscopic is increasingly found to be just horrible to inhale, but this blurb from Wikipedia says there are probably significantly worse things to handle for a one-time treatment.
...In a 1978 study of workers, those exposed to natural diatomaceous earth for over five years had no significant lung changes while 40% of those exposed to the calcined form had developed pneumoconiosis.[46] Today's common diatomaceous earth formulations are safer to use, as they are predominantly made up of amorphous silica and contain little or no crystalline silica.[47]
The crystalline silica content of diatomaceous earth is regulated in the United States by the Occupational Safety and Health Administration (OSHA) and there are guidelines from the National Institute for Occupational Safety and Health that set maximum amounts allowable in the product (1%) and in the air near the breathing zone of workers, with a recommended exposure limit at 6 mg/m3 over an 8-hour workday.[47] OSHA has set a permissible exposure limit for diatomaceous earth as 20 mppcf (80 mg/m3/%SiO2). At levels of 3,000 mg/m3, diatomaceous earth is immediately dangerous to life and health.
In the 1930s, long-term occupational exposure among workers in the cristobalite diatomaceous earth industry who were exposed to high levels of airborne crystalline silica over decades were found to have an increased risk of silicosis.[49]
Yes I'm not saying it's going to cause long term damage to your lungs, it's probably pretty safe, but it doesn't feel great if you inhale it, and it's easy to avoid if you just put on a mask or spray and move away.