GithubHelp home page GithubHelp logo

ayapapa / redmine_backlogs Goto Github PK

View Code? Open in Web Editor NEW

This project forked from backlogs/redmine_backlogs

11.0 11.0 8.0 21.16 MB

ubuntu1404-supportブランチにUbuntu14.04&redmine2.x対応, redmine3にredmine3.x対応のための変更を加えました

License: GNU General Public License v2.0

Ruby 7.97% HTML 56.83% JavaScript 28.05% CSS 2.66% Gherkin 3.57% Shell 0.29% Smarty 0.02% PHP 0.63%

redmine_backlogs's People

Contributors

ande3577 avatar ayapapa avatar bohansen avatar ctlajoie avatar dakota avatar dmoreno avatar dpogue avatar drakontia avatar ekohl avatar finelineautomation avatar gvinaccia avatar ippeiukai avatar joakimk avatar johnbat26 avatar kevinjw avatar laurentcoignot avatar mikoto20000 avatar mrliptontea avatar okamototk avatar otf avatar patrickatamaniuk avatar pinglamb avatar relaxdiego avatar rhulka avatar stefan-langenmaier avatar thib-b avatar todesking avatar vanuan avatar yogan avatar yusukekokubo avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar

redmine_backlogs's Issues

Redmine4.0にてmigrateが成功しない

コードお借りしております。
docker-compose 上のRedmine4.0にてインストール失敗しており、調査中です。
お知恵をお貸しください。

0. 環境情報

image ... Redmine:4.0
使用しているdocker-compose定義:https://blog1.mammb.com/entry/2020/05/24/090000

1. bundle install時にエラー発生 ①

root@d3efe946aa6d:/usr/src/redmine# bundle exec rake redmine:plugins:migrate RAILS_ENV=production

[!] There was an error parsing `Gemfile`:
[!] There was an error parsing `Gemfile`: You cannot specify the same gem twice with different version requirements.
You specified: nokogiri (~> 1.10.0) and nokogiri (>= 1.6.7.2). Bundler cannot continue.

 #  from /usr/src/redmine/plugins/redmine_backlogs/Gemfile:11
 #  -------------------------------------------
 #  gem "icalendar"
 >  gem "nokogiri", ">= 1.6.7.2"
 #  gem "open-uri-cached"
 #  -------------------------------------------
. Bundler cannot continue.

 #  from /usr/src/redmine/Gemfile:102
 #  -------------------------------------------
 #  Dir.glob File.expand_path("../plugins/*/{Gemfile,PluginGemfile}", __FILE__) do |file|
 >    eval_gemfile file
 #  end
 #  -------------------------------------------

 GemFile中の nokogiri, capybaraをコメントアウトしたところ、エラーメッセージが変わる(②へ)。

2. bundle install時にエラー発生 ②

Installing sidekiq 6.2.1
Gem::Ext::BuildError: ERROR: Failed to build gem native extension.

    current directory: /usr/local/bundle/gems/eventmachine-1.2.7/ext
/usr/local/bin/ruby -I /usr/local/lib/ruby/2.6.0 -r ./siteconf20210514-46-nbdmyz.rb extconf.rb
checking for -lcrypto... *** extconf.rb failed ***
Could not create Makefile due to some reason, probably lack of necessary
libraries and/or headers.  Check the mkmf.log file for more details.  You may
need configuration options.

Provided configuration options:
        --with-opt-dir
        --without-opt-dir
        --with-opt-include
        --without-opt-include=${opt-dir}/include
        --with-opt-lib
        --without-opt-lib=${opt-dir}/lib
        --with-make-prog
        --without-make-prog
        --srcdir=.
        --curdir
        --ruby=/usr/local/bin/$(RUBY_BASE_NAME)
        --with-ssl-dir
        --without-ssl-dir
        --with-ssl-include
        --without-ssl-include=${ssl-dir}/include
        --with-ssl-lib
        --without-ssl-lib=${ssl-dir}/lib
        --with-openssl-config
        --without-openssl-config
        --with-pkg-config
        --without-pkg-config
        --with-cryptolib
        --without-cryptolib
/usr/local/lib/ruby/2.6.0/mkmf.rb:467:in `try_do': The compiler failed to generate an executable file. (RuntimeError)
You have to install development tools first.
        from /usr/local/lib/ruby/2.6.0/mkmf.rb:552:in `try_link0'
        from /usr/local/lib/ruby/2.6.0/mkmf.rb:570:in `try_link'
        from /usr/local/lib/ruby/2.6.0/mkmf.rb:789:in `try_func'
        from /usr/local/lib/ruby/2.6.0/mkmf.rb:1016:in `block in have_library'
        from /usr/local/lib/ruby/2.6.0/mkmf.rb:959:in `block in checking_for'
        from /usr/local/lib/ruby/2.6.0/mkmf.rb:361:in `block (2 levels) in postpone'
        from /usr/local/lib/ruby/2.6.0/mkmf.rb:331:in `open'
        from /usr/local/lib/ruby/2.6.0/mkmf.rb:361:in `block in postpone'
        from /usr/local/lib/ruby/2.6.0/mkmf.rb:331:in `open'
        from /usr/local/lib/ruby/2.6.0/mkmf.rb:357:in `postpone'
        from /usr/local/lib/ruby/2.6.0/mkmf.rb:958:in `checking_for'
        from /usr/local/lib/ruby/2.6.0/mkmf.rb:1011:in `have_library'
        from extconf.rb:8:in `block in check_libs'
        from extconf.rb:8:in `all?'
        from extconf.rb:8:in `check_libs'
        from extconf.rb:95:in `<main>'

To see why this extension failed to compile, please check the mkmf.log which can be found here:

  /usr/local/bundle/extensions/x86_64-linux/2.6.0/eventmachine-1.2.7/mkmf.log

extconf failed, exit code 1

Gem files will remain installed in /usr/local/bundle/gems/eventmachine-1.2.7 for inspection.
Results logged to /usr/local/bundle/extensions/x86_64-linux/2.6.0/eventmachine-1.2.7/gem_make.out

An error occurred while installing eventmachine (1.2.7), and Bundler cannot continue.
Make sure that `gem install eventmachine -v '1.2.7' --source 'https://rubygems.org/'` succeeds before bundling.

In Gemfile:
  thin was resolved to 1.8.0, which depends on
    eventmachine


Gem::Ext::BuildError: ERROR: Failed to build gem native extension.

    current directory: /usr/local/bundle/gems/json-2.5.1/ext/json/ext/generator
/usr/local/bin/ruby -I /usr/local/lib/ruby/2.6.0 -r ./siteconf20210514-46-ulw4ex.rb extconf.rb
creating Makefile

current directory: /usr/local/bundle/gems/json-2.5.1/ext/json/ext/generator
make "DESTDIR=" clean
sh: 1: make: not found

current directory: /usr/local/bundle/gems/json-2.5.1/ext/json/ext/generator
make "DESTDIR="
sh: 1: make: not found

make failed, exit code 127

Gem files will remain installed in /usr/local/bundle/gems/json-2.5.1 for inspection.
Results logged to /usr/local/bundle/extensions/x86_64-linux/2.6.0/json-2.5.1/gem_make.out

An error occurred while installing json (2.5.1), and Bundler cannot continue.
Make sure that `gem install json -v '2.5.1' --source 'https://rubygems.org/'` succeeds before bundling.

In Gemfile:
  json

★対策
1. aptにてmake, gcc, g++をインストール。
2. gem install eventmachine -v '1.2.7' --source 'https://rubygems.org/'
3. gem install json -v '2.5.1

3. bundle exec 時にエラー発生

root@d3efe946aa6d:/usr/src/redmine# bundle install
The dependency tzinfo-data (>= 0) will be unused by any of the platforms Bundler is installing for. Bundler is installing for ruby but the dependency is only for x86-mingw32, x64-mingw32, x86-mswin32. To add those platforms to the bundle, run `bundle lock --add-platform x86-mingw32 x64-mingw32 x86-mswin32`.
Fetching gem metadata from https://rubygems.org/............
Fetching gem metadata from https://rubygems.org/.
Resolving dependencies...
Using rake 13.0.3
~~~
Installing json 2.5.1 with native extensions
Installing eventmachine 1.2.7 with native extensions
Fetching thin 1.8.0
Installing thin 1.8.0 with native extensions
Bundle complete! 54 Gemfile dependencies, 78 gems now installed.
Gems in the groups development and test were not installed.
Use `bundle info [gemname]` to see where a bundled gem is installed.
root@d3efe946aa6d:/usr/src/redmine# bundle exec rake redmine:plugins:migrate RAILS_ENV=production
W, [2021-05-14T11:40:59.464614 #978]  WARN -- : Creating scope :system. Overwriting existing method Enumeration.system.
W, [2021-05-14T11:40:59.545109 #978]  WARN -- : Creating scope :backlog_scope. Overwriting existing method RbStory.backlog_scope.
W, [2021-05-14T11:40:59.562921 #978]  WARN -- : Creating scope :sorted. Overwriting existing method Group.sorted.
W, [2021-05-14T11:40:59.568963 #978]  WARN -- : Creating scope :sorted. Overwriting existing method User.sorted.
E, [2021-05-14T11:40:59.696230 #978] ERROR -- : Backlogs printable cards: problem loading labels: No such file or directory @ rb_sysopen - /usr/src/redmine/plugins/redmine_backlogs/lib/labels/labels.yaml
E, [2021-05-14T11:40:59.696392 #978] ERROR -- : /usr/local/lib/ruby/2.6.0/psych.rb:577:in `initialize'
~~~
I, [2021-05-14T11:41:00.097274 #978]  INFO -- : Migrating to RbAddHistory (38)
== 38 RbAddHistory: migrating =================================================
Rebuilding history...
     1 (     1/770)...
rake aborted!
StandardError: An error has occurred, all later migrations canceled:

undefined method `id' for 7:Integer
Did you mean?  i
/usr/src/redmine/plugins/redmine_backlogs/app/models/rb_issue_history.rb:35:in `block in statuses'
/usr/src/redmine/plugins/redmine_backlogs/app/models/rb_issue_history.rb:150:in `block (3 levels) in rebuild_issue'
/usr/src/redmine/plugins/redmine_backlogs/app/models/rb_issue_history.rb:149:in `each'
/usr/src/redmine/plugins/redmine_backlogs/app/models/rb_issue_history.rb:149:in `each_with_index'
/usr/src/redmine/plugins/redmine_backlogs/app/models/rb_issue_history.rb:149:in `block (2 levels) in rebuild_issue'
/usr/local/bundle/gems/activerecord-5.2.5/lib/active_record/relation/delegation.rb:71:in `each'
/usr/local/bundle/gems/activerecord-5.2.5/lib/active_record/relation/delegation.rb:71:in `each'
/usr/src/redmine/plugins/redmine_backlogs/app/models/rb_issue_history.rb:133:in `block in rebuild_issue'
/usr/local/bundle/gems/activerecord-5.2.5/lib/active_record/relation/delegation.rb:71:in `each'
/usr/local/bundle/gems/activerecord-5.2.5/lib/active_record/relation/delegation.rb:71:in `each'
/usr/src/redmine/plugins/redmine_backlogs/app/models/rb_issue_history.rb:129:in `rebuild_issue'
/usr/src/redmine/plugins/redmine_backlogs/app/models/rb_issue_history.rb:329:in `block in rebuild'
/usr/local/bundle/gems/activerecord-5.2.5/lib/active_record/relation/delegation.rb:71:in `each'
/usr/local/bundle/gems/activerecord-5.2.5/lib/active_record/relation/delegation.rb:71:in `each'
/usr/src/redmine/plugins/redmine_backlogs/app/models/rb_issue_history.rb:327:in `each_with_index'
/usr/src/redmine/plugins/redmine_backlogs/app/models/rb_issue_history.rb:327:in `rebuild'
/usr/src/redmine/plugins/redmine_backlogs/db/migrate/038_rb_add_history.rb:35:in `up'

Ruby側のバージョン問題と思われるが、原因特定できず。調査断念。

Redmine4で利用時にチケット一覧表示でinternal error

報告元: #24 (comment)

参考サイト:

  1. https://blog.adachin.me/archives/6343
  2. http://www.redmine.org/issues/26637
  3. issue #19

上記issue #19 にて対応した、Redmine 3.4以上のときの分岐条件において、4.0以上が通るようになっていないために、起きたエラーと思われる
ayapapa/alminiumのredmine4ブランチでは、本エラーを、上記参考サイトの 12と同様に、redmine本体側にパッチを充てて対応していたが、本プラグインにおいても対応する。

エラー時のメッセージが不適切

エラー通知等で以下のような実装があり、

render text: "なんとかかんとか"

これが、Rails5.xでは、エラーになるため、以下のように変更する必要がある。

render plain: "なんとかかんとか"

以下、該当箇所記載。

app/controllers/rb_stories_controller.rb:      render :text => "No label stock selected. How did you get here?", :status => 500
app/controllers/rb_stories_controller.rb:      render :text => "There was a problem rendering the cards. A possible error could be that the selected font exceeds a render box", :status => 500
app/controllers/rb_stories_controller.rb:      render :text => e.message.blank? ? e.to_s : e.message, :status => 400
app/controllers/rb_stories_controller.rb:      render :text => e.message.blank? ? e.to_s : e.message, :status => 400
app/controllers/rb_sprints_controller.rb:      render :text => e.message.blank? ? e.to_s : e.message, :status => 400
app/controllers/rb_sprints_controller.rb:      render :text => e.message.blank? ? e.to_s : e.message, :status => 400
app/controllers/rb_sprints_controller.rb:      render :text => 'Sprint without start date cannot be reset', :status => 400
app/controllers/rb_releases_controller.rb:      render :text => e.message.blank? ? e.to_s : e.message, :status => 400
app/controllers/rb_tasks_controller.rb:      render :text => e.message.blank? ? e.to_s : e.message, :status => 400
app/controllers/rb_impediments_controller.rb:      render :text => e.message.blank? ? e.to_s : e.message, :status => 400
app/controllers/rb_impediments_controller.rb:      render :text => e.message.blank? ? e.to_s : e.message, :status => 400

calendar doesn't appear in editing release date items.

「リリース」の作成、または、編集で日付項目(開始、終了)にカレンダーが表示されない。
Ubunt14.04では問題がなく、Ubuntu16.04にインストールしたRedmineで問題が発生する。
おそらくRuby関連のバージョンによる違い、あるいは、これに伴うcalendar_forの実装変更などが原因と思われる。

bundle install error

redmine2.xにプラグインした場合に発生。
gem "holidays"が、rubyバージョン2.x以上を要求するため、バージョン不整合を起きる。

かんばんからNew Taskを作成すると404になる

バージョン4対応ありがとうございます。
下記の環境でpluginを導入することはできたのですが、かんばんからNew Taskを発行しようとするとNew Taskのダイアログが404エラーとなります。
原因や対処方法等分かればご教示ください。

CentOS Linux release 7.6.1810
Environment:
Redmine version 4.0.3.stable
Ruby version 2.6.1-p33 (2019-01-30) [x86_64-linux]
Rails version 5.2.2.1
Environment production
Database adapter Mysql2
Mailer queue ActiveJob::QueueAdapters::AsyncAdapter
Mailer delivery smtp
SCM:
Subversion 1.7.14
Git 1.8.3.1
Filesystem
Redmine plugins:
redmine_backlogs v1.0.6

support ubuntu1404

caused install error on ubunt14.04.
reason is that prawn described in Gemfile depends on ruby2.0, but ruby's version on ubuntu1404 is 1.9.3 .
need to speciied prawn's version(maybe 1.3.0).

update for redmine4

ビルドエラー解消後、ルーティングエラー発生。routes.rbを以下のような変更することで対応できるか否かを試みる。

(ここまで略)
if Rails::VERSION::MAJOR < 3
  ActionController::Routing::Routes.draw do |map|
    # Use rb/ as a URL 'namespace.' We're using a slightly different URL pattern
    # From Redmine so namespacing avoids any further problems down the line
    map.resource :rb, :only => :none do |rb|
      rb.resource   :task,             :except => :index,             :controller => :rb_tasks,           :as => "task/:id"
      rb.resources  :tasks,            :only => :index,               :controller => :rb_tasks,           :as => "tasks/:story_id"
      rb.resource   :taskboard,        :only => :show,                :controller => :rb_taskboards,      :as => "taskboards/:sprint_id"
      rb.resource   :taskboard,        :only => :current,             :controller => :rb_taskboards,      :as => "projects/:project_id/taskboard"

      rb_common_routes rb
    end
  end

else

  RedmineApp::Application.routes.draw do # ★追加
    resource :rb, :only => :none do |rb|

  # releases
#  resources :projects do
#    resources :releases, :only => [:index, :new,:show, :edit, :destroy, :snapshot], :controller => :rb_releases  do
#      get 'snapshot', :on => :member
#      post 'edit', :on => :member
#      post 'new', :on => :member
#    end
#  end

      rb_common_routes rb

      resources :task, :except => :index, :controller => :rb_tasks
      rb_match rb, 'tasks/:story_id', :to => 'rb_tasks#index', :via => [:get]

      rb_match rb, 'taskboards/:sprint_id',
            :to => 'rb_taskboards#show', :via => [:get]
      rb_match rb, 'projects/:project_id/taskboard',
            :to => 'rb_taskboards#current', :via => [:get]
    end # resource :rb, :only => :none do |rb|
  end # RedmineApp::Application.routes.draw do ★追加
end # if Rails::VERSION::MAJOR < 3 else```

update holiday gem

holidays 3.1.0 が現時点で最新であり、問題がなさそうなので、最新を使うようにする

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.