Giter VIP home page Giter VIP logo

Comments (12)

jmagman avatar jmagman commented on August 22, 2024

@tarrinneal do you know how this extension code is generated? I'm not spotting it in pigeon
https://github.com/flutter/packages/blob/937038cd033d2c468f871a338ec893343a09ca04/packages/quick_actions/quick_actions_ios/ios/quick_actions_ios/Sources/quick_actions_ios/messages.g.swift#L17

extension FlutterError: Error {}

In Xcode 16.0 beta 1 it seems to want this to be "fully qualified" :

extension FlutterError: Swift.Error {}

The implication is that generated pigeon Swift files with this pattern will generate a compilation warning.

from flutter.

tarrinneal avatar tarrinneal commented on August 22, 2024

That line has changed, but the current version of it is here: https://github.com/flutter/packages/blob/937038cd033d2c468f871a338ec893343a09ca04/packages/pigeon/lib/swift_generator.dart#L842

from flutter.

LouiseHsu avatar LouiseHsu commented on August 22, 2024

@hellohuanlin

from flutter.

jmagman avatar jmagman commented on August 22, 2024

That line has changed, but the current version of it is here: https://github.com/flutter/packages/blob/937038cd033d2c468f871a338ec893343a09ca04/packages/pigeon/lib/swift_generator.dart#L842

You're saying the extension code isn't generated any more by pigeon? Does that mean I should just regenerate the code for this particular plugin?

from flutter.

stuartmorgan avatar stuartmorgan commented on August 22, 2024

It was never generated by Pigeon, it was something we recommended people do at the plugin level in Swift plugins in older versions of Pigeon. I can fix this in the plugin.

from flutter.

jmagman avatar jmagman commented on August 22, 2024

It was never generated by Pigeon, it was something we recommended people do at the plugin level in Swift plugins in older versions of Pigeon. I can fix this in the plugin.

So this wasn't "Autogenerated from Pigeon (v12.0.1), do not edit directly."? It was edited?

from flutter.

tarrinneal avatar tarrinneal commented on August 22, 2024

That extension was added manually, but we've since switched to using our own PigeonError instead. I'm not sure if that class needs the new code (probably does)

from flutter.

tarrinneal avatar tarrinneal commented on August 22, 2024

you can see the old recommendations here packages/pigeon/example/README.md
(this is the pr that added the new error class)

from flutter.

jmagman avatar jmagman commented on August 22, 2024

I see, thanks for the clarification. I thought this code was autogenerated so required a pigeon update.

from flutter.

stuartmorgan avatar stuartmorgan commented on August 22, 2024

It should have been added in the code that used it rather than the generated file. We might have thought we were going to add it to the generator at that point?

But it turns out we aren't even using FlutterError in that plugin, so I'm not sure why it ended up in the PR at all 🤷🏻

from flutter.

jmagman avatar jmagman commented on August 22, 2024

Thank you @stuartmorgan and @tarrinneal!

from flutter.

github-actions avatar github-actions commented on August 22, 2024

This thread has been automatically locked since there has not been any recent activity after it was closed. If you are still experiencing a similar issue, please open a new bug, including the output of flutter doctor -v and a minimal reproduction of the issue.

from flutter.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.