The Senate last night passed a "sunset bill" providing for the automatic expiration of all government spending programs every 10 years if they are not reauthorized - a symbolic end-of-session action in which the House apparently will not concur this year.

Struggling with another piece of symbolic legislation, a group of senators failed to come up with a compromise on the Humphrey-Hawkins bill, legislation intended to commit the federal government to a policy of full employment. Last night the prospects for that measure looked dim.

The sunset bill, a project pressed for years by Sen. Edmund S. Muskie (D-Maine), was adopted by an over-whelming 86-to-1 vote. Just a day earlier Muskie was pessimistic about getting a vote on the measure in the rush to adjourn, but in fact he had plenty of time yesterday because the Senate suspended all other work while awaiting a Humphrey-Hawkins compromise that was not forthcoming. Indeed, the Senate spent much of the day, in what is supposed to be its most hectic period of work in recess.

Sunset legislation is tied up in the House, and will not come up for a vote there this year, according to congressional sources.

The Senate bill would require reauthorization of all government programs on a prearranged 10-year schedule. Its backers call it a way to allow ineffective programs to lapse, with a possible savings of enormous sums for taxpayers.

Sen. Charles H. Percy (R-Ill.) added an amendment to the measure yesterday extending its application to legislation establishing regulatory agencies as well as spending programs.

In a floor speech, Percy called the sunset bill a reasoned, sensible response to the tax revolts occurring all over the country, because it offers the prospect of eliminating non-productive government programs in the years to come.

The Perils-of-Pauline course followed by the Humphrey-Hawkins legislation over the last several years continued yesterday, with heightened prospect that the legislation may finally fall over the edge of a congressional cliff.

The bill already diluted to a wafery state in successive committee actions - came up in the Senate with unexpected ease Tuesday night, after Senate Republicans decided they would rather not rake the blame for blocking the legislation.

According to several sources, key Republicians decided they should look for an accomodation on Humphrey-Hawkins to placate its most ardent supporters, particularly members and allies of the Congressional Black Caucus. So they proposed that proponents and opponents of the measure seek a compromise.

The idea was to rewrite the bills so that its targets for meeting full employment would be matched by targets for reducing the rate of inflation. Conservatives argued that this would emonstrate that Congress did not intend that Humphrey-Hawkins become an excuse for big new spending programs. Friends of the bill said the inflation goals would only confirm the practical meaninglessness of the legislation.

The Senate majority leader, Robert C. Bryd (D-W.Va.), made it clear to supporters of Humphrey-Hawkins that he saw little if any chance to cut off a filibuster at this late stage in the session. (The Senate is hoping to adjourn Saturday.) If the Senate did vote cloture, cutting off debate, opponents of the measure could still adopt delaying tactics after that vote that could drag out proceedings for many days.

That means the bill's s proponents had to choose between abandoning the legislation or "satisfying bill's principal opponents," as one union lobbyist put it. "There's no umbrella big enough" to cover both the bill's original proponents and its critics, this man argued.

Others sympathetic to Humphrey-Hawkins disagreed, saying that even the version of the bill its supporters favored was only a symbolic gesture, so they ought to accept a compromise version that would also have symbolic value.

At a meeting yesterday morning of the ad hoc group of senators seeking a compromise, Sen. Gaylord Nelson (D-Wis.), angrily told representatives of the AFL-CIO and the United Auto Workers that they ought to accept a compromise including inflation targets as well as employment goals. The labor representatives disagreed.

A second meeting of the ad hoc group produced what Sen. Bob Dole (R-Kan.), a participant, called "good progress," but informed sources said the nature of the emerging compromise apparently did not satisfy Humphrey-Hawkins' sponsors.

A key sponsoring group, the full employment Action, Council, which includes representatives of organized labor and black groups, among others, was scheduled to meet last night to try to decide on a common position.

The Carter administration has promised the black caucus and other interested groups to help get Humphrey-Hawkins enacted this year. Yesterday administration officials told the negotiating senators that President Carter would accept any compromise version that Rep. Augustus F. Hawkins (D-Calif.) and Sen. Muriel Humphrey (D-Minn.) approved.

Hawkins and the late Sen. Hubert H. Humphrey (D-Minn.) originally proposed sweeping full-employment legislation that would have committed the federal government to provide jobs - either through private industry or public employment - for nearly all adult Americans who wanted to work.

After years of dickering and numerous adjustments the bill reported to the Senate contained no proposals that would bind the government to take concrete action to provide jobs for the unemployed.

The latest version would require the president to announce in advance his plans for reducing unemployment, and would also require the Federal Reserve Board to announce every year, in advance, its plans for monetary policy for the coming year and explain how they would coordinate with the president's economic intentions.

Some proponents of this watered-down version said its greatest benefit would be in setting a precedent for requiring advance planning by the government - a step, they argued, toward more rational economic planning generally.