All the ratsnakes can musk, but they chiefly do it when frightened/agitated. Most CB ratsnakes (including corns) seldom if ever musk, especially if handled from a young age...but there are always individuals who are more nervous or just more prone to any given behaviour than other, even among generally placid species. On the other hand, the more high-strung species, such as the Beauty snakes, are more likely to musk.
I believe the same goes for most snake species - in fact, I think all. Milks, Beauties and a couple of other rats, grass snakes, and garters are especially reputed for it. I have not seen (smelt) a python or boa musk, and they're not generally known for it in the same way as some of the the colubrids (and it's reputed to be somewhat less offensive on the rare occasions that they do it); but they are both perfectly capable of musking when sufficiently frightened or startled or whatever.
If this is a major concern for you, I'd suggest getting a more mature snake of one of the smaller python or boa species from a well-reputed private breeder who has had plenty of time to observe the individual and can confirm accurately to you that the snake has no personal history of musking. This will not guarantee that your life stays 100% musk-free, as there is always the chance of a nervous transition period when you move a snake to a new home; but it will at least reduce the likelihood to about as minimal as it can be if you're going to keep a snake at all.