我想将Firebase自定义模型集成到Flutter应用中。我如何整合?

时间:2019-11-04 05:46:32

标签: firebase flutter

我不知道将ML模型保存在Firebase中的位置

请参阅下面的代码,并得到一个错误:

  

断言失败:259行pos 12:'remoteModelName!=空||   localModelName!= null':不正确。

这是按下时的空白:

source 'https://rubygems.org'
ruby '2.0.0'
gem 'rails', '~> 3.2.22.5'
# gem 'rake', '~> 0.9.2'
gem 'thin'
gem 'unicorn'

#====start errors==
# remote: /app/tmp/buildpacks/ruby/lib/language_pack/helpers/rake_runner.rb:102:in `load_rake_tasks!': Could not detect rake tasks (LanguagePack::Helpers::RakeRunner::CannotLoadRakefileError)
# remote: ensure you can run `$ bundle exec rake -P` against your app
# remote: and using the production group of your Gemfile.
# remote: rake aborted!
# remote: cannot load such file -- iconv

# solution: http://stackoverflow.com/questions/7829886/in-require-no-such-file-to-load-iconv-loaderror

gem 'iconv', "~> 1.0.4" # version 1.0.4 was installed by `bundle` so I fixed it to avoid future problems
#====end errors====
# data
gem 'pg', "~> 0.18.4", group: [:production, :staging, :development]
gem 'delayed_job'
gem 'delayed_job_active_record'
gem 'carrierwave'
gem 'fog'
gem 'mini_magick'
gem 'mongoid'
gem 'httparty'
#gem 'mongoid-eager-loading'
gem 'mongo'
gem 'bson'
gem 'bson_ext'
gem 'squeel'
gem 'nokogiri', '~> 1.4.2'
gem 'will_paginate'
gem 'will_paginate_mongoid'

# controllers and views
gem 'inherited_resources'
gem 'haml-rails'
gem 'htmlentities'
gem 'kaminari'
gem 'kaminari-mongoid'

# wickedWizard
gem 'wicked', '1.3.0'

group :assets do
  gem 'sass-rails',   '~> 3.2.6'
  gem 'coffee-rails', '~> 3.2.2'
  gem 'uglifier', '>= 1.0.3'
end

# https://github.com/Shopify/dashing/issues/195
# Coffee Scripts were not compiling somehow without downgrading to "1.4.0"-- Phew- A long awaited issue.
gem 'execjs'

gem 'jquery-rails',  "1.0.19"
gem 'compass-rails', '~> 3.0.2'
gem 'compass-blueprint' # http://compass-style.org/blog/2012/05/20/removing-blueprint/
gem 'backbone-on-rails'#, '~> 1.2'
gem 'fancy-buttons', require: false
gem 'eco'
gem 'pdfkit'
gem 'wicked_pdf', "1.1.0" # Downgrade & lock wicked_pdf gem to 1.1.0 until v2 release (https://github.com/mileszs/wicked_pdf/issues/827#issuecomment-500563629)
gem 'wkhtmltopdf-binary'
gem 'activeadmin'
gem "meta_search",    '>= 1.1.0.pre'
gem "formtastic", "~> 2.1.1"
# auth
gem 'devise'
gem 'omniauth'
gem 'cancan'

# services / support
gem "aws-s3"
gem 'papercavalier-ruby-aaws', require: 'amazon/aws', git: 'git://github.com/xlymian/ruby-aaws.git', ref: '40af30'
gem 'exception_notification', "2.5.2", require: 'exception_notifier'
group :production, :staging do
  gem 'newrelic_rpm', "~> 3.15.2"
end
# gem 'rpm_contrib'
# gem 'heroku'
#gem 'airbrake', group: [:production]
gem 'oink'

gem "memcachier"
gem 'dalli'

# Preview Email
gem "letter_opener", :group => :development

# gem 'quiet_assets', :group => :development
gem 'utf8-cleaner'

gem "activerecord-import"

group :development, :test do
  # gem 'ruby-debug19', require: 'ruby-debug'
  # gem 'mysql2'
end

group :test do
  gem 'turn'
  gem 'factory_girl_rails'
  gem 'rr'
end

gem 'rack-ssl-enforcer', group: [:production]
# gem 'simple_xlsx_writer', '~> 0.5.3'
gem 'xlsx_writer', '~> 0.4.4'
gem 'write_xlsx'
gem 'rubyzip',  "~> 0.9.9"
gem 'roo'

gem 'active_admin_editor'
gem 'ckeditor'
gem 'rails_12factor'

gem 'route_downcaser'
gem "http"

gem "recaptcha", '~> 0.4.0'

gem "figaro" # allows to add environment variables, use config/application.yml to load env vars.

gem 'pry-rails', :group => :development # Debugging

1 个答案:

答案 0 :(得分:0)

将本地模型注册到管理器后,请确保也为解释器定义localModelName。

app.use(session({ secret: 'keyboard cat', resave: false }))

希望这会有所帮助。