Code Monkey home page Code Monkey logo

Comments (8)

wuv1982 avatar wuv1982 commented on June 14, 2024 26

Explicitly add import GTMSessionFetcher in Swift

from google-api-objectivec-client.

thomasvl avatar thomasvl commented on June 14, 2024 13

First up, please note this project has been deprecated in favor of GTLR (Note: there is a Migrating From GTL to GTLR doc).

The issue is likely the use of a Swift bridging header. Sadly, bridging headers will strip all properties, methods, etc. that reference an "incomplete" type. Incomplete is caused simply by things being forward declared (@Class Foo, @protocol DoSomething). To have the properties exposed, you have to manually import the header that define the forward declared types:

Try adding:
#import <GTMSessionFetcher/GTMSessionFetcher.h>
#import <GTMSessionFetcher/GTMSessionFetcherService.h>

That should fix the problem. When you hit this sorta issue in ObjC, it can kick out an error about the type of the property being incomplete, but with a bridging header it just drops them leaving it in this confusing state when you try to access them.

from google-api-objectivec-client.

thomasvl avatar thomasvl commented on June 14, 2024 1

It almost sounds like you don't have GTLRYouTubeService.h in your bridging header and maybe just have @class GTLRYouTubeService. If the full header is there, they it will know it is a subclass of GTLRService, and GTLRService provides the authorizer.

from google-api-objectivec-client.

manjunathgudisi avatar manjunathgudisi commented on June 14, 2024 1

screen shot 2017-06-14 at 2 49 36 pm
I have added that in bridging.h file already. Still getting the same error. I have changed the framework search path in build settings as well, but no luck.

#import <GoogleAPIClientForRest/GTLRYouTube.h>

from google-api-objectivec-client.

thomasvl avatar thomasvl commented on June 14, 2024

Can you set up a simple example project that shows it? At the moment I'm at a loss since I haven't seen this before.

from google-api-objectivec-client.

thomasvl avatar thomasvl commented on June 14, 2024

btw - this if filed on GTL, not GTLR. I'm going to close this out since it is the wrong project, go ahead and reopen on the correct one.

from google-api-objectivec-client.

huongtran84 avatar huongtran84 commented on June 14, 2024

I also facing with the bug. how to fix it?

from google-api-objectivec-client.

manjunathgudisi avatar manjunathgudisi commented on June 14, 2024

@huongtran84 look at attached podfile.lock file
screen shot 2017-07-24 at 10 11 30 am

from google-api-objectivec-client.

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.