首页
学习
活动
专区
圈层
工具
发布
社区首页 >问答首页 >如何要求google api客户端

如何要求google api客户端
EN

Stack Overflow用户
提问于 2018-07-18 15:15:49
回答 1查看 527关注 0票数 0

我正在使用google-api-client gem在谷歌日历中创建事件。

我在谷歌找到了文档:https://developers.google.com/calendar/quickstart/ruby

因此,当我安装gem时,在命令rails console之后,我尝试了require libs:

代码语言:javascript
复制
require 'google/api_client', 
require 'google/apis',
require 'google/apis/calendar_v3'

在每个require上,我都会得到这样的错误:LoadError: cannot load such file

创业板信息:

代码语言:javascript
复制
bundle info google-api-client

google-api-client (0.23.4)
Summary: Client for accessing Google APIs
Homepage: https://github.com/google/google-api-ruby-client
Path: /Users/danielsaifulin/.rvm/gems/ruby-2.4.0-rc1@sortd/gems/google-api-client-0.23.4`
EN

回答 1

Stack Overflow用户

发布于 2018-07-18 16:01:40

我不知道为什么,但在rails console中,当我调用require 'google/apis‘时,它不工作,但当我在rails helper中的某个函数中运行时,它是工作的。

所以,问题已经解决了。

票数 0
EN
页面原文内容由Stack Overflow提供。腾讯云小微IT领域专用引擎提供翻译支持
原文链接:

https://stackoverflow.com/questions/51395787

复制
相关文章

相似问题

领券
问题归档专栏文章快讯文章归档关键词归档开发者手册归档开发者手册 Section 归档