You can eat it, but it cannot completely replace the staple food. Because most pumpkins have low starch content and soluble sugar content, they can't reach 10% carbohydrate content, which is lower than that of potatoes and sweet potatoes with nearly 20% carbohydrate content. So if they are used instead of staple food, the starch is not enough and the calories are too low, which is equivalent to dieting in disguise.
Secondly, the protein content of pumpkin is low, so it is difficult to replace the daily protein provided by staple food (usually up to 20-30g). This can easily lead to malnutrition in protein.
Moreover, there is too much carotene in pumpkin, which can easily lead to yellow skin if eaten in large quantities every day. Although it is not toxic, it will recover after you stop eating it.
Steamed pumpkin can replace one third of the staple food for dinner. It can increase the supply of potassium, vitamin C, carotene and pectin, which is beneficial to prevent constipation and obesity.