Skip to content

Conversation

@Kapusch
Copy link

@Kapusch Kapusch commented Feb 5, 2026

This pull request introduces several improvements and fixes to the build, CI, and packaging process, as well as documentation updates and the addition of new artifacts. The most significant changes include enabling and updating the Firebase AppCheck and Google AppCheckCore components, improving CI reliability, and clarifying versioning and troubleshooting for contributors.

Artifact and Dependency Updates:

  • Enabled and updated the Firebase.AppCheck artifact to version 12.5.0.4, added its podspec, samples, and set dependencies (including Google.AppCheckCore). [1] [2] [3] [4] [5]
  • Introduced the Google.AppCheckCore artifact (11.2.0.0) with its podspec and dependencies, and updated Google.SignIn to depend on it. [1] [2] [3] [4]

Build and CI Improvements:

  • Updated CI workflows to use macos-15 runners, added toolchain version checks, and configured GitHub Packages as a NuGet source for publishing. [1] [2]
  • Refactored the Cake build script to build and pack each .csproj directly (instead of using solution-level targets), improving reliability and fixing issues with solution target builds. [1] [2] [3]
  • Ensured code signing is disabled by default in Xcode builds for CI compatibility. [1] [2]

Versioning and Packaging:

  • Improved versioning logic so FileVersion is always set, and PackageVersion is only overwritten if it doesn't already have a pre-release suffix—enabling forked builds to publish custom versions without modifying shared version lines.
  • Added documentation on versioning, fork testing suffix policies, and how to configure GitHub Packages feeds for fork contributors. [1] [2]

Documentation and Troubleshooting:

  • Expanded build documentation with troubleshooting for common errors (e.g., missing targets, missing packages, code signing, and NuGet feed issues), and clarified the build process for contributors.

Other Build Script Fixes:

  • Standardized the use of forward slashes for MSBuild targets across all platforms to avoid path issues.

- Introduced CI workflow for build and package validation using GitHub Actions.
- Added detailed building instructions for local development in `docs/BUILDING.md`.
- Created `AGENTS.md` to outline agent instructions and best practices for contributions.
- Updated `Readme.md` to include CI and publishing information.
- Enhanced `CONTRIBUTING.md` with guidelines for new contributors and repository orientation.
- Integrate Google.AppCheckCore v11.2.0 support (pr/repair-firebase-app-check)
- Upgrade Google.SignIn to v9.0.0 (origin/main)
- Update AppAuth to v2.0.0 and GTMAppAuth to v5.0.0 (origin/main)
- Keep separate GOOGLE_APP_CHECK_CORE_ARTIFACT PodSpec definition
Copy link

@chatgpt-codex-connector chatgpt-codex-connector bot left a comment

Choose a reason for hiding this comment

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

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: 5bce1c1fa4

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

@Kapusch
Copy link
Author

Kapusch commented Feb 6, 2026

Hey @AdamEssenmacher , sorry I went too fast, the other modes actually didn't work.

Now this is fixed and validated in Playground sample app 👍
Validated modes:

  • Disabled (both simulator & real device)
  • Debug (both simulator & real device)
  • AppAttest (real device)
  • DeviceCheck (real device)

@AdamEssenmacher
Copy link
Owner

Looking good. The only 'miss' I'm noticing is that AppCheckCore should have PackageReferences on PromisesObjC and GoogleUtilities I think.

I also have a question about the changes in ApiDefinition.cs. At a glance, it doesn't look like they should have been necessary (except for probably adding that using statement)? Even if it is working, the original definitions seem to be more correct--but again, this is 'at a glance', so I'm wondering what the reasons were that drove these changes.

…s for PromisesObjC and GoogleUtilities to AppCheckCore.csproj
@Kapusch
Copy link
Author

Kapusch commented Feb 6, 2026

Hey @AdamEssenmacher , as usual, thanks for the (fast!) review. Please find below my comments.

AppCheckCore missing PackageReferences

Good catch, I fixed it by adding PromisesObjC and GoogleUtilities to AppCheckCore.csproj (version ranges matching the repo conventions). I also updated components.cake accordingly.

ApiDefinition.cs changes

Actually, most of my changes were driven by a runtime InvalidCastException when calling SetAppCheckProviderFactory:

System.InvalidCastException: Specified cast is not valid.
   at Firebase.AppCheck.AppCheck.SetAppCheckProviderFactory(AppCheckDebugProviderFactory factory)

I'm not an ObjC binding expert, so I worked through it incrementally:

  1. interface IAppCheckProvider { } / interface IAppCheckProviderFactory { } + : IProtocol conformance on concrete classes.
    This aligns with the convention used elsewhere in this repo (Firebase.Auth, CloudMessaging, etc.). The original was using class inheritance for protocol conformance.

  2. Removing [BaseType] from protocol definitions
    For protocols without [Model], [Protocol(Name = "...")] seemed sufficient (same pattern as IInAppMessagingDisplay). Happy to restore [BaseType] if you think it's better.

  3. NSObject parameter + Extensions.cs
    This was the workaround for the InvalidCastException above. Even after fixing the protocol interfaces, passing a concrete factory to the binding-generated method still failed at runtime. The Extensions.cs bypasses the binding layer via raw objc_msgSend.

If you have a better approach for (3), I'm happy to try it. Thank you.

@AdamEssenmacher
Copy link
Owner

Thanks for the answer. Believe it or not, I'm not an iOS bindings expert either 😓

The thing that jumped out at me was the NSObject parameter. That's not really right... but it's also going to work as long as the right object is passed into it.

I suppose the likelihood of this ever being misused is pretty low, as it's kind of one of those things that gets set once at startup and you never have to think about it again.

It sounds like you've tested it pretty thoroughly, and provided samples that others can follow. So, it's better than what we have now (which is nothing, lol). If the binding contract is less than ideal, I guess I really don't care that much. It can always be improved later.

I'll get this merged in and do a light test in my own app before publishing a new package.

Your work here is going to make a lot of people happy!

@AdamEssenmacher
Copy link
Owner

One other thing @Kapusch , I can't add you as a collaborator at Plugin.Firebase (only Tobi can do that right now), but I'll ask him to after reviewing the AppCheck PR over there.

I'd like you to add you as a collaborator here if you'd like. Either way, feel free to hit me up on Discord. I just joined the MAUIverse server today, so I should be easy to find there.

@Kapusch
Copy link
Author

Kapusch commented Feb 7, 2026

The thing that jumped out at me was the NSObject parameter. That's not really right... [...] It can always be improved later.

I hear you. My primary goal was to make it work, but I understand it is not right and we should improve it.

[...]but it's also going to work as long as the right object is passed into it.

If you think there is a true risk of instability, I would prefer to improve it now. Otherwise, agree it can wait.

I'd like you to add you as a collaborator here if you'd like

As I said, this was all new to me, so I didn't feel legitimate initially, but since you proposed and as I'm convinced it's best to be a group of maintainers on this, I'd be happy to join you as collaborator here as well! Thank you 😊

@Kapusch
Copy link
Author

Kapusch commented Feb 7, 2026

I finally made the fix in ApiDefinition for clean protocol bindings, and I verified there is no more InvalidCastException! Please review the changes just in case, but I think we are good now for merge 👍

Also, I took the opportunity to improve the sample app to let the tester defining the AppCheck mode at first launch, and reset it anytime.

@AdamEssenmacher
Copy link
Owner

@codex do one final review

Copy link

@chatgpt-codex-connector chatgpt-codex-connector bot left a comment

Choose a reason for hiding this comment

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

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: 9ee57a36ea

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

@AdamEssenmacher AdamEssenmacher merged commit 6498909 into AdamEssenmacher:main Feb 7, 2026
1 check passed
@AdamEssenmacher AdamEssenmacher mentioned this pull request Feb 7, 2026
@Kapusch Kapusch deleted the pr/repair-firebase-app-check branch February 7, 2026 23:24
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.

2 participants