Access Control for Extensions in a Package

I am importing a package that has exact same extension as its parent app, and the compiler is getting confused about what functions it should execute, the app ones or the package ones, to be more clear here is an example:

// Parent YellowApp
extension UIViewController {
 func customPush() {
  //some yellow code
 }
}

// Child BluePackage
extension UIViewController {
 func customPush() {
  //some blue code
 }

My expectation is that since the extension is not marked as public it should not create conflicts with it's parent app, that is how it works with cocoapods.

Straightforward solution like renaming functions, deleting extensions or creating wrappers are expensive for me since application is huge. Is there any workaround for this?

Can you share a self-contained example?

Without the code, I'm going to guess that you're not describing the behavior of directly invoking customPush in your app—if that were the case, then it sounds like you've found some sort of bug.

By contrast, if you're calling a function defined in the package that in turn calls its own internal customPush, access control is irrelevant: extension methods not required by a protocol are not dynamically dispatched, meaning that writing your own implementation in your app won't change how a package's own code calls its own customPush.

You are right, not able to reproduce it in an smaller app, will double check the root cause, thank