The councils, and each branch thereof, of any borough, or of any city of the second or third class, within this commonwealth, shall have power to compel the attendance of witnesses, and the production of books, papers and other evidence, at any meeting of the body or any committee thereof, and for that purpose may issue subpoenas, signed by the president of council or the chairman of the committee, in any pending case of inquiry, investigation or impeachment, and cause the same to be served and executed in any part of this commonwealth; and if any witness shall refuse to testify as to any fact within his knowledge, or to produce any books or papers within his possession or under his control, required to be used as evidence in any such case, the clerk of that branch of council, by whose authority such witness was subpoenaed, shall forthwith report the facts relating to such refusal to one of the courts of common pleas of the county within which such borough or city is situated; and all questions arising upon such refusal, and also upon any new evidence, not included in said clerk's report (which new evidence may be offered in behalf of or against such witness), shall at once be heard by said court. If the court determines that the testimony or evidence required by such witness is legal and properly competent, and ought to be given or produced by him, then said court shall make an order commanding such witness to testify or produce books or papers (or both, as the case may be), and if such witness shall thereafter refuse to testify or to produce books or papers, as aforesaid, in disobedience of such order of the court, then the said court shall have power to order the commitment of such witness to the county jail of the proper county, for contempt.
53 P.S. § 22239