Is a palette just a bunch of pretty colors?

If a platform provides a general purpose palette, are there any rules for what the palette aught to contain?

For example, imagine we're designing a fantasy console that uses an 8-bit (indexed) palette. The user will have access to (virtual) sprite chips, tiling chips, a textmode chip et cetera, which all use the same 256 colors.

As a programmer, it's tempting to try and logically divide the RGB spectrum into 256 equidistant points. That would cover all of the obvious requirements, like having a good range of colors, and a full set of grays, and there's an elegance to a palette that can be described in one or two lines of code. However, I'm worried that that approach may be too simplistic.

When designing palettes for general purpose pixel art, are there any rules, technicalities, pitfalls or anything else to be mindful of?

No, pixel art palettes have a much more specific purpose. They are generally made of of "ramps", which is a set of colors you can use to shade a single hue.