The open permit should be closed. Upon the discovery of an open permit before the completion of the purchase, you will not have any title insurance coverage over this issue. Additionally, you will be put at risk by the open permit because it will allow the City to inspect the premises at any time and to issue a work order with which you would be legally required to comply. This in turn will give rise to the risk of litigation and may affect your right to use and enjoy the property.