Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Deprecate SelectMode.Single and backport evalOrThrow API #2570

Merged
merged 2 commits into from
Jun 6, 2023

Conversation

lolgab
Copy link
Member

@lolgab lolgab commented Jun 6, 2023

No description provided.

@lefou
Copy link
Member

lefou commented Jun 6, 2023

This supersedes #2554, I guess?

Copy link
Member

@lefou lefou left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good to me.

@lolgab lolgab marked this pull request as ready for review June 6, 2023 08:10
@lolgab lolgab merged commit 1ea329d into com-lihaoyi:0.10.x Jun 6, 2023
31 of 33 checks passed
@lolgab lolgab deleted the backport-apis branch June 6, 2023 08:17
@lefou lefou added this to the 0.10.13 milestone Jun 6, 2023
@lefou
Copy link
Member

lefou commented Nov 10, 2023

This PR breaks binary compatibility.

[1527/1698] main.core.mimaReportBinaryIssues 
Scanning binary compatibility in /home/lefou/work/opensource/mill-0.10.x/out/main/core/compile.dest/classes ...
Found 1 issue when checking against com.lihaoyi:mill-main-core_2.13:0.10.0
 * static method evalOrThrow(mill.eval.Evaluator,scala.Function1)mill.eval.Evaluator#EvalOrThrow in class mill.eval.Evaluator does not have a correspondent in current version
   filter with: ProblemFilter.exclude[DirectMissingMethodProblem]("mill.eval.Evaluator.evalOrThrow")
Found 1 issue when checking against com.lihaoyi:mill-main-core_2.13:0.10.1
 * static method evalOrThrow(mill.eval.Evaluator,scala.Function1)mill.eval.Evaluator#EvalOrThrow in class mill.eval.Evaluator does not have a correspondent in current version
   filter with: ProblemFilter.exclude[DirectMissingMethodProblem]("mill.eval.Evaluator.evalOrThrow")
Found 1 issue when checking against com.lihaoyi:mill-main-core_2.13:0.10.2
 * static method evalOrThrow(mill.eval.Evaluator,scala.Function1)mill.eval.Evaluator#EvalOrThrow in class mill.eval.Evaluator does not have a correspondent in current version
   filter with: ProblemFilter.exclude[DirectMissingMethodProblem]("mill.eval.Evaluator.evalOrThrow")
Found 1 issue when checking against com.lihaoyi:mill-main-core_2.13:0.10.3
 * static method evalOrThrow(mill.eval.Evaluator,scala.Function1)mill.eval.Evaluator#EvalOrThrow in class mill.eval.Evaluator does not have a correspondent in current version
   filter with: ProblemFilter.exclude[DirectMissingMethodProblem]("mill.eval.Evaluator.evalOrThrow")
Found 1 issue when checking against com.lihaoyi:mill-main-core_2.13:0.10.4
 * static method evalOrThrow(mill.eval.Evaluator,scala.Function1)mill.eval.Evaluator#EvalOrThrow in class mill.eval.Evaluator does not have a correspondent in current version
   filter with: ProblemFilter.exclude[DirectMissingMethodProblem]("mill.eval.Evaluator.evalOrThrow")
Found 1 issue when checking against com.lihaoyi:mill-main-core_2.13:0.10.5
 * static method evalOrThrow(mill.eval.Evaluator,scala.Function1)mill.eval.Evaluator#EvalOrThrow in class mill.eval.Evaluator does not have a correspondent in current version
   filter with: ProblemFilter.exclude[DirectMissingMethodProblem]("mill.eval.Evaluator.evalOrThrow")
Found 1 issue when checking against com.lihaoyi:mill-main-core_2.13:0.10.6
 * static method evalOrThrow(mill.eval.Evaluator,scala.Function1)mill.eval.Evaluator#EvalOrThrow in class mill.eval.Evaluator does not have a correspondent in current version
   filter with: ProblemFilter.exclude[DirectMissingMethodProblem]("mill.eval.Evaluator.evalOrThrow")
Found 1 issue when checking against com.lihaoyi:mill-main-core_2.13:0.10.7
 * static method evalOrThrow(mill.eval.Evaluator,scala.Function1)mill.eval.Evaluator#EvalOrThrow in class mill.eval.Evaluator does not have a correspondent in current version
   filter with: ProblemFilter.exclude[DirectMissingMethodProblem]("mill.eval.Evaluator.evalOrThrow")
Found 1 issue when checking against com.lihaoyi:mill-main-core_2.13:0.10.8
 * static method evalOrThrow(mill.eval.Evaluator,scala.Function1)mill.eval.Evaluator#EvalOrThrow in class mill.eval.Evaluator does not have a correspondent in current version
   filter with: ProblemFilter.exclude[DirectMissingMethodProblem]("mill.eval.Evaluator.evalOrThrow")
Found 1 issue when checking against com.lihaoyi:mill-main-core_2.13:0.10.9
 * static method evalOrThrow(mill.eval.Evaluator,scala.Function1)mill.eval.Evaluator#EvalOrThrow in class mill.eval.Evaluator does not have a correspondent in current version
   filter with: ProblemFilter.exclude[DirectMissingMethodProblem]("mill.eval.Evaluator.evalOrThrow")
Found 1 issue when checking against com.lihaoyi:mill-main-core_2.13:0.10.10
 * static method evalOrThrow(mill.eval.Evaluator,scala.Function1)mill.eval.Evaluator#EvalOrThrow in class mill.eval.Evaluator does not have a correspondent in current version
   filter with: ProblemFilter.exclude[DirectMissingMethodProblem]("mill.eval.Evaluator.evalOrThrow")
Found 1 issue when checking against com.lihaoyi:mill-main-core_2.13:0.10.11
 * static method evalOrThrow(mill.eval.Evaluator,scala.Function1)mill.eval.Evaluator#EvalOrThrow in class mill.eval.Evaluator does not have a correspondent in current version
   filter with: ProblemFilter.exclude[DirectMissingMethodProblem]("mill.eval.Evaluator.evalOrThrow")
[1527/1698] main.core.mimaReportBinaryIssues failed

I guess this is because you can't have the same methods defined as static and non-static.

@lolgab Should we revert this?

@lefou
Copy link
Member

lefou commented Nov 10, 2023

But if I look closer, the signature of the class's evalOrThrow and the object's evalOrThrow aren't the same. I have no idea, why MiMa thinks the method is missing.

@lefou
Copy link
Member

lefou commented Nov 10, 2023

The actual class file seen to contain boths methods, so this is probably a false positive?

> javap out/main/core/compile.dest/classes/mill/eval/Evaluator.class 
Compiled from "Evaluator.scala"
public class mill.eval.Evaluator implements scala.Product,java.io.Serializable {
  ...
  public mill.eval.Evaluator$EvalOrThrow evalOrThrow(scala.Function1<mill.eval.Evaluator$Results, java.lang.Throwable>);
  ...
  public static final java.lang.Exception $anonfun$evalOrThrow$default$1$1(mill.eval.Evaluator$Results);  
  ...
}

@lefou lefou mentioned this pull request Nov 10, 2023
lefou added a commit that referenced this pull request Nov 10, 2023
Fix false positive MiMa issue introduced in
#2570

Pull request: #2870
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants