OTTAWA — An effort to have the courts overturn Quebec’s controversial Bill 21 has failed, even though a provincial court did rule that some aspects of the law that infringe on language rights must be scrapped by the government.