G. Gordon Liddy, the convicted Watergate conspirator who is scheduled to be released today after more than four years in prison, narrowly missed losing his parole in a dispute over the weekend among federal pardons officials.

Liddy, who elected to remain defiantly mute and serve the longest sentence so far - 52 1/2 months - of anyone connected with the Watergate affair, was to be granted his freedom from the federal medium-security penitentiary at Danbury, Conn.

Yesterday, Liddy swore before U.S. Magistrate William Askey in Williamsport, Pa., that his a pauper with less than $20 to his name, a move that cleared the way for his release despite a $40,000 fine hanging over his head.

Askey noted that Liddy will eventually have to pay the money. "The debt is not forgiven," he said, "just the imprisonment."

Liddy, in a brown sports coat and with shackles around his waist and wrists, refused to comment to reporters on his way to the hearing.

Liddy, 46, received his parole in July after a 3-to-1 vote in his favor by the appeals board of the U.S. Parole Commission. The board made its decision after President Carter in April reduced Liddy's sentence for engineering the Watergate break-in from a 20-year maximum to eight years. That left Liddy open for parole after July 9.

Last week, however, knowledgeable sources said several members of the parole commission changed their minds about allowing Liddy to go free. Members began circulating a petition to reconsider Liddy's case because of an incident last month involving the discovery of several weapons in Liddy's prison living area.

Officials at the federal prison camp at Allenwood, Pa., found a 14-inch length of pipe and a club made from a sickle handle in Liddy's bed. The discovery was made as Liddy and other prisoners were being transferred from Allenwood to another federal prison following their part in a hunger strike.

According to federal law, a prisoner found with a weapon in a federal prison can get as much as 10 years added to his sentence. In Liddy's case, however, regional parole commissioner Joseph Mardoza ruled Aug. 29 that Liddy had kept the weapons in self-defense and that his parole would go through.

Federal parole commission sources noted, however, that Liddy's prison record was marred by other incidents.

They said any other prisoner would have at least had his parole reviewed after a similar weapons discovery.

"There was no question in some of our minds that the Liddy case was being handled differently than any other case of its kind," said one commission member who declined to be identified.

Acting under a new parole commission rule, three of the seven members last Friday sought to have Liddy's case formally reopened. A reopening would have automatically delayed parole for Liddy by 30 days or more during the review, according to commission officials.

All seven members were polled by telephone by acting chairman Curtis Crawford over the weekend. The commission voted 4 to 3 against reopening the case, according to commission sources. CAPTION: Picture, Liddy: pauper's oath hearing clears way for his release despite $40,000 fine. AP