I am reading through "Making games with Python & Pygame" and I have noticed that because the author uses lots of functions with drawing in to break his code up, he uses lots of globals  such as GRIDSIZE or BACKGROUNDCOLOR. I was always told that globals were generally bad, but without them, every drawing function would have ten more, repeating parameters - and I have also been told that repetition is bad. I wondered, then, is the author is correct in using globals for parameters that appear in most (drawing) functions, or should have just used more, repetitive parameters.
Example code in books is not the same as production code
Code in books and articles explaining things do things to keep to the point and not inundate the reader with what might be noise or tangents to the specific topic.
The author is taking short cuts to keep the code as specific to the problem they are explaining as possible.
That said, there are better ways to do what they are doing than using module level variables. Even in books and tutorials.
Huge State Machines are Bad
Variables that encompass too much scope, no matter what level they are at, tend to have the side effect of creating invisible side effects that manifest themselves from the huge state machine that the application becomes.
Excessive parameters to functions is a code smell
It should tell you that you probably need to encapsulate your data better. Multiple related parameters should be grouped into a single data structure and just pass that single data structure as a parameter.
Globals vs Parameters for Functions with the Same Parameters