The government has said it may drop key clauses from a bill that would breach international law by letting the UK unilaterally rewrite parts of the Brexit departure agreement. On Monday night the House of Commons voted down a series of five Lords amendments that had removed the controversial clauses from the internal market bill. The offer to remove the key controversial clauses pacified some Conservative MPs who had deep reservations about breaking international law, though some warned in the debate about the consequences to the UK’s international reputation should no deal be reached. Three Tory MPs rebelled during the votes, including Simon Hoare, chair of the Northern Ireland select committee. Among the MPs who abstained – and are known to have previously expressed concerns about the bill – were the former prime minister Theresa May, the former attorney generals Geoffrey Cox and Jeremy Wright, and the former Northern Ireland secretaries Julian Smith and Karen Bradley, as well as the chair of the foreign affairs select committee, Tom Tugendhat. The offer is conditional on the two sides agreeing a final trade deal this week when the prime minister meets the European commission president in Brussels for a make-or-break summit. The reintroduction of the controversial text had looked set to inflame tensions between the two sides at a crucial point in the Brexit talks, until the concession to take the clauses out again was offered by Boris Johnson in a call with Ursula von der Leyen. Speaking in the debate before the vote, Labour’s shadow business secretary, Ed Miliband, said the row over the clauses had been “calamitous, embarrassing and toxic” for the government and had been opposed by everyone from Conservative grandees such as Michael Howard and William Hague to the archbishop of Canterbury and US president-elect Joe Biden. He said it would be hard for the international community to trust that the clauses would be removed. “The one thing this whole saga has shown the world, I’m afraid, is that this government cannot be trusted, because they are willing to rip up international agreements they made less than a year ago.” The former defence minister Tobias Ellwood expressed alarm at the state of the negotiations during the debate on Monday and said the UK’s international standing had been “bruised” by a willingness to flout international law. “It would be an abject failure of statecraft to leave the EU with no deal,” he said. “If more time is required, then so be it. We will live with the consequences for years, indeed decades. We must summon the political courage to get it right. The west is about to regroup. Our voice, our experience, our leadership are needed on the global stage.” In a sign of softening attitudes, a government spokesman said it had agreed via the UK-EU joint committee, a bilateral body of ministers that deals with the withdrawal agreement, to iron out disagreements over the document, signed in January. The breach of international law in the clauses caused an outcry among MPs and the resignation of the government’s top lawyer. The House of Lords voted overwhelmingly to amend it to remove the offending elements. Ministers have said these would be restored by the Commons. If this happens, the bill would return to the Lords as part of a process known as ping-pong – but agreement on a trade bill could end the legislative impasse. The spokesman said the UK would be “prepared to remove clause 44 of the UK internal market bill, concerning export declarations … to deactivate clauses 45 and 47, concerning state aid.” Clause 45 of the bill sets out that the UK government could change import and export procedures for goods between Northern Ireland and the rest of the UK, and amend elements of the associated Northern Ireland protocol, “notwithstanding any relevant international or domestic law with which they may be incompatible or inconsistent”. The government’s commitment appeared to mollify some Conservatives in the Lords. Bob Neill, the chair of the Commons justice committee, said it would remove the clause that had “caused most concern to legal commentators … a significant gesture of good faith on Her Majesty’s government’s part and would hopefully remove some of the real concerns that have been expressed.” The business minister, Paul Scully, who opened the debate, said the government was “keen to work in partnership as we do some difficult negotiations … We want to solve these problems rather than have to legislate for them.” The measures, which the government openly conceded would breach international law, prompted criticism from both opposition parties and EU politicians, even if many did see it as primarily a lever for Brexit negotiations. The UK government has insisted that the clauses are necessary as a failsafe to preserve goods going to Northern Ireland in the event of a disorderly Brexit once the transition period finishes at the end of the year, with tariffs added to goods from the rest of the UK seen as “at risk” of entering the EU by going on to the Republic of Ireland. The statement followed last-minute talks in Brussels on Monday between Michael Gove, the Cabinet Office minister, and Maroš Šefčovič, the vice-president of the European commission. The UK government statement added: “Good progress continues to be made regarding the decision as to which goods are ‘at risk’ of entering the EU market. Talks continue this afternoon. In the light of those discussions, the government will keep under review the content of the forthcoming taxation bill.” The taxation bill, another post-Brexit measure expected in the Commons imminently, had also been predicted to contain clauses breaching international law.