I see this frequently, and fall for it still myself: just because what you’re looking at has a label that suggests it is something or does something or represents something, you should still check that it really is the case if what you’re doing depends on it.

A couple of examples:

  • when a list of user records you have pulled from your server contains one labelled JamesThomas it does not necessarily mean that I have an account on your server or even that anyone called James Thomas has an account on your sever or, even if they do, that it is active or valid or has other properties you’re interested in.
  • when you’re using a test object named x_4_y_5 it does not necessarily mean that it encodes the obvious variable assignments and, even if it once did, you might want to avoid assuming that no-one edited it to have some other values because it was a convenient way to run their quick test.
  • when you find a script called clear_down_safe.sh in the test data directory it does not necessarily mean that it will delete all and only the test run data that you would like it to. 

The label is not the thing. The label is not the thing. The. Label. Is. Not. The. Thing.
Image: Public Enemy
Lyric: Rebel Without a Pause