The next 'port sync' will override your local portfile changes. If you want to keep them, you can also copy the port somewhere else, or even set up your own local tree of port files. ('port dir python27' to get the path to the port for copying).
Also, if you fail to update the checksum, port(1) will tell you what it should be (which is how I got the line to use above).
Also, if you fail to update the checksum, port(1) will tell you what it should be (which is how I got the line to use above).