Whole bean coffee is packaged loose and hasn't been vacuum sealed by design. Once roasted, coffee beans will naturally release gases even while sitting unused. Most bags feature a small, one-way “breather valve” that allows air to escape the packaging. This can result in a puffed up bag as these gases build.
The video below goes into even more detail on what the one-way valve does and looks like in quality whole bean and pre-ground coffee bags.
What's That Thing In My Coffee Bag?
One-way valves are installed on bags of coffee because coffee beans continue to release CO2 (carbon dioxide) after they are bagged. The one-way valve allows this excess off-gassing to escape. Without the one-way valves, the bags would be prone to exploding in transit, as the off-gassing produces a significant amount of pressure, and can burst the bag, while in transit or storage. The rigors of shipping can press these gases through the valve such that the bag arrives in a tight, brick-like form. Rest assured that these gases will not adversely affect the quality of your drinks.
You can test this by squeezing the bag, and releasing all the air that you can. Air will come out of those two vents, but if you leave it sitting on the counter, air will not go back into the bag. Try it out!
Watch the video below for more information on why your coffee bag can sometimes get puffed up.
How To: Coffee Packaging - Why is it Puffy or Not Puffy?