From 5a18606690b7cc5f2bd4772fc8973ac808a815e4 Mon Sep 17 00:00:00 2001 From: stephanie rousset Date: Tue, 3 Mar 2026 10:11:14 +0100 Subject: [PATCH 01/17] feat: setup for 0.31 --- .node-version | 2 +- .rubocop.yml | 2 +- .ruby-version | 2 +- Gemfile | 12 +- Gemfile.lock | 1170 ++++++++++++----------- decidim-budgets_importer.gemspec | 2 +- lib/decidim/budgets_importer/version.rb | 4 +- package-lock.json | 466 +++++++++ package.json | 5 + 9 files changed, 1120 insertions(+), 545 deletions(-) create mode 100644 package-lock.json create mode 100644 package.json diff --git a/.node-version b/.node-version index 06e7515..7d41c73 100644 --- a/.node-version +++ b/.node-version @@ -1 +1 @@ -16.9.1 +22.14.0 diff --git a/.rubocop.yml b/.rubocop.yml index c577222..63f6143 100644 --- a/.rubocop.yml +++ b/.rubocop.yml @@ -1,4 +1,4 @@ -inherit_from: https://raw.githubusercontent.com/decidim/decidim/release/0.27-stable/.rubocop.yml +inherit_from: https://raw.githubusercontent.com/decidim/decidim/release/0.31-stable/.rubocop.yml AllCops: Include: diff --git a/.ruby-version b/.ruby-version index d9c62ed..a0891f5 100644 --- a/.ruby-version +++ b/.ruby-version @@ -1 +1 @@ -3.0.2 \ No newline at end of file +3.3.4 diff --git a/Gemfile b/Gemfile index 7b57799..d9de521 100644 --- a/Gemfile +++ b/Gemfile @@ -8,20 +8,20 @@ gem "decidim" gem "decidim-budgets_importer", path: "." gem "bootsnap", "~> 1.4" -gem "puma", ">= 5.5.1" +gem "puma", ">= 6.3.1" group :development, :test do gem "byebug", "~> 11.0", platform: :mri - gem "decidim-dev" + gem "decidim-dev", "~> 0.31" end group :development do - gem "faker", "~> 2.14" - gem "letter_opener_web", "~> 1.3" + gem "faker", "3.5.3" + gem "letter_opener_web", "~> 2.0" gem "listen", "~> 3.1" gem "rubocop-faker" - gem "spring", "~> 2.0" + gem "spring", "~> 4.0" gem "spring-watcher-listen", "~> 2.0" - gem "web-console", "~> 4.0.4" + gem "web-console", "~> 4.2" end diff --git a/Gemfile.lock b/Gemfile.lock index 66f258b..0e514b9 100644 --- a/Gemfile.lock +++ b/Gemfile.lock @@ -1,443 +1,492 @@ PATH remote: . specs: - decidim-budgets_importer (2.0.0) - decidim-core (~> 0.27) + decidim-budgets_importer (3.0.0) + decidim-core (~> 0.31.2) GEM remote: https://rubygems.org/ specs: - actioncable (6.1.7.4) - actionpack (= 6.1.7.4) - activesupport (= 6.1.7.4) + actioncable (7.2.3) + actionpack (= 7.2.3) + activesupport (= 7.2.3) nio4r (~> 2.0) websocket-driver (>= 0.6.1) - actionmailbox (6.1.7.4) - actionpack (= 6.1.7.4) - activejob (= 6.1.7.4) - activerecord (= 6.1.7.4) - activestorage (= 6.1.7.4) - activesupport (= 6.1.7.4) - mail (>= 2.7.1) - actionmailer (6.1.7.4) - actionpack (= 6.1.7.4) - actionview (= 6.1.7.4) - activejob (= 6.1.7.4) - activesupport (= 6.1.7.4) - mail (~> 2.5, >= 2.5.4) - rails-dom-testing (~> 2.0) - actionpack (6.1.7.4) - actionview (= 6.1.7.4) - activesupport (= 6.1.7.4) - rack (~> 2.0, >= 2.0.9) + zeitwerk (~> 2.6) + actionmailbox (7.2.3) + actionpack (= 7.2.3) + activejob (= 7.2.3) + activerecord (= 7.2.3) + activestorage (= 7.2.3) + activesupport (= 7.2.3) + mail (>= 2.8.0) + actionmailer (7.2.3) + actionpack (= 7.2.3) + actionview (= 7.2.3) + activejob (= 7.2.3) + activesupport (= 7.2.3) + mail (>= 2.8.0) + rails-dom-testing (~> 2.2) + actionpack (7.2.3) + actionview (= 7.2.3) + activesupport (= 7.2.3) + cgi + nokogiri (>= 1.8.5) + racc + rack (>= 2.2.4, < 3.3) + rack-session (>= 1.0.1) rack-test (>= 0.6.3) - rails-dom-testing (~> 2.0) - rails-html-sanitizer (~> 1.0, >= 1.2.0) - actiontext (6.1.7.4) - actionpack (= 6.1.7.4) - activerecord (= 6.1.7.4) - activestorage (= 6.1.7.4) - activesupport (= 6.1.7.4) + rails-dom-testing (~> 2.2) + rails-html-sanitizer (~> 1.6) + useragent (~> 0.16) + actiontext (7.2.3) + actionpack (= 7.2.3) + activerecord (= 7.2.3) + activestorage (= 7.2.3) + activesupport (= 7.2.3) + globalid (>= 0.6.0) nokogiri (>= 1.8.5) - actionview (6.1.7.4) - activesupport (= 6.1.7.4) + actionview (7.2.3) + activesupport (= 7.2.3) builder (~> 3.1) - erubi (~> 1.4) - rails-dom-testing (~> 2.0) - rails-html-sanitizer (~> 1.1, >= 1.2.0) + cgi + erubi (~> 1.11) + rails-dom-testing (~> 2.2) + rails-html-sanitizer (~> 1.6) active_link_to (1.0.5) actionpack addressable - activejob (6.1.7.4) - activesupport (= 6.1.7.4) + activejob (7.2.3) + activesupport (= 7.2.3) globalid (>= 0.3.6) - activemodel (6.1.7.4) - activesupport (= 6.1.7.4) - activerecord (6.1.7.4) - activemodel (= 6.1.7.4) - activesupport (= 6.1.7.4) - activestorage (6.1.7.4) - actionpack (= 6.1.7.4) - activejob (= 6.1.7.4) - activerecord (= 6.1.7.4) - activesupport (= 6.1.7.4) + activemodel (7.2.3) + activesupport (= 7.2.3) + activerecord (7.2.3) + activemodel (= 7.2.3) + activesupport (= 7.2.3) + timeout (>= 0.4.0) + activestorage (7.2.3) + actionpack (= 7.2.3) + activejob (= 7.2.3) + activerecord (= 7.2.3) + activesupport (= 7.2.3) marcel (~> 1.0) - mini_mime (>= 1.1.0) - activesupport (6.1.7.4) - concurrent-ruby (~> 1.0, >= 1.0.2) + activesupport (7.2.3) + base64 + benchmark (>= 0.3) + bigdecimal + concurrent-ruby (~> 1.0, >= 1.3.1) + connection_pool (>= 2.2.5) + drb i18n (>= 1.6, < 2) + logger (>= 1.4.2) minitest (>= 5.1) - tzinfo (~> 2.0) - zeitwerk (~> 2.3) - acts_as_list (0.9.19) - activerecord (>= 3.0) - addressable (2.8.4) - public_suffix (>= 2.0.2, < 6.0) - ast (2.4.2) - axe-core-api (4.7.0) - dumb_delegator - virtus - axe-core-rspec (4.1.0) - axe-core-api - dumb_delegator - virtus - axiom-types (0.1.1) - descendants_tracker (~> 0.0.4) - ice_nine (~> 0.11.0) - thread_safe (~> 0.3, >= 0.3.1) - batch-loader (1.5.0) - bcrypt (3.1.19) - better_html (1.0.16) - actionview (>= 4.0) - activesupport (>= 4.0) + securerandom (>= 0.3) + tzinfo (~> 2.0, >= 2.0.5) + acts_as_list (1.2.6) + activerecord (>= 6.1) + activesupport (>= 6.1) + addressable (2.8.9) + public_suffix (>= 2.0.2, < 8.0) + ast (2.4.3) + base64 (0.3.0) + batch-loader (2.0.6) + bcrypt (3.1.21) + benchmark (0.5.0) + better_html (2.2.0) + actionview (>= 7.0) + activesupport (>= 7.0) ast (~> 2.0) erubi (~> 1.4) - html_tokenizer (~> 0.0.6) parser (>= 2.4) smart_properties + bigdecimal (4.0.1) bindex (0.8.1) - bootsnap (1.16.0) + bootsnap (1.23.0) msgpack (~> 1.2) - browser (2.7.1) - builder (3.2.4) + browser (6.2.0) + builder (3.3.0) + bullet (8.0.8) + activesupport (>= 3.0.0) + uniform_notifier (~> 1.11) byebug (11.1.3) - capybara (3.39.2) + capybara (3.40.0) addressable matrix mini_mime (>= 0.1.3) - nokogiri (~> 1.8) + nokogiri (~> 1.11) rack (>= 1.6.0) rack-test (>= 0.6.3) regexp_parser (>= 1.5, < 3.0) xpath (~> 3.2) - carrierwave (2.2.4) - activemodel (>= 5.0.0) - activesupport (>= 5.0.0) - addressable (~> 2.6) - image_processing (~> 1.1) - marcel (~> 1.0.0) - mini_mime (>= 0.1.3) - ssrf_filter (~> 1.0) - cells (4.1.7) - declarative-builder (< 0.2.0) + cells (4.1.8) + declarative-builder (~> 0.2.0) declarative-option (< 0.2.0) tilt (>= 1.4, < 3) uber (< 0.2.0) cells-erb (0.1.0) cells (~> 4.0) erbse (>= 0.1.1) - cells-rails (0.1.5) + cells-rails (0.1.6) actionpack (>= 5.0) cells (>= 4.1.6, < 5.0.0) - charlock_holmes (0.7.7) - chef-utils (18.2.7) - concurrent-ruby - childprocess (4.1.0) - coercible (1.0.0) - descendants_tracker (~> 0.0.1) - coffee-rails (5.0.0) - coffee-script (>= 2.2.0) - railties (>= 5.2.0) - coffee-script (2.4.1) - coffee-script-source - execjs - coffee-script-source (1.12.2) - commonmarker (0.23.9) - concurrent-ruby (1.2.2) - crack (0.4.5) + cgi (0.5.1) + charlock_holmes (0.7.9) + chartkick (5.1.5) + childprocess (5.1.0) + logger (~> 1.5) + chunky_png (1.4.0) + cmdparse (3.0.7) + commonmarker (0.23.12) + concurrent-ruby (1.3.6) + connection_pool (2.5.5) + crack (1.0.1) + bigdecimal rexml crass (1.0.6) - css_parser (1.14.0) + css_parser (2.0.0) addressable - date (3.3.3) + csv (3.3.5) + data_migrate (11.3.1) + activerecord (>= 6.1) + railties (>= 6.1) + date (3.5.1) date_validator (0.12.0) activemodel (>= 3) activesupport (>= 3) - db-query-matchers (0.10.0) - activesupport (>= 4.0, < 7) - rspec (~> 3.0) - decidim (0.27.3) - decidim-accountability (= 0.27.3) - decidim-admin (= 0.27.3) - decidim-api (= 0.27.3) - decidim-assemblies (= 0.27.3) - decidim-blogs (= 0.27.3) - decidim-budgets (= 0.27.3) - decidim-comments (= 0.27.3) - decidim-core (= 0.27.3) - decidim-debates (= 0.27.3) - decidim-forms (= 0.27.3) - decidim-generators (= 0.27.3) - decidim-meetings (= 0.27.3) - decidim-pages (= 0.27.3) - decidim-participatory_processes (= 0.27.3) - decidim-proposals (= 0.27.3) - decidim-sortitions (= 0.27.3) - decidim-surveys (= 0.27.3) - decidim-system (= 0.27.3) - decidim-templates (= 0.27.3) - decidim-verifications (= 0.27.3) - decidim-accountability (0.27.3) - decidim-comments (= 0.27.3) - decidim-core (= 0.27.3) - decidim-admin (0.27.3) + decidim (0.31.2) + decidim-accountability (= 0.31.2) + decidim-admin (= 0.31.2) + decidim-api (= 0.31.2) + decidim-assemblies (= 0.31.2) + decidim-blogs (= 0.31.2) + decidim-budgets (= 0.31.2) + decidim-comments (= 0.31.2) + decidim-core (= 0.31.2) + decidim-debates (= 0.31.2) + decidim-forms (= 0.31.2) + decidim-generators (= 0.31.2) + decidim-meetings (= 0.31.2) + decidim-pages (= 0.31.2) + decidim-participatory_processes (= 0.31.2) + decidim-proposals (= 0.31.2) + decidim-sortitions (= 0.31.2) + decidim-surveys (= 0.31.2) + decidim-system (= 0.31.2) + decidim-verifications (= 0.31.2) + decidim-accountability (0.31.2) + decidim-comments (= 0.31.2) + decidim-core (= 0.31.2) + decidim-admin (0.31.2) active_link_to (~> 1.0) - decidim-core (= 0.27.3) + decidim-core (= 0.31.2) devise (~> 4.7) devise-i18n (~> 1.2) - devise_invitable (~> 2.0) - decidim-api (0.27.3) - graphql (~> 1.12, < 1.13) - graphql-docs (~> 2.1.0) + devise_invitable (~> 2.0, >= 2.0.9) + decidim-api (0.31.2) + decidim-core (= 0.31.2) + devise-jwt (~> 0.12.1) + graphql (~> 2.4.0, >= 2.4.17) + graphql-docs (~> 5.0) rack-cors (~> 1.0) - decidim-assemblies (0.27.3) - decidim-core (= 0.27.3) - decidim-blogs (0.27.3) - decidim-admin (= 0.27.3) - decidim-comments (= 0.27.3) - decidim-core (= 0.27.3) - decidim-budgets (0.27.3) - decidim-comments (= 0.27.3) - decidim-core (= 0.27.3) - decidim-comments (0.27.3) - decidim-core (= 0.27.3) + decidim-assemblies (0.31.2) + decidim-core (= 0.31.2) + decidim-blogs (0.31.2) + decidim-admin (= 0.31.2) + decidim-comments (= 0.31.2) + decidim-core (= 0.31.2) + decidim-budgets (0.31.2) + decidim-comments (= 0.31.2) + decidim-core (= 0.31.2) + decidim-comments (0.31.2) + decidim-core (= 0.31.2) redcarpet (~> 3.5, >= 3.5.1) - decidim-core (0.27.3) + decidim-core (0.31.2) active_link_to (~> 1.0) - acts_as_list (~> 0.9) - batch-loader (~> 1.2) - browser (~> 2.7) - carrierwave (~> 2.2.1) + acts_as_list (~> 1.0) + batch-loader (~> 2.0) + browser (~> 6.2.0) cells-erb (~> 0.1.0) cells-rails (~> 0.1.3) charlock_holmes (~> 0.7) + chartkick (~> 5.1.2) + concurrent-ruby (~> 1.3.0) + connection_pool (< 3) + data_migrate (~> 11.3) date_validator (~> 0.12.0) - decidim-api (= 0.27.3) devise (~> 4.7) devise-i18n (~> 1.2) diffy (~> 3.3) - doorkeeper (~> 5.1) + doorkeeper (~> 5.6, >= 5.6.6) doorkeeper-i18n (~> 4.0) file_validators (~> 3.0) fog-local (~> 0.6) - foundation_rails_helper (~> 4.0) geocoder (~> 1.8) hashdiff (>= 0.4.0, < 2.0.0) + hexapdf (~> 1.1.0) + image_processing (~> 1.2) invisible_captcha (~> 0.12) kaminari (~> 1.2, >= 1.2.1) - loofah (~> 2.3.1) + loofah (~> 2.19, >= 2.19.1) mime-types (>= 1.16, < 4.0) mini_magick (~> 4.9) - mustache (~> 1.1.0) + net-smtp (~> 0.5.0) + nokogiri (~> 1.16, >= 1.16.2) omniauth (~> 2.0) omniauth-facebook (~> 5.0) omniauth-google-oauth2 (~> 1.0) omniauth-rails_csrf_protection (~> 1.0) omniauth-twitter (~> 1.4) - paper_trail (~> 12.0) - pg (~> 1.1.4, < 2) + paper_trail (~> 16.0) + paranoia (~> 3.0.0) + pg (~> 1.5.0, < 2) pg_search (~> 2.2) premailer-rails (~> 1.10) - rack (~> 2.2, >= 2.2.3) + rack (~> 2.2, >= 2.2.8.1) rack-attack (~> 6.0) - rails (~> 6.1.0) - rails-i18n (~> 6.0) - ransack (~> 2.4.1) + rails (~> 7.2.0, >= 7.2.2.2) + rails-i18n (~> 7.0) + ransack (~> 4.2.0) redis (~> 4.1) - request_store (~> 1.5.0) + request_store (~> 1.7.0) + rqrcode (~> 2.2.0) rubyXL (~> 3.4) rubyzip (~> 2.0) - seven_zip_ruby (~> 1.3) - social-share-button (~> 1.2, >= 1.2.1) - valid_email2 (~> 2.1) - webpacker (= 6.0.0.rc.5) - webpush (~> 1.1) - wisper (~> 2.0) - decidim-debates (0.27.3) - decidim-comments (= 0.27.3) - decidim-core (= 0.27.3) - decidim-dev (0.27.3) - axe-core-rspec (~> 4.1.0) + shakapacker (~> 8.3.0) + valid_email2 (~> 7.0) + web-push (~> 3.0) + wisper (~> 3.0) + decidim-debates (0.31.2) + decidim-comments (= 0.31.2) + decidim-core (= 0.31.2) + decidim-dev (0.31.2) + bullet (~> 8.0.0) byebug (~> 11.0) - capybara (~> 3.24) - db-query-matchers (~> 0.10.0) - decidim (= 0.27.3) - erb_lint (~> 0.0.35) - factory_bot_rails (~> 4.8) - i18n-tasks (~> 0.9.18) - mdl (~> 0.5) - nokogiri (~> 1.13) - parallel_tests (~> 3.7) - puma (~> 5.0) + capybara (~> 3.39) + decidim-admin (= 0.31.2) + decidim-api (= 0.31.2) + decidim-comments (= 0.31.2) + decidim-core (= 0.31.2) + decidim-generators (= 0.31.2) + decidim-verifications (= 0.31.2) + erb_lint (~> 0.8.0) + factory_bot_rails (~> 6.2) + faker (~> 3.2) + i18n-tasks (~> 1.0) + nokogiri (~> 1.16, >= 1.16.2) + parallel_tests (~> 4.2) + puma (~> 6.5) rails-controller-testing (~> 1.0) + rspec (~> 3.12) rspec-cells (~> 0.3.7) - rspec-html-matchers (~> 0.9.1) - rspec-rails (~> 4.0) + rspec-html-matchers (~> 0.10) + rspec-rails (~> 6.0) rspec-retry (~> 0.6.2) - rspec_junit_formatter (~> 0.3.0) - rubocop (~> 1.28.0) - rubocop-rails (~> 2.14) - rubocop-rspec (~> 2.10) - selenium-webdriver (~> 4.1.0) - simplecov (~> 0.21.0) + rspec_junit_formatter (~> 0.6.0) + rubocop (~> 1.78.0) + rubocop-capybara (~> 2.22.0, >= 2.22.1) + rubocop-factory_bot (~> 2.27.0) + rubocop-faker (~> 1.3, >= 1.3.0) + rubocop-graphql (~> 1.5, >= 1.5.6) + rubocop-performance (~> 1.25, >= 1.25.0) + rubocop-rails (~> 2.32.0, >= 2.32.0) + rubocop-rspec (~> 3.0, >= 3.6.0) + rubocop-rspec_rails (~> 2.31.0) + rubocop-rubycw (~> 0.2.0) + selenium-webdriver (~> 4.9) + simplecov (~> 0.22.0) simplecov-cobertura (~> 2.1.0) + spring (~> 4.0) + spring-watcher-listen (~> 2.0) w3c_rspec_validators (~> 0.3.0) - webmock (~> 3.6) + webmock (~> 3.18) wisper-rspec (~> 1.0) - decidim-forms (0.27.3) - decidim-core (= 0.27.3) - wicked_pdf (~> 2.1) - wkhtmltopdf-binary (~> 0.12) - decidim-generators (0.27.3) - decidim-core (= 0.27.3) - decidim-meetings (0.27.3) - decidim-core (= 0.27.3) - decidim-forms (= 0.27.3) + decidim-forms (0.31.2) + decidim-core (= 0.31.2) + decidim-generators (0.31.2) + decidim-core (= 0.31.2) + decidim-meetings (0.31.2) + decidim-core (= 0.31.2) + decidim-forms (= 0.31.2) icalendar (~> 2.5) - decidim-pages (0.27.3) - decidim-core (= 0.27.3) - decidim-participatory_processes (0.27.3) - decidim-core (= 0.27.3) - decidim-proposals (0.27.3) - decidim-comments (= 0.27.3) - decidim-core (= 0.27.3) - doc2text (~> 0.4.5) + decidim-pages (0.31.2) + decidim-core (= 0.31.2) + decidim-participatory_processes (0.31.2) + decidim-core (= 0.31.2) + decidim-proposals (0.31.2) + decidim-comments (= 0.31.2) + decidim-core (= 0.31.2) + doc2text (~> 0.4.0, >= 0.4.8) redcarpet (~> 3.5, >= 3.5.1) - decidim-sortitions (0.27.3) - decidim-admin (= 0.27.3) - decidim-comments (= 0.27.3) - decidim-core (= 0.27.3) - decidim-proposals (= 0.27.3) - decidim-surveys (0.27.3) - decidim-core (= 0.27.3) - decidim-forms (= 0.27.3) - decidim-templates (= 0.27.3) - decidim-system (0.27.3) + decidim-sortitions (0.31.2) + decidim-admin (= 0.31.2) + decidim-comments (= 0.31.2) + decidim-core (= 0.31.2) + decidim-proposals (= 0.31.2) + decidim-surveys (0.31.2) + decidim-core (= 0.31.2) + decidim-forms (= 0.31.2) + decidim-system (0.31.2) active_link_to (~> 1.0) - decidim-core (= 0.27.3) + decidim-core (= 0.31.2) devise (~> 4.7) devise-i18n (~> 1.2) - devise_invitable (~> 2.0) - decidim-templates (0.27.3) - decidim-core (= 0.27.3) - decidim-forms (= 0.27.3) - decidim-verifications (0.27.3) - decidim-core (= 0.27.3) - declarative-builder (0.1.0) - declarative-option (< 0.2.0) + devise_invitable (~> 2.0, >= 2.0.9) + decidim-verifications (0.31.2) + decidim-core (= 0.31.2) + declarative-builder (0.2.0) + trailblazer-option (~> 0.1.0) declarative-option (0.1.0) - descendants_tracker (0.0.4) - thread_safe (~> 0.3, >= 0.3.1) - devise (4.9.2) + devise (4.9.4) bcrypt (~> 3.0) orm_adapter (~> 0.1) railties (>= 4.1.0) responders warden (~> 1.2.3) - devise-i18n (1.11.0) + devise-i18n (1.15.0) devise (>= 4.9.0) - devise_invitable (2.0.8) + rails-i18n + devise-jwt (0.12.1) + devise (~> 4.0) + warden-jwt_auth (~> 0.10) + devise_invitable (2.0.11) actionmailer (>= 5.0) devise (>= 4.6) - diff-lcs (1.5.0) - diffy (3.4.2) - doc2text (0.4.6) - nokogiri (>= 1.13.2, < 1.15.0) + diff-lcs (1.6.2) + diffy (3.4.4) + doc2text (0.4.8) + nokogiri (>= 1.18.2) rubyzip (~> 2.3.0) - docile (1.4.0) - doorkeeper (5.6.6) + docile (1.4.1) + doorkeeper (5.8.2) railties (>= 5) doorkeeper-i18n (4.0.1) - dumb_delegator (1.0.0) - erb_lint (0.0.37) + drb (2.2.3) + dry-auto_inject (1.1.0) + dry-core (~> 1.1) + zeitwerk (~> 2.6) + dry-configurable (1.3.0) + dry-core (~> 1.1) + zeitwerk (~> 2.6) + dry-core (1.2.0) + concurrent-ruby (~> 1.0) + logger + zeitwerk (~> 2.6) + erb (6.0.2) + erb_lint (0.8.0) activesupport - better_html (~> 1.0.7) - html_tokenizer + better_html (>= 2.0.1) parser (>= 2.7.1.4) rainbow - rubocop + rubocop (>= 1) smart_properties erbse (0.1.4) temple - erubi (1.12.0) + erubi (1.13.1) escape_utils (1.3.0) - excon (0.100.0) - execjs (2.8.1) + excon (1.3.2) + logger extended-markdown-filter (0.7.0) html-pipeline (~> 2.9) - factory_bot (4.11.1) - activesupport (>= 3.0.0) - factory_bot_rails (4.11.1) - factory_bot (~> 4.11.1) - railties (>= 3.0.0) - faker (2.23.0) + factory_bot (6.5.6) + activesupport (>= 6.1.0) + factory_bot_rails (6.5.1) + factory_bot (~> 6.5) + railties (>= 6.1.0) + faker (3.5.3) i18n (>= 1.8.11, < 2) - faraday (2.7.9) - faraday-net_http (>= 2.0, < 3.1) - ruby2_keywords (>= 0.0.4) - faraday-net_http (3.0.2) - ffi (1.15.5) + faraday (2.14.1) + faraday-net_http (>= 2.0, < 3.5) + json + logger + faraday-net_http (3.4.2) + net-http (~> 0.5) + ffi (1.17.3-x86_64-darwin) + fiber-storage (1.0.1) file_validators (3.0.0) activemodel (>= 3.2) mime-types (>= 1.0) - fog-core (2.3.0) + fog-core (2.6.0) builder - excon (~> 0.71) + excon (~> 1.0) formatador (>= 0.2, < 2.0) mime-types - fog-local (0.8.0) + fog-local (0.9.0) fog-core (>= 1.27, < 3.0) - formatador (1.1.0) - foundation_rails_helper (4.0.1) - actionpack (>= 4.1, < 7.1) - activemodel (>= 4.1, < 7.1) - activesupport (>= 4.1, < 7.1) - railties (>= 4.1, < 7.1) + formatador (1.2.3) + reline gemoji (3.0.1) - geocoder (1.8.1) - globalid (1.1.0) - activesupport (>= 5.0) - graphql (1.12.24) - graphql-docs (2.1.0) - commonmarker (~> 0.16) + geocoder (1.8.6) + base64 (>= 0.1.0) + csv (>= 3.0.0) + geom2d (0.4.1) + globalid (1.3.0) + activesupport (>= 6.1) + google-protobuf (4.34.0-x86_64-darwin) + bigdecimal + rake (~> 13.3) + graphql (2.4.17) + base64 + fiber-storage + logger + graphql-docs (5.2.0) + commonmarker (~> 0.23, >= 0.23.6) escape_utils (~> 1.2) extended-markdown-filter (~> 0.4) gemoji (~> 3.0) - graphql (~> 1.12) - html-pipeline (~> 2.9) - sass (~> 3.4) - hashdiff (1.0.1) - hashie (5.0.0) - highline (2.1.0) - hkdf (0.3.0) + graphql (~> 2.0) + html-pipeline (~> 2.14, >= 2.14.3) + logger (~> 1.6) + ostruct (~> 0.6) + sass-embedded (~> 1.58) + hashdiff (1.2.1) + hashie (5.1.0) + logger + hexapdf (1.1.1) + cmdparse (~> 3.0, >= 3.0.3) + geom2d (~> 0.4, >= 0.4.1) + openssl (>= 2.2.1) + strscan (>= 3.1.2) + highline (3.1.2) + reline html-pipeline (2.14.3) activesupport (>= 2) nokogiri (>= 1.4) - html_tokenizer (0.0.7) - htmlentities (4.3.4) - i18n (1.14.1) + htmlentities (4.4.2) + i18n (1.14.8) concurrent-ruby (~> 1.0) - i18n-tasks (0.9.37) + i18n-tasks (1.1.2) activesupport (>= 4.0.2) ast (>= 2.1.0) erubi - highline (>= 2.0.0) + highline (>= 3.0.0) i18n - parser (>= 2.2.3.0) + parser (>= 3.2.2.1) + prism rails-i18n rainbow (>= 2.2.2, < 4.0) + ruby-progressbar (~> 1.8, >= 1.8.1) terminal-table (>= 1.5.1) - icalendar (2.8.0) + icalendar (2.12.1) + base64 ice_cube (~> 0.16) - ice_cube (0.16.4) - ice_nine (0.11.2) - image_processing (1.12.2) - mini_magick (>= 4.9.5, < 5) + logger + ostruct + ice_cube (0.17.0) + image_processing (1.14.0) + mini_magick (>= 4.9.5, < 6) ruby-vips (>= 2.0.17, < 3) invisible_captcha (0.13.0) rails (>= 3.2.0) - json (2.6.3) - jwt (2.7.1) + io-console (0.8.2) + irb (1.17.0) + pp (>= 0.6.0) + prism (>= 1.3.0) + rdoc (>= 4.0.0) + reline (>= 0.4.2) + json (2.18.1) + jwt (3.1.2) + base64 kaminari (1.2.2) activesupport (>= 4.1.0) kaminari-actionview (= 1.2.2) @@ -450,308 +499,364 @@ GEM activerecord kaminari-core (= 1.2.2) kaminari-core (1.2.2) - kramdown (2.4.0) - rexml - kramdown-parser-gfm (1.1.0) - kramdown (~> 2.0) - launchy (2.5.2) + language_server-protocol (3.17.0.5) + launchy (3.1.1) addressable (~> 2.8) - letter_opener (1.8.1) - launchy (>= 2.2, < 3) - letter_opener_web (1.4.1) - actionmailer (>= 3.2) - letter_opener (~> 1.0) - railties (>= 3.2) - listen (3.8.0) + childprocess (~> 5.0) + logger (~> 1.6) + letter_opener (1.10.0) + launchy (>= 2.2, < 4) + letter_opener_web (2.0.0) + actionmailer (>= 5.2) + letter_opener (~> 1.7) + railties (>= 5.2) + rexml + lint_roller (1.1.0) + listen (3.10.0) + logger rb-fsevent (~> 0.10, >= 0.10.3) rb-inotify (~> 0.9, >= 0.9.10) - loofah (2.3.1) + logger (1.7.0) + loofah (2.25.0) crass (~> 1.0.2) - nokogiri (>= 1.5.9) - mail (2.8.1) + nokogiri (>= 1.12.0) + mail (2.9.0) + logger mini_mime (>= 0.1.1) net-imap net-pop net-smtp - marcel (1.0.2) - matrix (0.4.2) - mdl (0.12.0) - kramdown (~> 2.3) - kramdown-parser-gfm (~> 1.1) - mixlib-cli (~> 2.1, >= 2.1.1) - mixlib-config (>= 2.2.1, < 4) - mixlib-shellout - method_source (1.0.0) - mime-types (3.4.1) - mime-types-data (~> 3.2015) - mime-types-data (3.2023.0218.1) - mini_magick (4.12.0) - mini_mime (1.1.2) - minitest (5.18.1) - mixlib-cli (2.1.8) - mixlib-config (3.0.27) - tomlrb - mixlib-shellout (3.2.7) - chef-utils - msgpack (1.7.1) - multi_xml (0.6.0) - mustache (1.1.1) - net-imap (0.3.6) + marcel (1.1.0) + matrix (0.4.3) + mime-types (3.7.0) + logger + mime-types-data (~> 3.2025, >= 3.2025.0507) + mime-types-data (3.2026.0224) + mini_magick (4.13.2) + mini_mime (1.1.5) + minitest (6.0.2) + drb (~> 2.0) + prism (~> 1.5) + msgpack (1.8.0) + multi_xml (0.8.1) + bigdecimal (>= 3.1, < 5) + net-http (0.9.1) + uri (>= 0.11.1) + net-imap (0.6.3) date net-protocol net-pop (0.1.2) net-protocol - net-protocol (0.2.1) + net-protocol (0.2.2) timeout - net-smtp (0.3.3) + net-smtp (0.5.1) net-protocol - nio4r (2.5.9) - nokogiri (1.14.5-arm64-darwin) - racc (~> 1.4) - nokogiri (1.14.5-x86_64-linux) + nio4r (2.7.5) + nokogiri (1.19.1-x86_64-darwin) racc (~> 1.4) - oauth (1.1.0) - oauth-tty (~> 1.0, >= 1.0.1) + oauth (1.1.3) + base64 (~> 0.1) + oauth-tty (~> 1.0, >= 1.0.6) snaky_hash (~> 2.0) - version_gem (~> 1.1) - oauth-tty (1.0.5) - version_gem (~> 1.1, >= 1.1.1) - oauth2 (2.0.9) - faraday (>= 0.17.3, < 3.0) - jwt (>= 1.0, < 3.0) + version_gem (~> 1.1, >= 1.1.9) + oauth-tty (1.0.6) + version_gem (~> 1.1, >= 1.1.9) + oauth2 (2.0.18) + faraday (>= 0.17.3, < 4.0) + jwt (>= 1.0, < 4.0) + logger (~> 1.2) multi_xml (~> 0.5) rack (>= 1.2, < 4) - snaky_hash (~> 2.0) - version_gem (~> 1.1) - omniauth (2.1.1) + snaky_hash (~> 2.0, >= 2.0.3) + version_gem (~> 1.1, >= 1.1.9) + omniauth (2.1.4) hashie (>= 3.4.6) + logger rack (>= 2.2.3) rack-protection omniauth-facebook (5.0.0) omniauth-oauth2 (~> 1.2) - omniauth-google-oauth2 (1.1.1) - jwt (>= 2.0) - oauth2 (~> 2.0.6) + omniauth-google-oauth2 (1.2.2) + jwt (>= 2.9.2) + oauth2 (~> 2.0) omniauth (~> 2.0) - omniauth-oauth2 (~> 1.8.0) - omniauth-oauth (1.2.0) + omniauth-oauth2 (~> 1.8) + omniauth-oauth (1.2.1) oauth omniauth (>= 1.0, < 3) - omniauth-oauth2 (1.8.0) - oauth2 (>= 1.4, < 3) + rack (>= 1.6.2, < 4) + omniauth-oauth2 (1.9.0) + oauth2 (>= 2.0.2, < 3) omniauth (~> 2.0) - omniauth-rails_csrf_protection (1.0.1) + omniauth-rails_csrf_protection (1.0.2) actionpack (>= 4.2) omniauth (~> 2.0) omniauth-twitter (1.4.0) omniauth-oauth (~> 1.1) rack + openssl (4.0.1) orm_adapter (0.5.0) - paper_trail (12.3.0) - activerecord (>= 5.2) - request_store (~> 1.1) - parallel (1.23.0) - parallel_tests (3.13.0) + ostruct (0.6.3) + package_json (0.2.0) + paper_trail (16.0.0) + activerecord (>= 6.1) + request_store (~> 1.4) + parallel (1.27.0) + parallel_tests (4.10.1) parallel - parser (3.2.2.3) + paranoia (3.0.1) + activerecord (>= 6, < 8.1) + parser (3.3.10.2) ast (~> 2.4.1) racc - pg (1.1.4) - pg_search (2.3.6) - activerecord (>= 5.2) - activesupport (>= 5.2) - premailer (1.21.0) + pg (1.5.9) + pg_search (2.3.7) + activerecord (>= 6.1) + activesupport (>= 6.1) + pp (0.6.3) + prettyprint + premailer (1.28.0) addressable - css_parser (>= 1.12.0) + css_parser (>= 1.19.0) htmlentities (>= 4.0.0) premailer-rails (1.12.0) actionmailer (>= 3) net-smtp premailer (~> 1.7, >= 1.7.9) - public_suffix (5.0.1) - puma (5.6.6) + prettyprint (0.2.0) + prism (1.9.0) + psych (5.3.1) + date + stringio + public_suffix (7.0.2) + puma (6.6.1) nio4r (~> 2.0) - racc (1.7.1) - rack (2.2.7) - rack-attack (6.6.1) - rack (>= 1.0, < 3) + racc (1.8.1) + rack (2.2.22) + rack-attack (6.8.0) + rack (>= 1.0, < 4) rack-cors (1.1.1) rack (>= 2.0.0) - rack-protection (3.0.6) - rack - rack-proxy (0.7.6) + rack-protection (3.2.0) + base64 (>= 0.1.0) + rack (~> 2.2, >= 2.2.4) + rack-proxy (0.7.7) rack - rack-test (2.1.0) + rack-session (1.0.2) + rack (< 3) + rack-test (2.2.0) rack (>= 1.3) - rails (6.1.7.4) - actioncable (= 6.1.7.4) - actionmailbox (= 6.1.7.4) - actionmailer (= 6.1.7.4) - actionpack (= 6.1.7.4) - actiontext (= 6.1.7.4) - actionview (= 6.1.7.4) - activejob (= 6.1.7.4) - activemodel (= 6.1.7.4) - activerecord (= 6.1.7.4) - activestorage (= 6.1.7.4) - activesupport (= 6.1.7.4) + rackup (1.0.1) + rack (< 3) + webrick + rails (7.2.3) + actioncable (= 7.2.3) + actionmailbox (= 7.2.3) + actionmailer (= 7.2.3) + actionpack (= 7.2.3) + actiontext (= 7.2.3) + actionview (= 7.2.3) + activejob (= 7.2.3) + activemodel (= 7.2.3) + activerecord (= 7.2.3) + activestorage (= 7.2.3) + activesupport (= 7.2.3) bundler (>= 1.15.0) - railties (= 6.1.7.4) - sprockets-rails (>= 2.0.0) + railties (= 7.2.3) rails-controller-testing (1.0.5) actionpack (>= 5.0.1.rc1) actionview (>= 5.0.1.rc1) activesupport (>= 5.0.1.rc1) - rails-dom-testing (2.1.1) + rails-dom-testing (2.3.0) activesupport (>= 5.0.0) minitest nokogiri (>= 1.6) - rails-html-sanitizer (1.4.3) - loofah (~> 2.3) - rails-i18n (6.0.0) + rails-html-sanitizer (1.7.0) + loofah (~> 2.25) + nokogiri (>= 1.15.7, != 1.16.7, != 1.16.6, != 1.16.5, != 1.16.4, != 1.16.3, != 1.16.2, != 1.16.1, != 1.16.0.rc1, != 1.16.0) + rails-i18n (7.0.10) i18n (>= 0.7, < 2) - railties (>= 6.0.0, < 7) - railties (6.1.7.4) - actionpack (= 6.1.7.4) - activesupport (= 6.1.7.4) - method_source + railties (>= 6.0.0, < 8) + railties (7.2.3) + actionpack (= 7.2.3) + activesupport (= 7.2.3) + cgi + irb (~> 1.13) + rackup (>= 1.0.0) rake (>= 12.2) - thor (~> 1.0) + thor (~> 1.0, >= 1.2.2) + tsort (>= 0.2) + zeitwerk (~> 2.6) rainbow (3.1.1) - rake (13.0.6) - ransack (2.4.2) - activerecord (>= 5.2.4) - activesupport (>= 5.2.4) + rake (13.3.1) + ransack (4.2.1) + activerecord (>= 6.1.5) + activesupport (>= 6.1.5) i18n rb-fsevent (0.11.2) - rb-inotify (0.10.1) + rb-inotify (0.11.1) ffi (~> 1.0) - redcarpet (3.6.0) + rdoc (7.2.0) + erb + psych (>= 4.0.0) + tsort + redcarpet (3.6.1) redis (4.8.1) - regexp_parser (2.8.1) - request_store (1.5.1) + regexp_parser (2.11.3) + reline (0.6.3) + io-console (~> 0.5) + request_store (1.7.0) rack (>= 1.4) - responders (3.1.0) - actionpack (>= 5.2) - railties (>= 5.2) - rexml (3.2.5) - rspec (3.12.0) - rspec-core (~> 3.12.0) - rspec-expectations (~> 3.12.0) - rspec-mocks (~> 3.12.0) - rspec-cells (0.3.8) + responders (3.2.0) + actionpack (>= 7.0) + railties (>= 7.0) + rexml (3.4.4) + rqrcode (2.2.0) + chunky_png (~> 1.0) + rqrcode_core (~> 1.0) + rqrcode_core (1.2.0) + rspec (3.13.2) + rspec-core (~> 3.13.0) + rspec-expectations (~> 3.13.0) + rspec-mocks (~> 3.13.0) + rspec-cells (0.3.10) cells (>= 4.0.0, < 6.0.0) - rspec-rails (>= 3.0.0, < 6.1.0) - rspec-core (3.12.2) - rspec-support (~> 3.12.0) - rspec-expectations (3.12.3) + rspec-rails (>= 3.0.0) + rspec-core (3.13.6) + rspec-support (~> 3.13.0) + rspec-expectations (3.13.5) diff-lcs (>= 1.2.0, < 2.0) - rspec-support (~> 3.12.0) - rspec-html-matchers (0.9.4) + rspec-support (~> 3.13.0) + rspec-html-matchers (0.10.0) nokogiri (~> 1) - rspec (>= 3.0.0.a, < 4) - rspec-mocks (3.12.5) + rspec (>= 3.0.0.a) + rspec-mocks (3.13.8) diff-lcs (>= 1.2.0, < 2.0) - rspec-support (~> 3.12.0) - rspec-rails (4.1.2) - actionpack (>= 4.2) - activesupport (>= 4.2) - railties (>= 4.2) - rspec-core (~> 3.10) - rspec-expectations (~> 3.10) - rspec-mocks (~> 3.10) - rspec-support (~> 3.10) + rspec-support (~> 3.13.0) + rspec-rails (6.1.5) + actionpack (>= 6.1) + activesupport (>= 6.1) + railties (>= 6.1) + rspec-core (~> 3.13) + rspec-expectations (~> 3.13) + rspec-mocks (~> 3.13) + rspec-support (~> 3.13) rspec-retry (0.6.2) rspec-core (> 3.3) - rspec-support (3.12.1) - rspec_junit_formatter (0.3.0) + rspec-support (3.13.7) + rspec_junit_formatter (0.6.0) rspec-core (>= 2, < 4, != 2.12.0) - rubocop (1.28.2) + rubocop (1.78.0) + json (~> 2.3) + language_server-protocol (~> 3.17.0.2) + lint_roller (~> 1.1.0) parallel (~> 1.10) - parser (>= 3.1.0.0) + parser (>= 3.3.0.2) rainbow (>= 2.2.2, < 4.0) - regexp_parser (>= 1.8, < 3.0) - rexml - rubocop-ast (>= 1.17.0, < 2.0) + regexp_parser (>= 2.9.3, < 3.0) + rubocop-ast (>= 1.45.1, < 2.0) ruby-progressbar (~> 1.7) - unicode-display_width (>= 1.4.0, < 3.0) - rubocop-ast (1.29.0) - parser (>= 3.2.1.0) - rubocop-faker (1.1.0) + unicode-display_width (>= 2.4.0, < 4.0) + rubocop-ast (1.49.0) + parser (>= 3.3.7.2) + prism (~> 1.7) + rubocop-capybara (2.22.1) + lint_roller (~> 1.1) + rubocop (~> 1.72, >= 1.72.1) + rubocop-factory_bot (2.27.1) + lint_roller (~> 1.1) + rubocop (~> 1.72, >= 1.72.1) + rubocop-faker (1.3.0) faker (>= 2.12.0) - rubocop (>= 0.82.0) - rubocop-rails (2.15.2) + lint_roller (~> 1.1) + rubocop (>= 1.72.1) + rubocop-graphql (1.6.0) + lint_roller (~> 1.1) + rubocop (>= 1.72.1, < 2) + rubocop-performance (1.26.1) + lint_roller (~> 1.1) + rubocop (>= 1.75.0, < 2.0) + rubocop-ast (>= 1.47.1, < 2.0) + rubocop-rails (2.32.0) activesupport (>= 4.2.0) + lint_roller (~> 1.1) rack (>= 1.1) - rubocop (>= 1.7.0, < 2.0) - rubocop-rspec (2.11.1) - rubocop (~> 1.19) + rubocop (>= 1.75.0, < 2.0) + rubocop-ast (>= 1.44.0, < 2.0) + rubocop-rspec (3.7.0) + lint_roller (~> 1.1) + rubocop (~> 1.72, >= 1.72.1) + rubocop-rspec_rails (2.31.0) + lint_roller (~> 1.1) + rubocop (~> 1.72, >= 1.72.1) + rubocop-rspec (~> 3.5) + rubocop-rubycw (0.2.2) + lint_roller (~> 1.1) + rubocop (~> 1.72, >= 1.72.1) ruby-progressbar (1.13.0) - ruby-vips (2.1.4) + ruby-vips (2.3.0) ffi (~> 1.12) - ruby2_keywords (0.0.5) - rubyXL (3.4.25) + logger + rubyXL (3.4.33) nokogiri (>= 1.10.8) rubyzip (>= 1.3.0) rubyzip (2.3.2) - sass (3.7.4) - sass-listen (~> 4.0.0) - sass-listen (4.0.0) - rb-fsevent (~> 0.9, >= 0.9.4) - rb-inotify (~> 0.9, >= 0.9.7) - selenium-webdriver (4.1.0) - childprocess (>= 0.5, < 5.0) + sass-embedded (1.97.3-x86_64-darwin) + google-protobuf (~> 4.31) + securerandom (0.4.1) + selenium-webdriver (4.41.0) + base64 (~> 0.2) + logger (~> 1.4) rexml (~> 3.2, >= 3.2.5) - rubyzip (>= 1.2.2) - semantic_range (3.0.0) - seven_zip_ruby (1.3.0) - simplecov (0.21.2) + rubyzip (>= 1.2.2, < 4.0) + websocket (~> 1.0) + semantic_range (3.1.1) + shakapacker (8.3.0) + activesupport (>= 5.2) + package_json + rack-proxy (>= 0.6.1) + railties (>= 5.2) + semantic_range (>= 2.3.0) + simplecov (0.22.0) docile (~> 1.1) simplecov-html (~> 0.11) simplecov_json_formatter (~> 0.1) simplecov-cobertura (2.1.0) rexml simplecov (~> 0.19) - simplecov-html (0.12.3) + simplecov-html (0.13.2) simplecov_json_formatter (0.1.4) smart_properties (1.17.0) - snaky_hash (2.0.1) - hashie - version_gem (~> 1.1, >= 1.1.1) - social-share-button (1.2.4) - coffee-rails - spring (2.1.1) - spring-watcher-listen (2.0.1) + snaky_hash (2.0.3) + hashie (>= 0.1.0, < 6) + version_gem (>= 1.1.8, < 3) + spring (4.4.2) + spring-watcher-listen (2.1.0) listen (>= 2.7, < 4.0) - spring (>= 1.2, < 3.0) - sprockets (4.2.0) - concurrent-ruby (~> 1.0) - rack (>= 2.2.4, < 4) - sprockets-rails (3.4.2) - actionpack (>= 5.2) - activesupport (>= 5.2) - sprockets (>= 3.0.0) - ssrf_filter (1.1.1) - temple (0.10.2) - terminal-table (3.0.2) - unicode-display_width (>= 1.1.1, < 3) - thor (1.2.2) - thread_safe (0.3.6) - tilt (2.2.0) - timeout (0.4.0) - tomlrb (2.0.3) + spring (>= 4) + stringio (3.2.0) + strscan (3.1.7) + temple (0.10.4) + terminal-table (4.0.0) + unicode-display_width (>= 1.1.1, < 4) + thor (1.5.0) + tilt (2.7.0) + timeout (0.6.0) + trailblazer-option (0.1.2) + tsort (0.2.0) tzinfo (2.0.6) concurrent-ruby (~> 1.0) uber (0.1.0) - unicode-display_width (2.4.2) - valid_email2 (2.3.1) - activemodel (>= 3.2) + unicode-display_width (3.2.0) + unicode-emoji (~> 4.1) + unicode-emoji (4.2.0) + uniform_notifier (1.18.0) + uri (1.1.1) + useragent (0.16.11) + valid_email2 (7.0.15) + activemodel (>= 6.0) mail (~> 2.5) - version_gem (1.1.3) - virtus (2.0.0) - axiom-types (~> 0.1) - coercible (~> 1.0) - descendants_tracker (~> 0.0, >= 0.0.3) + version_gem (1.1.9) w3c_rspec_validators (0.3.0) rails rspec @@ -762,56 +867,55 @@ GEM rexml (~> 3.2) warden (1.2.9) rack (>= 2.0.9) - web-console (4.0.4) + warden-jwt_auth (0.12.0) + dry-auto_inject (>= 0.8, < 2) + dry-configurable (>= 0.13, < 2) + jwt (>= 2.1, < 4) + warden (~> 1.2) + web-console (4.2.1) actionview (>= 6.0.0) activemodel (>= 6.0.0) bindex (>= 0.4.0) railties (>= 6.0.0) - webmock (3.18.1) + web-push (3.1.0) + jwt (~> 3.0) + openssl (>= 3.0) + webmock (3.26.1) addressable (>= 2.8.0) crack (>= 0.3.2) hashdiff (>= 0.4.0, < 2.0.0) - webpacker (6.0.0.rc.5) - activesupport (>= 5.2) - rack-proxy (>= 0.6.1) - railties (>= 5.2) - semantic_range (>= 2.3.0) - webpush (1.1.0) - hkdf (~> 0.2) - jwt (~> 2.0) - websocket-driver (0.7.5) + webrick (1.9.2) + websocket (1.2.11) + websocket-driver (0.8.0) + base64 websocket-extensions (>= 0.1.0) websocket-extensions (0.1.5) - wicked_pdf (2.6.3) - activesupport - wisper (2.0.1) + wisper (3.0.0) wisper-rspec (1.1.0) - wkhtmltopdf-binary (0.12.6.6) xpath (3.2.0) nokogiri (~> 1.8) - zeitwerk (2.6.8) + zeitwerk (2.7.5) PLATFORMS - arm64-darwin-22 - x86_64-linux + x86_64-darwin DEPENDENCIES bootsnap (~> 1.4) byebug (~> 11.0) decidim decidim-budgets_importer! - decidim-dev - faker (~> 2.14) - letter_opener_web (~> 1.3) + decidim-dev (~> 0.31) + faker (= 3.5.3) + letter_opener_web (~> 2.0) listen (~> 3.1) - puma (>= 5.5.1) + puma (>= 6.3.1) rubocop-faker - spring (~> 2.0) + spring (~> 4.0) spring-watcher-listen (~> 2.0) - web-console (~> 4.0.4) + web-console (~> 4.2) RUBY VERSION - ruby 3.0.2p107 + ruby 3.3.4p94 BUNDLED WITH - 2.4.9 + 2.5.22 diff --git a/decidim-budgets_importer.gemspec b/decidim-budgets_importer.gemspec index 59d6e63..a324bd6 100644 --- a/decidim-budgets_importer.gemspec +++ b/decidim-budgets_importer.gemspec @@ -17,7 +17,7 @@ Gem::Specification.new do |s| "homepage_uri" => "https://decidim.org", "source_code_uri" => "https://github.com/decidim/decidim" } - s.required_ruby_version = ">= 3.0" + s.required_ruby_version = ">= 3.3" s.name = "decidim-budgets_importer" s.summary = "A decidim budgets_importer module" diff --git a/lib/decidim/budgets_importer/version.rb b/lib/decidim/budgets_importer/version.rb index ff4e126..ca6416d 100644 --- a/lib/decidim/budgets_importer/version.rb +++ b/lib/decidim/budgets_importer/version.rb @@ -4,11 +4,11 @@ module Decidim # This holds the decidim-meetings version. module BudgetsImporter def self.version - "2.0.0" + "3.0.0" end def self.decidim_version - "0.27" + "0.31.2" end end end diff --git a/package-lock.json b/package-lock.json new file mode 100644 index 0000000..575f048 --- /dev/null +++ b/package-lock.json @@ -0,0 +1,466 @@ +{ + "name": "decidim-module-budgets_importer", + "lockfileVersion": 3, + "requires": true, + "packages": { + "": { + "devDependencies": { + "@tiptap/extension-dropcursor": "^2.1.13" + } + }, + "node_modules/@remirror/core-constants": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/@remirror/core-constants/-/core-constants-3.0.0.tgz", + "integrity": "sha512-42aWfPrimMfDKDi4YegyS7x+/0tlzaqwPQCULLanv3DMIlu96KTJR0fM5isWX2UViOqlGnX6YFgqWepcX+XMNg==", + "dev": true, + "license": "MIT", + "peer": true + }, + "node_modules/@tiptap/core": { + "version": "2.27.2", + "resolved": "https://registry.npmjs.org/@tiptap/core/-/core-2.27.2.tgz", + "integrity": "sha512-ABL1N6eoxzDzC1bYvkMbvyexHacszsKdVPYqhl5GwHLOvpZcv9VE9QaKwDILTyz5voCA0lGcAAXZp+qnXOk5lQ==", + "dev": true, + "license": "MIT", + "peer": true, + "funding": { + "type": "github", + "url": "https://github.com/sponsors/ueberdosis" + }, + "peerDependencies": { + "@tiptap/pm": "^2.7.0" + } + }, + "node_modules/@tiptap/extension-dropcursor": { + "version": "2.27.2", + "resolved": "https://registry.npmjs.org/@tiptap/extension-dropcursor/-/extension-dropcursor-2.27.2.tgz", + "integrity": "sha512-oEu/OrktNoQXq1x29NnH/GOIzQZm8ieTQl3FK27nxfBPA89cNoH4mFEUmBL5/OFIENIjiYG3qWpg6voIqzswNw==", + "dev": true, + "license": "MIT", + "funding": { + "type": "github", + "url": "https://github.com/sponsors/ueberdosis" + }, + "peerDependencies": { + "@tiptap/core": "^2.7.0", + "@tiptap/pm": "^2.7.0" + } + }, + "node_modules/@tiptap/pm": { + "version": "2.27.2", + "resolved": "https://registry.npmjs.org/@tiptap/pm/-/pm-2.27.2.tgz", + "integrity": "sha512-kaEg7BfiJPDQMKbjVIzEPO3wlcA+pZb2tlcK9gPrdDnEFaec2QTF1sXz2ak2IIb2curvnIrQ4yrfHgLlVA72wA==", + "dev": true, + "license": "MIT", + "peer": true, + "dependencies": { + "prosemirror-changeset": "^2.3.0", + "prosemirror-collab": "^1.3.1", + "prosemirror-commands": "^1.6.2", + "prosemirror-dropcursor": "^1.8.1", + "prosemirror-gapcursor": "^1.3.2", + "prosemirror-history": "^1.4.1", + "prosemirror-inputrules": "^1.4.0", + "prosemirror-keymap": "^1.2.2", + "prosemirror-markdown": "^1.13.1", + "prosemirror-menu": "^1.2.4", + "prosemirror-model": "^1.23.0", + "prosemirror-schema-basic": "^1.2.3", + "prosemirror-schema-list": "^1.4.1", + "prosemirror-state": "^1.4.3", + "prosemirror-tables": "^1.6.4", + "prosemirror-trailing-node": "^3.0.0", + "prosemirror-transform": "^1.10.2", + "prosemirror-view": "^1.37.0" + }, + "funding": { + "type": "github", + "url": "https://github.com/sponsors/ueberdosis" + } + }, + "node_modules/@types/linkify-it": { + "version": "5.0.0", + "resolved": "https://registry.npmjs.org/@types/linkify-it/-/linkify-it-5.0.0.tgz", + "integrity": "sha512-sVDA58zAw4eWAffKOaQH5/5j3XeayukzDk+ewSsnv3p4yJEZHCCzMDiZM8e0OUrRvmpGZ85jf4yDHkHsgBNr9Q==", + "dev": true, + "license": "MIT", + "peer": true + }, + "node_modules/@types/markdown-it": { + "version": "14.1.2", + "resolved": "https://registry.npmjs.org/@types/markdown-it/-/markdown-it-14.1.2.tgz", + "integrity": "sha512-promo4eFwuiW+TfGxhi+0x3czqTYJkG8qB17ZUJiVF10Xm7NLVRSLUsfRTU/6h1e24VvRnXCx+hG7li58lkzog==", + "dev": true, + "license": "MIT", + "peer": true, + "dependencies": { + "@types/linkify-it": "^5", + "@types/mdurl": "^2" + } + }, + "node_modules/@types/mdurl": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/@types/mdurl/-/mdurl-2.0.0.tgz", + "integrity": "sha512-RGdgjQUZba5p6QEFAVx2OGb8rQDL/cPRG7GiedRzMcJ1tYnUANBncjbSB1NRGwbvjcPeikRABz2nshyPk1bhWg==", + "dev": true, + "license": "MIT", + "peer": true + }, + "node_modules/argparse": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/argparse/-/argparse-2.0.1.tgz", + "integrity": "sha512-8+9WqebbFzpX9OR+Wa6O29asIogeRMzcGtAINdpMHHyAg10f05aSFVBbcEqGf/PXw1EjAZ+q2/bEBg3DvurK3Q==", + "dev": true, + "license": "Python-2.0", + "peer": true + }, + "node_modules/crelt": { + "version": "1.0.6", + "resolved": "https://registry.npmjs.org/crelt/-/crelt-1.0.6.tgz", + "integrity": "sha512-VQ2MBenTq1fWZUH9DJNGti7kKv6EeAuYr3cLwxUWhIu1baTaXh4Ib5W2CqHVqib4/MqbYGJqiL3Zb8GJZr3l4g==", + "dev": true, + "license": "MIT", + "peer": true + }, + "node_modules/entities": { + "version": "4.5.0", + "resolved": "https://registry.npmjs.org/entities/-/entities-4.5.0.tgz", + "integrity": "sha512-V0hjH4dGPh9Ao5p0MoRY6BVqtwCjhz6vI5LT8AJ55H+4g9/4vbHx1I54fS0XuclLhDHArPQCiMjDxjaL8fPxhw==", + "dev": true, + "license": "BSD-2-Clause", + "peer": true, + "engines": { + "node": ">=0.12" + }, + "funding": { + "url": "https://github.com/fb55/entities?sponsor=1" + } + }, + "node_modules/escape-string-regexp": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/escape-string-regexp/-/escape-string-regexp-4.0.0.tgz", + "integrity": "sha512-TtpcNJ3XAzx3Gq8sWRzJaVajRs0uVxA2YAkdb1jm2YkPz4G6egUFAyA3n5vtEIZefPk5Wa4UXbKuS5fKkJWdgA==", + "dev": true, + "license": "MIT", + "peer": true, + "engines": { + "node": ">=10" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "node_modules/linkify-it": { + "version": "5.0.0", + "resolved": "https://registry.npmjs.org/linkify-it/-/linkify-it-5.0.0.tgz", + "integrity": "sha512-5aHCbzQRADcdP+ATqnDuhhJ/MRIqDkZX5pyjFHRRysS8vZ5AbqGEoFIb6pYHPZ+L/OC2Lc+xT8uHVVR5CAK/wQ==", + "dev": true, + "license": "MIT", + "peer": true, + "dependencies": { + "uc.micro": "^2.0.0" + } + }, + "node_modules/markdown-it": { + "version": "14.1.1", + "resolved": "https://registry.npmjs.org/markdown-it/-/markdown-it-14.1.1.tgz", + "integrity": "sha512-BuU2qnTti9YKgK5N+IeMubp14ZUKUUw7yeJbkjtosvHiP0AZ5c8IAgEMk79D0eC8F23r4Ac/q8cAIFdm2FtyoA==", + "dev": true, + "license": "MIT", + "peer": true, + "dependencies": { + "argparse": "^2.0.1", + "entities": "^4.4.0", + "linkify-it": "^5.0.0", + "mdurl": "^2.0.0", + "punycode.js": "^2.3.1", + "uc.micro": "^2.1.0" + }, + "bin": { + "markdown-it": "bin/markdown-it.mjs" + } + }, + "node_modules/mdurl": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/mdurl/-/mdurl-2.0.0.tgz", + "integrity": "sha512-Lf+9+2r+Tdp5wXDXC4PcIBjTDtq4UKjCPMQhKIuzpJNW0b96kVqSwW0bT7FhRSfmAiFYgP+SCRvdrDozfh0U5w==", + "dev": true, + "license": "MIT", + "peer": true + }, + "node_modules/orderedmap": { + "version": "2.1.1", + "resolved": "https://registry.npmjs.org/orderedmap/-/orderedmap-2.1.1.tgz", + "integrity": "sha512-TvAWxi0nDe1j/rtMcWcIj94+Ffe6n7zhow33h40SKxmsmozs6dz/e+EajymfoFcHd7sxNn8yHM8839uixMOV6g==", + "dev": true, + "license": "MIT", + "peer": true + }, + "node_modules/prosemirror-changeset": { + "version": "2.4.0", + "resolved": "https://registry.npmjs.org/prosemirror-changeset/-/prosemirror-changeset-2.4.0.tgz", + "integrity": "sha512-LvqH2v7Q2SF6yxatuPP2e8vSUKS/L+xAU7dPDC4RMyHMhZoGDfBC74mYuyYF4gLqOEG758wajtyhNnsTkuhvng==", + "dev": true, + "license": "MIT", + "peer": true, + "dependencies": { + "prosemirror-transform": "^1.0.0" + } + }, + "node_modules/prosemirror-collab": { + "version": "1.3.1", + "resolved": "https://registry.npmjs.org/prosemirror-collab/-/prosemirror-collab-1.3.1.tgz", + "integrity": "sha512-4SnynYR9TTYaQVXd/ieUvsVV4PDMBzrq2xPUWutHivDuOshZXqQ5rGbZM84HEaXKbLdItse7weMGOUdDVcLKEQ==", + "dev": true, + "license": "MIT", + "peer": true, + "dependencies": { + "prosemirror-state": "^1.0.0" + } + }, + "node_modules/prosemirror-commands": { + "version": "1.7.1", + "resolved": "https://registry.npmjs.org/prosemirror-commands/-/prosemirror-commands-1.7.1.tgz", + "integrity": "sha512-rT7qZnQtx5c0/y/KlYaGvtG411S97UaL6gdp6RIZ23DLHanMYLyfGBV5DtSnZdthQql7W+lEVbpSfwtO8T+L2w==", + "dev": true, + "license": "MIT", + "peer": true, + "dependencies": { + "prosemirror-model": "^1.0.0", + "prosemirror-state": "^1.0.0", + "prosemirror-transform": "^1.10.2" + } + }, + "node_modules/prosemirror-dropcursor": { + "version": "1.8.2", + "resolved": "https://registry.npmjs.org/prosemirror-dropcursor/-/prosemirror-dropcursor-1.8.2.tgz", + "integrity": "sha512-CCk6Gyx9+Tt2sbYk5NK0nB1ukHi2ryaRgadV/LvyNuO3ena1payM2z6Cg0vO1ebK8cxbzo41ku2DE5Axj1Zuiw==", + "dev": true, + "license": "MIT", + "peer": true, + "dependencies": { + "prosemirror-state": "^1.0.0", + "prosemirror-transform": "^1.1.0", + "prosemirror-view": "^1.1.0" + } + }, + "node_modules/prosemirror-gapcursor": { + "version": "1.4.0", + "resolved": "https://registry.npmjs.org/prosemirror-gapcursor/-/prosemirror-gapcursor-1.4.0.tgz", + "integrity": "sha512-z00qvurSdCEWUIulij/isHaqu4uLS8r/Fi61IbjdIPJEonQgggbJsLnstW7Lgdk4zQ68/yr6B6bf7sJXowIgdQ==", + "dev": true, + "license": "MIT", + "peer": true, + "dependencies": { + "prosemirror-keymap": "^1.0.0", + "prosemirror-model": "^1.0.0", + "prosemirror-state": "^1.0.0", + "prosemirror-view": "^1.0.0" + } + }, + "node_modules/prosemirror-history": { + "version": "1.5.0", + "resolved": "https://registry.npmjs.org/prosemirror-history/-/prosemirror-history-1.5.0.tgz", + "integrity": "sha512-zlzTiH01eKA55UAf1MEjtssJeHnGxO0j4K4Dpx+gnmX9n+SHNlDqI2oO1Kv1iPN5B1dm5fsljCfqKF9nFL6HRg==", + "dev": true, + "license": "MIT", + "peer": true, + "dependencies": { + "prosemirror-state": "^1.2.2", + "prosemirror-transform": "^1.0.0", + "prosemirror-view": "^1.31.0", + "rope-sequence": "^1.3.0" + } + }, + "node_modules/prosemirror-inputrules": { + "version": "1.5.1", + "resolved": "https://registry.npmjs.org/prosemirror-inputrules/-/prosemirror-inputrules-1.5.1.tgz", + "integrity": "sha512-7wj4uMjKaXWAQ1CDgxNzNtR9AlsuwzHfdFH1ygEHA2KHF2DOEaXl1CJfNPAKCg9qNEh4rum975QLaCiQPyY6Fw==", + "dev": true, + "license": "MIT", + "peer": true, + "dependencies": { + "prosemirror-state": "^1.0.0", + "prosemirror-transform": "^1.0.0" + } + }, + "node_modules/prosemirror-keymap": { + "version": "1.2.3", + "resolved": "https://registry.npmjs.org/prosemirror-keymap/-/prosemirror-keymap-1.2.3.tgz", + "integrity": "sha512-4HucRlpiLd1IPQQXNqeo81BGtkY8Ai5smHhKW9jjPKRc2wQIxksg7Hl1tTI2IfT2B/LgX6bfYvXxEpJl7aKYKw==", + "dev": true, + "license": "MIT", + "peer": true, + "dependencies": { + "prosemirror-state": "^1.0.0", + "w3c-keyname": "^2.2.0" + } + }, + "node_modules/prosemirror-markdown": { + "version": "1.13.4", + "resolved": "https://registry.npmjs.org/prosemirror-markdown/-/prosemirror-markdown-1.13.4.tgz", + "integrity": "sha512-D98dm4cQ3Hs6EmjK500TdAOew4Z03EV71ajEFiWra3Upr7diytJsjF4mPV2dW+eK5uNectiRj0xFxYI9NLXDbw==", + "dev": true, + "license": "MIT", + "peer": true, + "dependencies": { + "@types/markdown-it": "^14.0.0", + "markdown-it": "^14.0.0", + "prosemirror-model": "^1.25.0" + } + }, + "node_modules/prosemirror-menu": { + "version": "1.3.0", + "resolved": "https://registry.npmjs.org/prosemirror-menu/-/prosemirror-menu-1.3.0.tgz", + "integrity": "sha512-TImyPXCHPcDsSka2/lwJ6WjTASr4re/qWq1yoTTuLOqfXucwF6VcRa2LWCkM/EyTD1UO3CUwiH8qURJoWJRxwg==", + "dev": true, + "license": "MIT", + "peer": true, + "dependencies": { + "crelt": "^1.0.0", + "prosemirror-commands": "^1.0.0", + "prosemirror-history": "^1.0.0", + "prosemirror-state": "^1.0.0" + } + }, + "node_modules/prosemirror-model": { + "version": "1.25.4", + "resolved": "https://registry.npmjs.org/prosemirror-model/-/prosemirror-model-1.25.4.tgz", + "integrity": "sha512-PIM7E43PBxKce8OQeezAs9j4TP+5yDpZVbuurd1h5phUxEKIu+G2a+EUZzIC5nS1mJktDJWzbqS23n1tsAf5QA==", + "dev": true, + "license": "MIT", + "peer": true, + "dependencies": { + "orderedmap": "^2.0.0" + } + }, + "node_modules/prosemirror-schema-basic": { + "version": "1.2.4", + "resolved": "https://registry.npmjs.org/prosemirror-schema-basic/-/prosemirror-schema-basic-1.2.4.tgz", + "integrity": "sha512-ELxP4TlX3yr2v5rM7Sb70SqStq5NvI15c0j9j/gjsrO5vaw+fnnpovCLEGIcpeGfifkuqJwl4fon6b+KdrODYQ==", + "dev": true, + "license": "MIT", + "peer": true, + "dependencies": { + "prosemirror-model": "^1.25.0" + } + }, + "node_modules/prosemirror-schema-list": { + "version": "1.5.1", + "resolved": "https://registry.npmjs.org/prosemirror-schema-list/-/prosemirror-schema-list-1.5.1.tgz", + "integrity": "sha512-927lFx/uwyQaGwJxLWCZRkjXG0p48KpMj6ueoYiu4JX05GGuGcgzAy62dfiV8eFZftgyBUvLx76RsMe20fJl+Q==", + "dev": true, + "license": "MIT", + "peer": true, + "dependencies": { + "prosemirror-model": "^1.0.0", + "prosemirror-state": "^1.0.0", + "prosemirror-transform": "^1.7.3" + } + }, + "node_modules/prosemirror-state": { + "version": "1.4.4", + "resolved": "https://registry.npmjs.org/prosemirror-state/-/prosemirror-state-1.4.4.tgz", + "integrity": "sha512-6jiYHH2CIGbCfnxdHbXZ12gySFY/fz/ulZE333G6bPqIZ4F+TXo9ifiR86nAHpWnfoNjOb3o5ESi7J8Uz1jXHw==", + "dev": true, + "license": "MIT", + "peer": true, + "dependencies": { + "prosemirror-model": "^1.0.0", + "prosemirror-transform": "^1.0.0", + "prosemirror-view": "^1.27.0" + } + }, + "node_modules/prosemirror-tables": { + "version": "1.8.5", + "resolved": "https://registry.npmjs.org/prosemirror-tables/-/prosemirror-tables-1.8.5.tgz", + "integrity": "sha512-V/0cDCsHKHe/tfWkeCmthNUcEp1IVO3p6vwN8XtwE9PZQLAZJigbw3QoraAdfJPir4NKJtNvOB8oYGKRl+t0Dw==", + "dev": true, + "license": "MIT", + "peer": true, + "dependencies": { + "prosemirror-keymap": "^1.2.3", + "prosemirror-model": "^1.25.4", + "prosemirror-state": "^1.4.4", + "prosemirror-transform": "^1.10.5", + "prosemirror-view": "^1.41.4" + } + }, + "node_modules/prosemirror-trailing-node": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/prosemirror-trailing-node/-/prosemirror-trailing-node-3.0.0.tgz", + "integrity": "sha512-xiun5/3q0w5eRnGYfNlW1uU9W6x5MoFKWwq/0TIRgt09lv7Hcser2QYV8t4muXbEr+Fwo0geYn79Xs4GKywrRQ==", + "dev": true, + "license": "MIT", + "peer": true, + "dependencies": { + "@remirror/core-constants": "3.0.0", + "escape-string-regexp": "^4.0.0" + }, + "peerDependencies": { + "prosemirror-model": "^1.22.1", + "prosemirror-state": "^1.4.2", + "prosemirror-view": "^1.33.8" + } + }, + "node_modules/prosemirror-transform": { + "version": "1.11.0", + "resolved": "https://registry.npmjs.org/prosemirror-transform/-/prosemirror-transform-1.11.0.tgz", + "integrity": "sha512-4I7Ce4KpygXb9bkiPS3hTEk4dSHorfRw8uI0pE8IhxlK2GXsqv5tIA7JUSxtSu7u8APVOTtbUBxTmnHIxVkIJw==", + "dev": true, + "license": "MIT", + "peer": true, + "dependencies": { + "prosemirror-model": "^1.21.0" + } + }, + "node_modules/prosemirror-view": { + "version": "1.41.6", + "resolved": "https://registry.npmjs.org/prosemirror-view/-/prosemirror-view-1.41.6.tgz", + "integrity": "sha512-mxpcDG4hNQa/CPtzxjdlir5bJFDlm0/x5nGBbStB2BWX+XOQ9M8ekEG+ojqB5BcVu2Rc80/jssCMZzSstJuSYg==", + "dev": true, + "license": "MIT", + "peer": true, + "dependencies": { + "prosemirror-model": "^1.20.0", + "prosemirror-state": "^1.0.0", + "prosemirror-transform": "^1.1.0" + } + }, + "node_modules/punycode.js": { + "version": "2.3.1", + "resolved": "https://registry.npmjs.org/punycode.js/-/punycode.js-2.3.1.tgz", + "integrity": "sha512-uxFIHU0YlHYhDQtV4R9J6a52SLx28BCjT+4ieh7IGbgwVJWO+km431c4yRlREUAsAmt/uMjQUyQHNEPf0M39CA==", + "dev": true, + "license": "MIT", + "peer": true, + "engines": { + "node": ">=6" + } + }, + "node_modules/rope-sequence": { + "version": "1.3.4", + "resolved": "https://registry.npmjs.org/rope-sequence/-/rope-sequence-1.3.4.tgz", + "integrity": "sha512-UT5EDe2cu2E/6O4igUr5PSFs23nvvukicWHx6GnOPlHAiiYbzNuCRQCuiUdHJQcqKalLKlrYJnjY0ySGsXNQXQ==", + "dev": true, + "license": "MIT", + "peer": true + }, + "node_modules/uc.micro": { + "version": "2.1.0", + "resolved": "https://registry.npmjs.org/uc.micro/-/uc.micro-2.1.0.tgz", + "integrity": "sha512-ARDJmphmdvUk6Glw7y9DQ2bFkKBHwQHLi2lsaH6PPmz/Ka9sFOBsBluozhDltWmnv9u/cF6Rt87znRTPV+yp/A==", + "dev": true, + "license": "MIT", + "peer": true + }, + "node_modules/w3c-keyname": { + "version": "2.2.8", + "resolved": "https://registry.npmjs.org/w3c-keyname/-/w3c-keyname-2.2.8.tgz", + "integrity": "sha512-dpojBhNsCNN7T82Tm7k26A6G9ML3NkhDsnw9n/eoxSRlVBB4CEtIQ/KTCLI2Fwf3ataSXRhYFkQi3SlnFwPvPQ==", + "dev": true, + "license": "MIT", + "peer": true + } + } +} diff --git a/package.json b/package.json new file mode 100644 index 0000000..817da77 --- /dev/null +++ b/package.json @@ -0,0 +1,5 @@ +{ + "devDependencies": { + "@tiptap/extension-dropcursor": "^2.1.13" + } +} From 65810d71179452e55d486f77af8b13968df2d37a Mon Sep 17 00:00:00 2001 From: stephanie rousset Date: Wed, 4 Mar 2026 09:43:00 +0100 Subject: [PATCH 02/17] feat: update lib files and delete project_form file --- .../budgets_importer/admin/project_form.rb | 93 ------------------- lib/decidim/budgets_importer.rb | 10 +- .../import/project_creator.rb | 52 +++++------ 3 files changed, 31 insertions(+), 124 deletions(-) delete mode 100644 app/forms/decidim/budgets_importer/admin/project_form.rb diff --git a/app/forms/decidim/budgets_importer/admin/project_form.rb b/app/forms/decidim/budgets_importer/admin/project_form.rb deleted file mode 100644 index 62a52cb..0000000 --- a/app/forms/decidim/budgets_importer/admin/project_form.rb +++ /dev/null @@ -1,93 +0,0 @@ -# frozen_string_literal: true - -module Decidim - module BudgetsImporter - module Admin - # This class holds a Form to create/update projects from Decidim's admin panel. - class ProjectForm < Decidim::Form - include TranslatableAttributes - include AttachmentAttributes - include TranslationsHelper - include Decidim::ApplicationHelper - - translatable_attribute :title, String - translatable_attribute :description, String - - attribute :budget_amount, Integer - attribute :decidim_scope_id, Integer - attribute :decidim_category_id, Integer - attribute :proposal_ids, Array[Integer] - attribute :attachment, AttachmentForm - attribute :selected, Boolean - - attachments_attribute :photos - - validates :title, translatable_presence: true - validates :description, translatable_presence: true - validates :budget_amount, presence: true, numericality: { greater_than: 0 } - - validates :category, presence: true, if: ->(form) { form.decidim_category_id.present? } - - # Customization: - - # If scope does not exist, add Global scope to project - # validates :scope, presence: true, if: ->(form) { form.decidim_scope_id.present? } - - # decidim_scope_id : belongs to causes an inconsistency where validation fail on loop. - # validates :decidim_scope_id, scope_belongs_to_component: true, if: ->(form) { form.decidim_scope_id.present? } - - validate :notify_missing_attachment_if_errored - - delegate :categories, to: :current_component - - def map_model(model) - self.proposal_ids = model.linked_resources(:proposals, "included_proposals").pluck(:id) - self.selected = model.selected? - - return unless model.categorization - - self.decidim_category_id = model.categorization.decidim_category_id - end - - # Finds the Budget from the decidim_budgets_budget_id. - # - # Returns a Decidim::Budgets:Budget - def budget - @budget ||= context[:budget] - end - - # Finds the Category from the decidim_category_id. - # - # Returns a Decidim::Category - def category - @category ||= categories.find_by(id: decidim_category_id) - end - - # Customization: Returns Decidim::Scope or nil - # Finds the Scope from the given decidim_scope_id, uses the component scope if missing. - # - # Returns a Decidim::Scope - def scope - @scope ||= @attributes["decidim_scope_id"].value ? current_component.scopes.find_by(id: @attributes["decidim_scope_id"].value) : current_component.scope - end - - # Scope identifier - # - # Returns the scope identifier related to the project - def decidim_scope_id - super || scope&.id - end - - private - - # This method will add an error to the `attachment` field only if there's - # any error in any other field. This is needed because when the form has - # an error, the attachment is lost, so we need a way to inform the user of - # this problem. - def notify_missing_attachment_if_errored - errors.add(:add_photos, :needs_to_be_reattached) if errors.any? && add_photos.present? - end - end - end - end -end diff --git a/lib/decidim/budgets_importer.rb b/lib/decidim/budgets_importer.rb index 6af903c..49f0b75 100644 --- a/lib/decidim/budgets_importer.rb +++ b/lib/decidim/budgets_importer.rb @@ -53,11 +53,13 @@ def initialize(i18n_key) end end - class CategoryNotFound < DependencyNotFound - def initialize(project_title, id) + class TaxonomyNotFound < DependencyNotFound + attr_reader :ids + def initialize(project_title, ids) @project_title = project_title - @id = id - @resource = "category" + @ids = ids + @id = ids.join(",") + @resource = "taxonomy" super("not_found") end end diff --git a/lib/decidim/budgets_importer/import/project_creator.rb b/lib/decidim/budgets_importer/import/project_creator.rb index 6072119..056a1d8 100644 --- a/lib/decidim/budgets_importer/import/project_creator.rb +++ b/lib/decidim/budgets_importer/import/project_creator.rb @@ -15,6 +15,7 @@ def produce check_required_params! related_proposals(resource) + related_taxonomies resource end @@ -26,6 +27,7 @@ def finish! ) do resource.save! link_proposals! + link_taxonomies! end end @@ -36,8 +38,6 @@ def resource component: component, budget: budget, title: title, - scope: scope, - category: category, description: description, budget_amount: budget_amount ) @@ -55,14 +55,6 @@ def description locale_hasher("description", available_locales + ["machine_translations"]) end - def category_id - data[:"category/id"]&.to_i - end - - def scope_id - data[:"scope/id"]&.to_i - end - def budget_amount data[:budget_amount] end @@ -76,6 +68,15 @@ def proposal_ids &.map(&:to_i) || [] end + def taxonomy_ids + return [data[:"taxonomies/ids"].to_i] if data[:"taxonomies/ids"].is_a? Float + + data[:"taxonomies/ids"] + &.split(",") + &.flatten + &.map(&:to_i) || [] + end + def component context[:current_component] end @@ -88,27 +89,17 @@ def current_user context[:current_user] end - # ProjectForm requires the category_id to be present in component, if not returns nil - def category - return if category_id.blank? - - category = component.categories.find_by(id: category_id) - return category if category.present? - - raise Decidim::BudgetsImporter::CategoryNotFound.new(title[current_user.locale], category_id) - end - - # ProjectForm requires the category_id to be present in component, if not returns nil - def scope - return unless component.scopes_enabled? || scope_id.present? - - component.scopes.find_by(id: scope_id).presence - end - def link_proposals! resource.link_resources(@proposals, "included_proposals") end + def link_taxonomies! + taxonomies = Decidim::Taxonomy.where(id: taxonomy_ids) + taxonomies.each do |taxonomy| + resource.taxonomies << taxonomy + end + end + def related_proposals(project) proposals = project.sibling_scope(:proposals).where(id: proposal_ids) missing_ids = proposal_ids - proposals.map(&:id) @@ -117,6 +108,13 @@ def related_proposals(project) @proposals = proposals end + def related_taxonomies + taxonomies = Decidim::Taxonomy.where(id: taxonomy_ids) + missing_ids = taxonomy_ids - taxonomies.map(&:id) + raise Decidim::BudgetsImporter::TaxonomyNotFound.new(title[current_user.locale], missing_ids) if missing_ids.present? + + @taxonomies = taxonomies + end def available_locales @available_locales ||= component.organization.available_locales end From 99f4f136083fc4d74c90db86d04c0f772d996338 Mon Sep 17 00:00:00 2001 From: stephanie rousset Date: Wed, 4 Mar 2026 09:43:21 +0100 Subject: [PATCH 03/17] feat: update views and locales --- .../budgets/admin/projects/index.html.erb | 140 +++++++----------- .../admin/projects_imports/new.html.erb | 4 +- config/locales/en.yml | 14 +- config/locales/fr.yml | 12 +- 4 files changed, 72 insertions(+), 98 deletions(-) diff --git a/app/views/decidim/budgets/admin/projects/index.html.erb b/app/views/decidim/budgets/admin/projects/index.html.erb index 81ae832..8044e14 100644 --- a/app/views/decidim/budgets/admin/projects/index.html.erb +++ b/app/views/decidim/budgets/admin/projects/index.html.erb @@ -1,101 +1,65 @@ -
-
-

+<% add_decidim_page_title(t(".title")) %> +
+
+

- <%= link_to translated_attribute(budget.title), budgets_path %> > + <%= link_to decidim_sanitize_translated(budget.title), budgets_path %> > <%= t(".title") %> + ">
-
- <%= t "actions.import", scope: "decidim.admin" %> - + +
+ <%= render partial: "decidim/budgets/admin/projects/bulk_actions/dropdown" %> + <%= render partial: "decidim/budgets/admin/projects/bulk_actions/change-selected" %> + <%= render partial: "decidim/budgets/admin/projects/bulk_actions/budget-change" %> <% if allowed_to? :export, :budget %> - <%= export_dropdown(current_component, budget.id) %> + <%= export_dropdowns(query, current_component, budget.id) %> <% end %> - <%= link_to t("actions.new", scope: "decidim.budgets", name: t("models.project.name", scope: "decidim.budgets.admin")), new_budget_project_path, class: "button tiny button--title new" if allowed_to? :create, :project %> -
-

-
- - <%= admin_filter_selector(:projects) %> -
-
- - - - - - <%= th_scope_sort_link %> - - - - - - - <% projects.each do |project| %> - - - - - <%= td_resource_scope_for(project.scope) %> - - - - + <%= render partial: "decidim/budgets/admin/projects/bulk_actions/taxonomy_change" %> + + <%= admin_filter_selector(:projects) %> +
+
<%= sort_link(query, :id, t("models.project.fields.id", scope: "decidim.budgets"), default_order: :desc) %> - <%= sort_link(query, :title, t("models.project.fields.title", scope: "decidim.budgets")) %><%= sort_link(query, :category_name, t("models.project.fields.category", scope: "decidim.budgets") ) %><%= sort_link(query, :confirmed_orders_count, t("index.confirmed_orders_count")) %><%= sort_link(query, :selected, t(".selected")) %><%= t("actions.title", scope: "decidim.budgets") %>
- <%= project.id %>
-
- <%= translated_attribute(project.title) %>
-
- <% if project.category %> - <%= translated_attribute project.category.name %> - <% end %> - - <%= project.confirmed_orders_count %> - - <% if project.selected? %> - <%= content_tag :strong, t(".selected"), class: "text-success" %> - <% else %> - <%= content_tag :span, "×", class: "text-muted" %> - <% end %> - - <%= icon_link_to "eye", resource_locator([budget, project]).path, t("actions.preview", scope: "decidim.budgets"), target: :blank, class: "action-icon--preview" %> - - <% if allowed_to? :update, :project, project: project %> - <%= icon_link_to "pencil", resource_locator([budget, project]).edit, t("actions.edit", scope: "decidim.budgets"), class: "action-icon--edit" %> - <% end %> - - <% if allowed_to? :update, :project, project: project %> - <%= icon_link_to "folder", project_attachment_collections_path(project), t("actions.attachment_collections", scope: "decidim.budgets"), class: "action-icon--attachment_collections" %> + <% if allowed_to? :import_proposals, :project %> + <%= import_dropdown do %> + + + <% end %> + <% end %> + <%= link_to t("actions.new_project", scope: "decidim.budgets"), new_budget_project_path, class: "button button__sm button__secondary new" if allowed_to? :create, :project %> + + - <%= resource_permissions_link(project) %> - - <% if allowed_to? :destroy, :project, project: project %> - <%= icon_link_to "circle-x", resource_locator([budget, project]).show, t("actions.destroy", scope: "decidim.budgets"), method: :delete, class: "action-icon--remove", data: { confirm: t("actions.confirm_destroy", scope: "decidim.budgets") } %> - <% else %> - <%= icon "circle-x", class: "action-icon action-icon--disabled", role: "img", aria_label: t("actions.destroy", scope: "decidim.budgets") %> - <% end %> -
+ <%= render partial: "projects-thead" %> + + <%= render partial: "decidim/budgets/admin/projects/project-tr", + collection: projects, + as: :project, + locals: { view: :index } %> + +
+ <% if allowed_to? :manage_trash, :project, participatory_space: current_participatory_space %> +
+ <%= link_to manage_trash_budget_projects_path(budget), class: "flex items-center text-secondary" do %> + <%= icon "delete-bin-2-line", class: "mr-2 fill-current text-secondary", role: "img" %> + <%= t("actions.view_deleted_projects", scope: "decidim.budgets") %> + + <%= icon_with_tooltip("information-line", t("actions.deleted_budgets_info", scope: "decidim.budgets")) %> + <% end %> - - - <%= paginate projects, theme: "decidim" %> -
+
+ <% end %> + <%= decidim_paginate projects %>
<%= t ".finished_orders" %>: <%= finished_orders.count %> @@ -103,3 +67,5 @@ <%= t ".pending_orders" %>: <%= pending_orders.count %>
+ +<%= append_javascript_pack_tag "decidim_budgets_admin" %> diff --git a/app/views/decidim/budgets_importer/admin/projects_imports/new.html.erb b/app/views/decidim/budgets_importer/admin/projects_imports/new.html.erb index 7bfeb7a..3ec2056 100644 --- a/app/views/decidim/budgets_importer/admin/projects_imports/new.html.erb +++ b/app/views/decidim/budgets_importer/admin/projects_imports/new.html.erb @@ -9,7 +9,7 @@
- <%= t(".document_legend") %> + <%= t(".document_legend") %>
<%= f.upload :document, optional: false, help_i18n_messages: ["import_document", "import_accepted_formats"] %>
@@ -17,7 +17,7 @@

-
+
<%= f.submit t(".create") %>
<% end %> diff --git a/config/locales/en.yml b/config/locales/en.yml index 97d49a6..e6ae116 100644 --- a/config/locales/en.yml +++ b/config/locales/en.yml @@ -1,5 +1,9 @@ --- en: + activemodel: + attributes: + project: + document: Document decidim: assemblies: admin: @@ -14,10 +18,10 @@ en: projects_imports: new: callout: - help: The file must have column names 'title/en', 'description/en' (or + help: You can only import projects from a Decidim platform of miniml version 0.31. The imported file must have column names 'title/en', 'description/en' (or another locale which you prefer eg. 'title/ca' and 'description/ca') - and 'budget_amount'. Also 'scope/id', 'category/id' , 'related_proposals' - and 'image/url' columns are supported. + and 'budget_amount'. Also 'taxonomies/ids' and 'related_proposals' + columns are supported. create: Import document_legend: Join the document to import title: Import projects in current budget @@ -31,8 +35,8 @@ en: description: 'Missing required field ''description'' (ID: %{resource_id})' title: 'Missing required field ''title'' (ID: %{resource_id})' errors: - category: - not_found: 'Category (ID: %{id}) does not exist for project ''%{project_title}''' + taxonomy: + not_found: 'Taxonomy (ID: %{id}) does not exist for project ''%{project_title}''' database: missing_arguments: One or multiple arguments are expected but missing, please check required columns in export. diff --git a/config/locales/fr.yml b/config/locales/fr.yml index e62ec56..be61cc4 100644 --- a/config/locales/fr.yml +++ b/config/locales/fr.yml @@ -1,5 +1,9 @@ --- fr: + activemodel: + attributes: + project: + document: Document decidim: assemblies: admin: @@ -14,9 +18,9 @@ fr: projects_imports: new: callout: - help: Le fichier doit avoir les colonnes 'title/fr', 'description/fr' + help: Vous ne pouvez importer que des projets d'une plateforme Decidim de version minimale 0.31. Le fichier importé doit avoir les colonnes 'title/fr', 'description/fr' (ou une autre langue eg. 'title/en' et 'description/en') et 'budget_amount'. - Les colonnes 'scope/id', 'category/id' et 'related_proposals' sont + Les colonnes taxonomies/ids et 'related_proposals' sont supportées et optionnelles. create: Importer document_legend: Joindre le document à importer @@ -31,8 +35,8 @@ fr: description: 'Champs requis manquant ''description'' (ID: %{resource_id})' title: 'Champs requis manquant ''title'' (ID: %{resource_id})' errors: - category: - not_found: 'Categorie (ID: %{id}) n''existe pas pour le projet ''%{project_title}''' + taxonomy: + not_found: 'Taxonomie (ID: %{id}) n''existe pas pour le projet ''%{project_title}''' database: missing_arguments: Un ou plusieurs arguments sont requis et manquants, veuillez vous assurer que toutes les colonnes sont présentes. From 834c687ede6d970842288829a53083a2d0204c56 Mon Sep 17 00:00:00 2001 From: stephanie rousset Date: Wed, 4 Mar 2026 16:06:02 +0100 Subject: [PATCH 04/17] feat: update link_taxonomies method --- .../import/project_creator.rb | 9 +- spec/fixtures/files/projects-import.xlsx | Bin 5801 -> 0 bytes .../admin/project_form_spec.rb | 193 ------------------ 3 files changed, 5 insertions(+), 197 deletions(-) delete mode 100644 spec/fixtures/files/projects-import.xlsx delete mode 100644 spec/forms/decidim/budgets_importer/admin/project_form_spec.rb diff --git a/lib/decidim/budgets_importer/import/project_creator.rb b/lib/decidim/budgets_importer/import/project_creator.rb index 056a1d8..c1d1d52 100644 --- a/lib/decidim/budgets_importer/import/project_creator.rb +++ b/lib/decidim/budgets_importer/import/project_creator.rb @@ -56,7 +56,7 @@ def description end def budget_amount - data[:budget_amount] + data[:budget_amount].is_a?(Float) ? data[:budget_amount].to_i : data[:budget_amount] end def proposal_ids @@ -94,9 +94,10 @@ def link_proposals! end def link_taxonomies! - taxonomies = Decidim::Taxonomy.where(id: taxonomy_ids) - taxonomies.each do |taxonomy| - resource.taxonomies << taxonomy + if @taxonomies.present? + @taxonomies.each do |taxonomy| + resource.taxonomies << taxonomy + end end end diff --git a/spec/fixtures/files/projects-import.xlsx b/spec/fixtures/files/projects-import.xlsx deleted file mode 100644 index aa57117b26878fa83b38f2783fc39010cb98e98a..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 5801 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 diff --git a/spec/forms/decidim/budgets_importer/admin/project_form_spec.rb b/spec/forms/decidim/budgets_importer/admin/project_form_spec.rb deleted file mode 100644 index 8344ab1..0000000 --- a/spec/forms/decidim/budgets_importer/admin/project_form_spec.rb +++ /dev/null @@ -1,193 +0,0 @@ -# frozen_string_literal: true - -require "spec_helper" - -module Decidim::BudgetsImporter - describe Admin::ProjectForm do - subject(:form) { described_class.from_params(attributes).with_context(context) } - - let(:organization) { create(:organization, available_locales: [:en]) } - let(:context) do - { - current_organization: organization, - current_component: current_component, - current_participatory_space: participatory_process - } - end - let(:participatory_process) { create :participatory_process, organization: organization } - let(:current_component) { create :budgets_component, participatory_space: participatory_process } - let(:budget) { create :budget, component: current_component } - let(:title) do - Decidim::Faker::Localized.sentence(word_count: 3) - end - let(:description) do - Decidim::Faker::Localized.sentence(word_count: 3) - end - let(:budget_amount) { Faker::Number.number(digits: 8) } - let(:parent_scope) { create(:scope, organization: organization) } - let(:scope) { create(:subscope, parent: parent_scope) } - let(:scope_id) { scope.id } - let(:category) { create :category, participatory_space: participatory_process } - let(:category_id) { category.id } - let(:selected) { nil } - let(:attributes) do - { - decidim_scope_id: scope_id, - decidim_category_id: category_id, - title_en: title[:en], - description_en: description[:en], - budget_amount: budget_amount, - selected: selected - } - end - - it { is_expected.to be_valid } - - describe "when title is missing" do - let(:title) { { en: nil } } - - it { is_expected.not_to be_valid } - end - - describe "when description is missing" do - let(:description) { { en: nil } } - - it { is_expected.not_to be_valid } - end - - describe "when budget_amount is missing" do - let(:budget_amount) { nil } - - it { is_expected.not_to be_valid } - end - - describe "when budget_amount is less or equal 0" do - let(:budget_amount) { 0 } - - it { is_expected.not_to be_valid } - end - - describe "when the scope does not exist" do - let(:scope_id) { scope.id + 10 } - - it "assign component scope" do - expect(subject.scope).to eq(current_component.scope) - end - end - - describe "when the category does not exist" do - let(:category_id) { category.id + 10 } - - it { is_expected.not_to be_valid } - end - - it "properly maps category id from model" do - project = create(:project, component: current_component, category: category) - - expect(described_class.from_model(project).decidim_category_id).to eq(category_id) - end - - context "with proposals" do - subject { described_class.from_model(project).with_context(context) } - - let(:proposals_component) { create :component, manifest_name: :proposals, participatory_space: participatory_process } - let!(:proposal) { create :proposal, component: proposals_component } - - let(:project) do - create( - :project, - budget: budget, - scope: scope, - category: category - ) - end - - describe "#proposals" do - before do - project.link_resources([proposal], "included_proposals") - end - - it "returns the available proposals in a way suitable for the form" do - expect(subject.proposal_ids).to eq([proposal.id]) - end - end - - describe "#map_model" do - subject { described_class.from_model(project).with_context(context) } - - it "sets the proposal_ids correctly" do - project.link_resources([proposal], "included_proposals") - expect(subject.proposal_ids).to eq [proposal.id] - end - end - end - - describe "#selected" do - context "and properly maps selected? from model" do - let(:project) { create :project, selected_at: selected_at } - - context "when is not selected" do - let(:selected_at) { nil } - - it { expect(described_class.from_model(project).selected).to be_falsey } - end - - context "when selected is selected" do - let(:selected_at) { Time.current } - - it { expect(described_class.from_model(project).selected).to be_truthy } - end - end - - context "when is not selected" do - it { is_expected.to be_valid } - end - - context "when selected is selected" do - let(:selected) { true } - - it { is_expected.to be_valid } - end - end - - describe "scope" do - subject { form.scope } - - context "when the scope exists" do - it { is_expected.to be_kind_of(Decidim::Scope) } - end - - context "when the scope does not exist" do - let(:scope_id) { 3456 } - - it { is_expected.to be_nil } - end - - context "when the scope is from another organization" do - let(:scope_id) { create(:scope).id } - - it { is_expected.to be_nil } - end - - context "when the participatory space has a scope" do - let(:parent_scope) { create(:scope, organization: organization) } - let(:participatory_process) { create(:participatory_process, :with_steps, organization: organization, scope: parent_scope) } - let(:scope) { create(:scope, organization: organization, parent: parent_scope) } - - context "when the scope is descendant from participatory space scope" do - it { is_expected.to eq(scope) } - end - - context "when the scope is not descendant from participatory space scope" do - let(:scope) { create(:scope, organization: organization) } - - it { is_expected.to be_valid } - - it "find scope in current_component available scopes" do - expect(form.scope).to be_valid - end - end - end - end - end -end From 4348714575e52bacb69e87d3e1cf1edd22f78340 Mon Sep 17 00:00:00 2001 From: stephanie rousset Date: Wed, 4 Mar 2026 16:06:42 +0100 Subject: [PATCH 05/17] feat: update locales files --- config/i18n-tasks.yml | 4 +++- config/locales/en.yml | 20 ++++++++++++++------ config/locales/fr.yml | 20 ++++++++++++++------ 3 files changed, 31 insertions(+), 13 deletions(-) diff --git a/config/i18n-tasks.yml b/config/i18n-tasks.yml index 431dcc4..e5c86e3 100644 --- a/config/i18n-tasks.yml +++ b/config/i18n-tasks.yml @@ -14,7 +14,9 @@ ignore_unused: - decidim.budgets_importer.errors.database.missing_arguments - decidim.budgets_importer.import.success - decidim.budgets_importer.command.import.missing.* - + - activemodel.attributes.project.document + - decidim.budgets_importer.errors.not_found + - decidim.budgets_importer.errors.taxonomy.not_found ignore_missing: - decidim.participatory_processes.scopes.global diff --git a/config/locales/en.yml b/config/locales/en.yml index e6ae116..cafc5ee 100644 --- a/config/locales/en.yml +++ b/config/locales/en.yml @@ -4,6 +4,12 @@ en: attributes: project: document: Document + errors: + models: + assembly: + attributes: + document: + invalid_document_type: Invalid document type decidim: assemblies: admin: @@ -18,10 +24,11 @@ en: projects_imports: new: callout: - help: You can only import projects from a Decidim platform of miniml version 0.31. The imported file must have column names 'title/en', 'description/en' (or - another locale which you prefer eg. 'title/ca' and 'description/ca') - and 'budget_amount'. Also 'taxonomies/ids' and 'related_proposals' - columns are supported. + help: You can only import projects from a Decidim platform of miniml + version 0.31. The imported file must have column names 'title/en', + 'description/en' (or another locale which you prefer eg. 'title/ca' + and 'description/ca') and 'budget_amount'. Also 'taxonomies/ids' and + 'related_proposals' columns are supported. create: Import document_legend: Join the document to import title: Import projects in current budget @@ -35,15 +42,16 @@ en: description: 'Missing required field ''description'' (ID: %{resource_id})' title: 'Missing required field ''title'' (ID: %{resource_id})' errors: - taxonomy: - not_found: 'Taxonomy (ID: %{id}) does not exist for project ''%{project_title}''' database: missing_arguments: One or multiple arguments are expected but missing, please check required columns in export. importer: errors: Canceling import because of %{errors_count} errors + not_found: Not found proposal: not_found: 'Related proposals (ID: %{id}) does not exist for project ''%{project_title}''' + taxonomy: + not_found: 'Taxonomies (ID: %{id}) does not exist for project ''%{project_title}''' import: success: Projects successfully imported components: diff --git a/config/locales/fr.yml b/config/locales/fr.yml index be61cc4..c0ca84a 100644 --- a/config/locales/fr.yml +++ b/config/locales/fr.yml @@ -4,6 +4,12 @@ fr: attributes: project: document: Document + errors: + models: + assembly: + attributes: + document: + invalid_document_type: Type de document invalide decidim: assemblies: admin: @@ -18,10 +24,11 @@ fr: projects_imports: new: callout: - help: Vous ne pouvez importer que des projets d'une plateforme Decidim de version minimale 0.31. Le fichier importé doit avoir les colonnes 'title/fr', 'description/fr' - (ou une autre langue eg. 'title/en' et 'description/en') et 'budget_amount'. - Les colonnes taxonomies/ids et 'related_proposals' sont - supportées et optionnelles. + help: Vous ne pouvez importer que des projets d'une plateforme Decidim + de version minimale 0.31. Le fichier importé doit avoir les colonnes + 'title/fr', 'description/fr' (ou une autre langue eg. 'title/en' et + 'description/en') et 'budget_amount'. Les colonnes taxonomies/ids + et 'related_proposals' sont supportées et optionnelles. create: Importer document_legend: Joindre le document à importer title: Importer des projets dans le budget @@ -35,16 +42,17 @@ fr: description: 'Champs requis manquant ''description'' (ID: %{resource_id})' title: 'Champs requis manquant ''title'' (ID: %{resource_id})' errors: - taxonomy: - not_found: 'Taxonomie (ID: %{id}) n''existe pas pour le projet ''%{project_title}''' database: missing_arguments: Un ou plusieurs arguments sont requis et manquants, veuillez vous assurer que toutes les colonnes sont présentes. importer: errors: Import annulé à cause de %{errors_count} erreur(s) + not_found: Non trouvé proposal: not_found: 'Les propositions liées (ID: %{id}) n''existent pas pour le projet ''%{project_title}''' + taxonomy: + not_found: 'Les Taxonomies (ID: %{id}) n''existent pas pour le projet ''%{project_title}''' import: success: Projet importé avec succès components: From c6dcc0f1ef7f5f34bf15c5de9237600eeeb3d8f1 Mon Sep 17 00:00:00 2001 From: stephanie rousset Date: Wed, 4 Mar 2026 16:07:33 +0100 Subject: [PATCH 06/17] feat: replace deprecated Webpacker with Shakapacker --- config/assets.rb | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/config/assets.rb b/config/assets.rb index acf0c68..5a0d9c0 100644 --- a/config/assets.rb +++ b/config/assets.rb @@ -2,8 +2,8 @@ base_path = File.expand_path("..", __dir__) -Decidim::Webpacker.register_path("#{base_path}/app/packs") -Decidim::Webpacker.register_entrypoints( +Decidim::Shakapacker.register_path("#{base_path}/app/packs") +Decidim::Shakapacker.register_entrypoints( decidim_budgets_importer: "#{base_path}/app/packs/entrypoints/decidim_budgets_importer.js" ) -Decidim::Webpacker.register_stylesheet_import("stylesheets/decidim/budgets_importer/budgets_importer") +Decidim::Shakapacker.register_stylesheet_import("stylesheets/decidim/budgets_importer/budgets_importer") From 43624b5b080b9a33624a99ccc504957cc524cc30 Mon Sep 17 00:00:00 2001 From: stephanie rousset Date: Wed, 4 Mar 2026 16:08:00 +0100 Subject: [PATCH 07/17] test: update tests --- .../admin/import_project_spec.rb | 6 +++--- spec/fixtures/files/projects-import.csv | 6 +++--- spec/fixtures/files/projects-import.json | 20 ++++-------------- spec/fixtures/files/projects-import.xlsx | Bin 0 -> 5767 bytes .../decidim/budgets_importer/version_spec.rb | 4 ++-- spec/lib/decidim/budgets_importer_spec.rb | 10 ++++----- 6 files changed, 17 insertions(+), 29 deletions(-) create mode 100644 spec/fixtures/files/projects-import.xlsx diff --git a/spec/commands/decidim/budgets_importer/admin/import_project_spec.rb b/spec/commands/decidim/budgets_importer/admin/import_project_spec.rb index 1828d41..8c90c9b 100644 --- a/spec/commands/decidim/budgets_importer/admin/import_project_spec.rb +++ b/spec/commands/decidim/budgets_importer/admin/import_project_spec.rb @@ -15,7 +15,7 @@ module Admin let!(:proposal) { create(:proposal, id: 1, component: proposal_component) } let!(:proposal2) { create(:proposal, id: 2, component: proposal_component) } let(:budget) { create :budget, component: current_component } - let!(:category) { create(:category, id: 1, participatory_space: current_component.participatory_space) } + let!(:taxonomy) { create(:taxonomy, :with_parent, id: 1, organization:) } let(:document) { upload_test_file(fixture_test_file(filename, mime_type)) } let(:filename) { "projects-import.csv" } let(:mime_type) { "text/csv" } @@ -100,8 +100,8 @@ module Admin it_behaves_like "does not save imported projects" end - context "when category ID does not exist" do - let(:category) { create(:category) } + context "when taxonomy ID does not exist" do + let(:taxonomy) { create(:taxonomy) } it_behaves_like "does not save imported projects" end diff --git a/spec/fixtures/files/projects-import.csv b/spec/fixtures/files/projects-import.csv index 043011a..f3314bb 100644 --- a/spec/fixtures/files/projects-import.csv +++ b/spec/fixtures/files/projects-import.csv @@ -1,3 +1,3 @@ -id;category/id;category/name/en;scope/id;scope/name/en;participatory_space/id;participatory_space/url;component/id;title/en;description/en;budget/id;budget_amount;confirmed_votes;comments;created_at;url;related_proposals;related_proposal_titles;related_proposal_urls -1;1;Category example;3;North Yvone;1;http://localhost:3000/processes/strikebreaker-agree?participatory_process_slug=strikebreaker-agree;4;Occaecati qui.;

Voluptates sequi sit. Odio sed consectetur. Qui in nisi.

;1;40775012;0;2;2023-01-12 13:24:20 UTC;http://localhost:3000/processes/strikebreaker-agree/f/4/budgets/1/projects/1;"";"";"" -21;;"";18;Remediosport;1;http://localhost:3000/processes/strikebreaker-agree?participatory_process_slug=strikebreaker-agree;4;Project example 2;

Project example description 2

;1;10000;0;0;2023-01-12 13:42:48 UTC;http://localhost:3000/processes/strikebreaker-agree/f/4/budgets/1/projects/21;2, 1;Nihil occaecati. Similique., Proposal example;http://localhost:3000/processes/strikebreaker-agree/f/3/proposals/2, http://localhost:3000/processes/strikebreaker-agree/f/3/proposals/1 +id;taxonomies/ids;participatory_space/id;participatory_space/url;component/id;title/en;description/en;budget/id;budget_amount;confirmed_votes;comments;created_at;url;related_proposals;related_proposal_titles;related_proposal_urls +1;1;1;http://localhost:3000/processes/strikebreaker-agree?participatory_process_slug=strikebreaker-agree;4;Occaecati qui.;

Voluptates sequi sit. Odio sed consectetur. Qui in nisi.

;1;40775012;0;2;12.01.2023 13:24:SS;http://localhost:3000/processes/strikebreaker-agree/f/4/budgets/1/projects/1;;; +21;;1;http://localhost:3000/processes/strikebreaker-agree?participatory_process_slug=strikebreaker-agree;4;Project example 2;

Project example description 2

;1;10000;0;0;12.01.2023 13:42:SS;http://localhost:3000/processes/strikebreaker-agree/f/4/budgets/1/projects/21;2, 1;Nihil occaecati. Similique., Proposal example;http://localhost:3000/processes/strikebreaker-agree/f/3/proposals/2, http://localhost:3000/processes/strikebreaker-agree/f/3/proposals/1 \ No newline at end of file diff --git a/spec/fixtures/files/projects-import.json b/spec/fixtures/files/projects-import.json index e8c49c1..28d697c 100644 --- a/spec/fixtures/files/projects-import.json +++ b/spec/fixtures/files/projects-import.json @@ -1,16 +1,10 @@ [ { "id": 1, - "category": { + "taxonomy": { "id": 1, "name": { - "en": "Category example" - } - }, - "scope": { - "id": 3, - "name": { - "en": "North Yvone" + "en": "taxonomy example" } }, "participatory_space": { @@ -46,18 +40,12 @@ }, { "id": 21, - "category": { + "taxonomy": { "id": null, "name": { "en": "" } }, - "scope": { - "id": 18, - "name": { - "en": "Remediosport" - } - }, "participatory_space": { "id": 1, "url": "http://localhost:3000/processes/strikebreaker-agree?participatory_process_slug=strikebreaker-agree" @@ -92,4 +80,4 @@ "http://localhost:3000/processes/strikebreaker-agree/f/3/proposals/1" ] } -] \ No newline at end of file +] diff --git a/spec/fixtures/files/projects-import.xlsx b/spec/fixtures/files/projects-import.xlsx new file mode 100644 index 0000000000000000000000000000000000000000..7540621e80d74f58e78600eec7227deb5a8bf137 GIT binary patch literal 5767 zcmai2bwHEt`ld$52GUA1N|5db=^TyZV1%S}gLFzwQjkzeLQ)z8X(U8J8Wcr@0ZK@7 zHa+JjpXYqv?_Rv`{;^KvnNi|`|Ky*5n z5t-wi*REboM~YCgAm*=iq<{eOhHvJ~#5->F57|Y-XRIOyl+054Tu&RQg{sEeOPLUX z7NvEd;KW{2HA5-!6@J1mQw>CG3?*se<#=PNK89n@zTW;Wi<=Yps`)Ya!`GLXIhY^! zE;MH%n}qOx$mLx>5oL^|fSv$;*sWBS<5cTP>71eWhlUHpW5ft&a5isp%&N$rOX7)M z&>SodLOO@vSq?5<8$iFI-Fve|Az(137HrX(4pZ{ozW>4j^Tz#=!Di8;kBhaOL&A;h zT+X!?OI4%wOfM{T)NyceppFp$bTl*^Of)o||1XrjZXQma4ltOP=dGWYU!lyH_n6}a zMn5jtS(yyJNzcbCTSCN`qL5o6X7;QJH{Y0oIZk1zvj=;|!r!dKEUe>nV`hB>v8} zesm7PsF$Cd>Lf8(ASU01$LO zr+b~;q(*96lGzo^1EB0g{Gl26wk_hlxW=m6m<%ynf^FjUNH%8Y=k-OF$vyERkbAea;j>?AenYQWWT=^YO<4iZQoB}P#LqD|P6C>oMK4;(TOoo#ToeooXm~J?PyCjIqcUF5a3a%G@q>Q;Kw1t>+oYHNBZ% zs2$8Fgx95Nma90yVh08Z$I+&L5sGV3Rn&x9lb(a`Igv(y@7a^`uzw9Ez^FKx2oI|Z zag&oZ4{cy5c%ICSTedY$7M^^cjp_)1InKL_fmy@5Ye--vRranS0Qm;2W`bQr%kyTR zjcx72tH{v_$Gy!N!Z7M7(0T8OaN|-{`62IH(eEcF@Y`z(7M|!T+ZcVE)xju9SeK2h90uA@HDnCylG) z_wWL-SIGQgcmva?qhbXSN|CNl>8w;rNSx_dzD>^OCKavpd>S1O>a`Ri5vZq)5*6br zTm$gd4Q~t)la4Lk>%gQSGfk?mXR$8C)$FLy60{i>x%Vi@mbzBACo6540Q61;o7p$t zSu22&utYLi&QG86x{7l=l&hx{{UCG5l$)`k6>FM1|Dx7>Sv#Is%baL-|6|ky`c8{6 zn2!+7;(jsL(VJ#Zp=cgg6MsO4ia}M`re-~Ig`CJ%@b_(i>{krD9AGZ6TR*>lc7WGL z^B(gI!1M46%-+BV7WJl2ad~lh0Vfk$_FpaX<05&8LZ z#MF0x7*X^pKs zKL%WajH^954&H~)2x1qYp!Ao^qDk<`w=Qp$RAL+;;dE9?wK4I8ufku>J??rXlUyXo zAmZ;nikof#)MC$wZ&i6CFWc>2B1%Up|0FDzY)Bgprz;Y~g41KX4hkdM+4`=$d*q`m z);!=v#CA}TRY?^r;rF`562Z9Nb$F=Q~Gj(%*Mf{TOyBViXPV5Svj zgr%K?1r5SF=&|ProNAfd9W-mmVA$l`)uh+1l7&M8Qj+08pq#8hN1E-2y1os1%zmk5 zc2edzl%AFIVe8+0Inx!w351fW>|<}=5T_^@j2fnWlvwpt%+7M}dEMOM1|cWT%{y)4 zlx%IJ5X0%?BB|$^ev1iFs@+p^mRdbomFiGoc_?2XHQu~9B|&Ip-qctmfEv4-btXo1c}h}_^>EVb#ftZB)nAK6zt2r2Q=76hSF?YHS-kXaE3~Op z5J1%6C#m|;?u_etKlc4LGmK@{JAxi*yrX6iM~&_4=%d%ZsvxfD(xKXvBH5Iwk^c}RB6|KRhp-R zwFk^r&&vZvU{JiJLw`hTkr!2J5uX5Du?l4l0M+dxNM=+;vWxAbmKMFU9s#+`u9}^Q zcyM_u``592&!C_&zqNoyZ$n9WCc@6t_1hc(KeB**1?H~cbH76id?+H&B_c*i8hyy% zv;+)IO%Axb7ADXiw2I)`(?G7ppNn=|hr+t;M1Rwe{~iec6A zBk`TRlzJi{#S->z$IWNW$9AC5q(IxPolhxZGVz1;D`cQk8!5SsIcku7^Us0I(Aizx3Jz?tdbX1GzL5)#+3USG;p4J>-9+aAp#xr z{2h-e@EyIUX7;TTef`V6AR$l7ym%7?nd?OS?wN7aQ8+PT+lgJP4{`5FzFzx-d4dC{ zHG`)89j06I}%jM{G23X zSserRE?&L@k7JW=PD-}4Lp)BQ@66KE8uM>jHe$9wx z!&`d5gyM80n-wIeai-<1%5qPstFy|4x4dDTs(Do=Sqt`@=Pmd4wX-l!>rsEXOK|_P z88`L%sj0NmG|HPdUQci zdn%?8G7KWhI(5Fl-W+|%V;x8=!Ix#WGL0wnLI z*6uh`rIf5L+OvmU6SNBF(6e6qPCOO07ST?B$>Vm%oSi{)a4c?t4^8=C_FP3w4%N|^k zdu2x!=j2Zb`jw{p3K5Ba!I&1hIIj%OrBF(yP1Vagp7MMD^c4F55%65(aGGw5IA1Kp z>)Hd|PU{7J>L45!lF>SZgtXtOHuQu5m6!N4)nIcZJ2Jxgr@SQpm6z@?4^KB&&s)E) zsD^bTk&hTDw9qWO>6v!k!pkdid~BeRIEr!VOhP^ecgoK4djeY9tmigAEHyZS4kv^u z-CyZKRx@MPKl*HUmjkq{L0}SkNLK&U^A~x2AyV?Ifx4apF^!itB(u&4kdR%4T(0Q{ zFlW7xF6Xdhrb^kS5~Cxyu65<$jgP}|4Eqg3R$;*PF4Rf{9WWooAfK}k`T2W}L-K1S zD4qv(b94GB7Sq&`Vi6dvJt3jE6!8(CGgjrj{zK$@j;{MX8FUp{V1f&s=_!gu&PCN{ zkKCkZFI|^u@&s2RJcQYtv(vCD-66AjTAf`>6troPgH>yDCWAxd7_*exZS?Eo%Ijlz z)AK3moc-d(g0c97BP=OQY|SA&wNIM-_$j06v%iew=M2}KtvgK@^l?w&wK8Sop+O19 zre+!}0weaCc$yz*R;;$ zs_`ISVpDZE3BKRh#MmaNzP%j%Kr`W|+)M?Nr6?o29QYsQCe5!s_(iaRu&Rnxa))lrjS;WXxm>)Cy>I|6_k;6!Y~F_>uwWH|Dq*dheDBtF zByOu*vAi0wOMCesZJ+Lmsp!)m6-u?kbxy0L)H>H;;CV>+a)ua7+tO-iU3rCR(vK&W zgr?HEjG~==RAoU)H&@k(?ehD1fu+=j>ik&SZKAy(=!EA1Wx}+`u+8x+>5yGG^zQge zvkP<^Qv`=jUpaX1HRyDYHr2ihXtp3+7qcyQdF1)YNL}kg(wVeiY!Cx=)wo!n%>w?t zhV8ze^5vLc4n}|ssqjCBlmHphU-A66OpzlF=LG^LkTS*Y5aMo~SooX|>`X*g(4@d9 zTk80%2Z4Yj5oD$x?}e09X8J=(_N^JX3I;u_9LP6b(xA^Awo9QA=$dk~)v;Ukp?NoQ z+!7tia+Q~9?k0ssgh?y;u1S{B*;Dg-I82o=%Zy|xxizQXg<~J{jQ?2ZqSXn`s+`0K zDkiW(eBGtbZFSZ0WAc7H*-uYy8ONgT#*1$ZzF?7AitWEy*!?UmRMNNuS+O{{PuvO_ z>W~XzM=tm8D;T9x?kKpqdcj=1EcN}}VV>rwDsI#tK~?ct_=Uon6FF@_Sw(zzA@@KN zWCMpPP=V zPI9xCB`>32g8e;R%Igx5^gd}cJNVXfD+9GvU0i)~`OC4VRP-9IUNIhafgAtgEusCCI+uYC2UdV)1 z$p$vo!h6o^78vrdrP$KQKs9=tmzA&C z_k8@2d2na6P}j<@!0F>+ihS}4qeX3pqnlN8%?%ILPl}ne(NDw+LM^=0*gd#5Uq-)R z?${3reoMJ{>39M_?TrsqbL|dtUzV{@dxMT~4ej@-+|@%S)T!KG?eEU${zSQ|)BlR1 zj{ILF$`x(?`*`Y4l&eY?rRjg07V^peit;}d{-1zX2|X(Hej5Zy<&c1X%H=-+t};Iq z@BeM>xIY2@O9lLiaCJtb7~*exi#*dnK7!}}@x?z~uMS1j5dUq?NF=1|e~nVVj-RXW(fR=bG0>~dfjg$0{x}){pol$Z~wY| aM@Yy2(MNRD0oW*X0_1BENsQn>z5WFbwM&iw literal 0 HcmV?d00001 diff --git a/spec/lib/decidim/budgets_importer/version_spec.rb b/spec/lib/decidim/budgets_importer/version_spec.rb index cc623f3..f6bc76e 100644 --- a/spec/lib/decidim/budgets_importer/version_spec.rb +++ b/spec/lib/decidim/budgets_importer/version_spec.rb @@ -7,11 +7,11 @@ module Decidim subject { described_class } it "has version" do - expect(subject.version).to eq("2.0.0") + expect(subject.version).to eq("3.0.0") end it "has decidim version" do - expect(subject.decidim_version).to eq("0.27") + expect(subject.decidim_version).to eq("0.31.2") end end end diff --git a/spec/lib/decidim/budgets_importer_spec.rb b/spec/lib/decidim/budgets_importer_spec.rb index 08f4997..8b58754 100644 --- a/spec/lib/decidim/budgets_importer_spec.rb +++ b/spec/lib/decidim/budgets_importer_spec.rb @@ -76,20 +76,20 @@ module Decidim end end - describe BudgetsImporter::CategoryNotFound do - subject { described_class.new project_title, id } + describe BudgetsImporter::TaxonomyNotFound do + subject { described_class.new project_title, ids } let(:project_title) { "Project title example" } - let(:id) { 10 } + let(:ids) { [10, 11] } it "is a DependencyNotFound" do expect(subject).to be_a BudgetsImporter::DependencyNotFound end describe "#to_flash_format" do - subject { described_class.new(project_title, id).to_flash_format } + subject { described_class.new(project_title, ids).to_flash_format } - it { is_expected.to eq({ type: :alert, message: "Category (ID: 10) does not exist for project 'Project title example'" }) } + it { is_expected.to eq({ type: :alert, message: "Taxonomies (ID: 10,11) does not exist for project 'Project title example'" }) } end end From a57ce2a4790401e82e719f123efb0054a79c28f1 Mon Sep 17 00:00:00 2001 From: stephanie rousset Date: Wed, 4 Mar 2026 16:17:51 +0100 Subject: [PATCH 08/17] style: update comment on view --- app/views/decidim/budgets/admin/projects/index.html.erb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/app/views/decidim/budgets/admin/projects/index.html.erb b/app/views/decidim/budgets/admin/projects/index.html.erb index 8044e14..1e977e6 100644 --- a/app/views/decidim/budgets/admin/projects/index.html.erb +++ b/app/views/decidim/budgets/admin/projects/index.html.erb @@ -7,7 +7,7 @@ <%= t(".title") %> ">
- +
<%= render partial: "decidim/budgets/admin/projects/bulk_actions/dropdown" %> From a446f6b3805d5b9f14446e28573bacd516832704 Mon Sep 17 00:00:00 2001 From: stephanie rousset Date: Wed, 4 Mar 2026 16:43:23 +0100 Subject: [PATCH 09/17] ci: update ci --- .github/workflows/build_app.yml | 70 +++++++++++++++ .github/workflows/ci_budgets_importer.yml | 53 ++++++----- .github/workflows/test_app.yml | 102 ++++++++++++++++++++++ 3 files changed, 197 insertions(+), 28 deletions(-) create mode 100644 .github/workflows/build_app.yml create mode 100644 .github/workflows/test_app.yml diff --git a/.github/workflows/build_app.yml b/.github/workflows/build_app.yml new file mode 100644 index 0000000..9cd9017 --- /dev/null +++ b/.github/workflows/build_app.yml @@ -0,0 +1,70 @@ +on: + workflow_call: + inputs: + ruby_version: + description: 'Ruby Version' + default: "3.3.4" + type: string + required: false + node_version: + description: 'Node version' + default: '22.14.0' + required: false + type: string +jobs: + build_app: + name: Build app + runs-on: ubuntu-22.04 + if: "!startsWith(github.head_ref, 'chore/l10n')" + timeout-minutes: 60 + env: + DATABASE_USERNAME: postgres + DATABASE_PASSWORD: postgres + DATABASE_HOST: localhost + RUBYOPT: '-W:no-deprecated' + services: + postgres: + image: postgres:14 + ports: ["5432:5432"] + options: >- + --health-cmd pg_isready + --health-interval 10s + --health-timeout 5s + --health-retries 5 + env: + POSTGRES_PASSWORD: postgres + steps: + - uses: actions/checkout@v4 + with: + fetch-depth: 1 + - uses: ruby/setup-ruby@v1 + with: + ruby-version: ${{ inputs.ruby_version }} + bundler-cache: true + - uses: actions/setup-node@v4 + with: + node-version: ${{ inputs.node_version }} + cache: 'npm' + cache-dependency-path: ./package-lock.json + - uses: actions/cache@v4 + id: app-cache + with: + path: ./spec/decidim_dummy_app/ + key: app-${{ github.sha }} + restore-keys: app-${{ github.sha }} + - run: bundle exec rake test_app + name: Create test app + shell: "bash" + - run: | + rm -f ./spec/decidim_dummy_app/app/services/dummy_signature_handler.rb + rm -f ./spec/decidim_dummy_app/app/services/dummy_sms_mobile_phone_validator.rb + name: Remove Initiative-dependent dummy files + - run: mkdir -p ./spec/decidim_dummy_app/tmp/screenshots + name: Create the screenshots folder + shell: "bash" + - run: RAILS_ENV=test bundle exec rails shakapacker:compile + name: Precompile assets + working-directory: ./spec/decidim_dummy_app/ + shell: "bash" + env: + NODE_ENV: "test" diff --git a/.github/workflows/ci_budgets_importer.yml b/.github/workflows/ci_budgets_importer.yml index 55bd1da..8c96ebe 100644 --- a/.github/workflows/ci_budgets_importer.yml +++ b/.github/workflows/ci_budgets_importer.yml @@ -3,40 +3,37 @@ on: [push] env: CI: "true" - RUBY_VERSION: 3.0.2 - NODE_VERSION: 16.9.1 + RUBY_VERSION: 3.3.4 + NODE_VERSION: 22.14.0 jobs: - main: - name: Tests + build_app: + uses: ./.github/workflows/build_app.yml + secrets: inherit + name: Build test application + + lint: + name: Lint code runs-on: ubuntu-latest - timeout-minutes: 30 - services: - postgres: - image: postgres:11 - ports: ["5432:5432"] - options: >- - --health-cmd pg_isready - --health-interval 10s - --health-timeout 5s - --health-retries 5 - env: - POSTGRES_PASSWORD: postgres - env: - DATABASE_USERNAME: postgres - DATABASE_PASSWORD: postgres - DATABASE_HOST: localhost + timeout-minutes: 60 steps: - - name: Linting - uses: OpenSourcePolitics/lint-action@master - with: - ruby_version: ${{ env.RUBY_VERSION }} - node_version: ${{ env.NODE_VERSION }} - - name: Running rspec - uses: OpenSourcePolitics/rspec-action@master + - uses: rokroskar/workflow-run-cleanup-action@v0.3.0 + if: "github.ref != 'refs/heads/develop'" + env: + GITHUB_TOKEN: "${{ secrets.GITHUB_TOKEN }}" + - uses: OpenSourcePolitics/lint-action@master with: ruby_version: ${{ env.RUBY_VERSION }} node_version: ${{ env.NODE_VERSION }} + + tests: + name: Tests + needs: build_app + uses: ./.github/workflows/test_app.yml + with: + test_command: "bundle exec rspec --pattern './spec/**/*_spec.rb'" + secrets: inherit + release: name: Generate release and push to RubyGems needs: [main] @@ -47,4 +44,4 @@ jobs: uses: OpenSourcePolitics/decidim-publish-gem-action@master with: rubygems_api_key: ${{ secrets.RUBYGEMS_API_KEY }} - github_token: ${{ secrets.GITHUB_TOKEN }} \ No newline at end of file + github_token: ${{ secrets.GITHUB_TOKEN }} diff --git a/.github/workflows/test_app.yml b/.github/workflows/test_app.yml new file mode 100644 index 0000000..c008a36 --- /dev/null +++ b/.github/workflows/test_app.yml @@ -0,0 +1,102 @@ +on: + workflow_call: + inputs: + ruby_version: + description: 'Ruby Version' + default: "3.3.4" + required: false + type: string + test_command: + description: 'The testing command to be ran' + required: true + type: string + chrome_version: + description: 'Chrome & Chromedriver version' + required: false + default: "136.0.7103.92" + type: string + +jobs: + build_app: + name: Test + runs-on: ubuntu-latest + if: "!startsWith(github.head_ref, 'chore/l10n')" + timeout-minutes: 60 + env: + DATABASE_USERNAME: postgres + DATABASE_PASSWORD: postgres + DATABASE_HOST: localhost + RUBYOPT: '-W:no-deprecated' + services: + validator: + image: ghcr.io/validator/validator:latest + ports: ["8888:8888"] + postgres: + image: postgres:14 + ports: ["5432:5432"] + options: >- + --health-cmd pg_isready + --health-interval 10s + --health-timeout 5s + --health-retries 5 + env: + POSTGRES_PASSWORD: postgres + redis: + image: redis + options: >- + --health-cmd "redis-cli ping" + --health-interval 10s + --health-timeout 5s + --health-retries 5 + steps: + - uses: actions/checkout@v4 + with: + fetch-depth: 1 + - uses: ruby/setup-ruby@v1 + with: + ruby-version: ${{ inputs.ruby_version }} + - run: | + sudo apt update + sudo apt install libu2f-udev imagemagick + wget --no-verbose -O /tmp/chrome.deb https://dl.google.com/linux/chrome/deb/pool/main/g/google-chrome-stable/google-chrome-stable_${{inputs.chrome_version}}-1_amd64.deb + sudo dpkg -i /tmp/chrome.deb + rm /tmp/chrome.deb + - uses: nanasess/setup-chromedriver@v2 + with: + chromedriver-version: ${{inputs.chrome_version}} + name: Install Chrome version ${{inputs.chrome_version}} + - uses: actions/cache@v4 + id: app-cache + with: + path: ./spec/decidim_dummy_app/ + key: app-${{ github.sha }} + restore-keys: app-${{ github.sha }} + - run: | + bundle install + bundle exec rake db:create db:schema:load + name: Install gems and create db + shell: "bash" + working-directory: ./spec/decidim_dummy_app/ + - run: | + sudo Xvfb -ac $DISPLAY -screen 0 1920x1084x24 > /dev/null 2>&1 & # optional + ${{ inputs.test_command }} + name: RSpec + working-directory: ./ + env: + VALIDATOR_HTML_URI: http://localhost:8888/ + RUBY_VERSION: ${{ inputs.ruby_version }} + DECIDIM_MODULE: "decidim-module-additional_authorization_handler" + DISPLAY: ":99" + CI: "true" + SIMPLECOV: "true" + SHAKAPACKER_RUNTIME_COMPILE: "false" + NODE_ENV: "test" + - uses: codecov/codecov-action@v3 + name: Upload coverage + - uses: actions/upload-artifact@v4 + if: always() + with: + name: screenshots + path: ./spec/decidim_dummy_app/tmp/screenshots + if-no-files-found: ignore + overwrite: true From 1acb1bf6cef09d88fcd5a19173b8d1dd44c386b9 Mon Sep 17 00:00:00 2001 From: stephanie rousset Date: Wed, 4 Mar 2026 16:49:49 +0100 Subject: [PATCH 10/17] ci: update ci --- .github/workflows/ci_budgets_importer.yml | 18 ++++++++++++++++-- 1 file changed, 16 insertions(+), 2 deletions(-) diff --git a/.github/workflows/ci_budgets_importer.yml b/.github/workflows/ci_budgets_importer.yml index 8c96ebe..893a700 100644 --- a/.github/workflows/ci_budgets_importer.yml +++ b/.github/workflows/ci_budgets_importer.yml @@ -1,6 +1,20 @@ name: "[CI] BudgetsImporter" -on: [push] - +on: + push: + branches: + - develop + - release/* + - "*-stable" + pull_request: + branches-ignore: + - "chore/l10n*" + paths: + - "*" + - ".github/**" +concurrency: + group: ${{ github.workflow }}-${{ github.head_ref || github.ref }} + cancel-in-progress: true + env: CI: "true" RUBY_VERSION: 3.3.4 From a3d64f4acb4f4c6724fe24854cc3dfdba1016bae Mon Sep 17 00:00:00 2001 From: stephanie rousset Date: Wed, 4 Mar 2026 16:52:00 +0100 Subject: [PATCH 11/17] ci: remove release --- .github/workflows/ci_budgets_importer.yml | 14 +------------- 1 file changed, 1 insertion(+), 13 deletions(-) diff --git a/.github/workflows/ci_budgets_importer.yml b/.github/workflows/ci_budgets_importer.yml index 893a700..482cc43 100644 --- a/.github/workflows/ci_budgets_importer.yml +++ b/.github/workflows/ci_budgets_importer.yml @@ -14,7 +14,7 @@ on: concurrency: group: ${{ github.workflow }}-${{ github.head_ref || github.ref }} cancel-in-progress: true - + env: CI: "true" RUBY_VERSION: 3.3.4 @@ -47,15 +47,3 @@ jobs: with: test_command: "bundle exec rspec --pattern './spec/**/*_spec.rb'" secrets: inherit - - release: - name: Generate release and push to RubyGems - needs: [main] - if: "github.ref == 'refs/heads/master'" - runs-on: ubuntu-latest - steps: - - name: Github release and RubyGems push - uses: OpenSourcePolitics/decidim-publish-gem-action@master - with: - rubygems_api_key: ${{ secrets.RUBYGEMS_API_KEY }} - github_token: ${{ secrets.GITHUB_TOKEN }} From 40c6e599875ed025e420776df8b7e4a207befa5d Mon Sep 17 00:00:00 2001 From: stephanie rousset Date: Wed, 4 Mar 2026 16:54:22 +0100 Subject: [PATCH 12/17] fix: add platform x86_64-linux --- Gemfile.lock | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/Gemfile.lock b/Gemfile.lock index 0e514b9..1ec3eb0 100644 --- a/Gemfile.lock +++ b/Gemfile.lock @@ -402,6 +402,7 @@ GEM faraday-net_http (3.4.2) net-http (~> 0.5) ffi (1.17.3-x86_64-darwin) + ffi (1.17.3-x86_64-linux-gnu) fiber-storage (1.0.1) file_validators (3.0.0) activemodel (>= 3.2) @@ -425,6 +426,9 @@ GEM google-protobuf (4.34.0-x86_64-darwin) bigdecimal rake (~> 13.3) + google-protobuf (4.34.0-x86_64-linux-gnu) + bigdecimal + rake (~> 13.3) graphql (2.4.17) base64 fiber-storage @@ -554,6 +558,8 @@ GEM nio4r (2.7.5) nokogiri (1.19.1-x86_64-darwin) racc (~> 1.4) + nokogiri (1.19.1-x86_64-linux-gnu) + racc (~> 1.4) oauth (1.1.3) base64 (~> 0.1) oauth-tty (~> 1.0, >= 1.0.6) @@ -803,6 +809,8 @@ GEM rubyzip (2.3.2) sass-embedded (1.97.3-x86_64-darwin) google-protobuf (~> 4.31) + sass-embedded (1.97.3-x86_64-linux-gnu) + google-protobuf (~> 4.31) securerandom (0.4.1) selenium-webdriver (4.41.0) base64 (~> 0.2) @@ -898,6 +906,7 @@ GEM PLATFORMS x86_64-darwin + x86_64-linux DEPENDENCIES bootsnap (~> 1.4) From 88cbcc4b5d774062c56853c8eff645a785f85e94 Mon Sep 17 00:00:00 2001 From: stephanie rousset Date: Wed, 4 Mar 2026 17:18:22 +0100 Subject: [PATCH 13/17] fix: set version of openssl in gemfile to avoid error --- Gemfile | 1 + Gemfile.lock | 13 ++++++------- 2 files changed, 7 insertions(+), 7 deletions(-) diff --git a/Gemfile b/Gemfile index d9de521..4469b90 100644 --- a/Gemfile +++ b/Gemfile @@ -8,6 +8,7 @@ gem "decidim" gem "decidim-budgets_importer", path: "." gem "bootsnap", "~> 1.4" +gem "openssl", "3.3.0" gem "puma", ">= 6.3.1" group :development, :test do diff --git a/Gemfile.lock b/Gemfile.lock index 1ec3eb0..32678de 100644 --- a/Gemfile.lock +++ b/Gemfile.lock @@ -538,9 +538,7 @@ GEM mime-types-data (3.2026.0224) mini_magick (4.13.2) mini_mime (1.1.5) - minitest (6.0.2) - drb (~> 2.0) - prism (~> 1.5) + minitest (5.26.2) msgpack (1.8.0) multi_xml (0.8.1) bigdecimal (>= 3.1, < 5) @@ -600,7 +598,7 @@ GEM omniauth-twitter (1.4.0) omniauth-oauth (~> 1.1) rack - openssl (4.0.1) + openssl (3.3.0) orm_adapter (0.5.0) ostruct (0.6.3) package_json (0.2.0) @@ -630,7 +628,7 @@ GEM net-smtp premailer (~> 1.7, >= 1.7.9) prettyprint (0.2.0) - prism (1.9.0) + prism (1.4.0) psych (5.3.1) date stringio @@ -763,9 +761,9 @@ GEM rubocop-ast (>= 1.45.1, < 2.0) ruby-progressbar (~> 1.7) unicode-display_width (>= 2.4.0, < 4.0) - rubocop-ast (1.49.0) + rubocop-ast (1.48.0) parser (>= 3.3.7.2) - prism (~> 1.7) + prism (~> 1.4) rubocop-capybara (2.22.1) lint_roller (~> 1.1) rubocop (~> 1.72, >= 1.72.1) @@ -917,6 +915,7 @@ DEPENDENCIES faker (= 3.5.3) letter_opener_web (~> 2.0) listen (~> 3.1) + openssl (= 3.3.0) puma (>= 6.3.1) rubocop-faker spring (~> 4.0) From a42aba67e11c09f6784405a7be05720994f85653 Mon Sep 17 00:00:00 2001 From: stephanie rousset Date: Wed, 4 Mar 2026 17:22:42 +0100 Subject: [PATCH 14/17] style: update with rubocop --- lib/decidim/budgets_importer.rb | 1 + lib/decidim/budgets_importer/import/project_creator.rb | 1 + .../budgets_importer/admin/import_project_spec.rb | 10 +++++----- 3 files changed, 7 insertions(+), 5 deletions(-) diff --git a/lib/decidim/budgets_importer.rb b/lib/decidim/budgets_importer.rb index 49f0b75..7dcf1f0 100644 --- a/lib/decidim/budgets_importer.rb +++ b/lib/decidim/budgets_importer.rb @@ -55,6 +55,7 @@ def initialize(i18n_key) class TaxonomyNotFound < DependencyNotFound attr_reader :ids + def initialize(project_title, ids) @project_title = project_title @ids = ids diff --git a/lib/decidim/budgets_importer/import/project_creator.rb b/lib/decidim/budgets_importer/import/project_creator.rb index c1d1d52..c87f920 100644 --- a/lib/decidim/budgets_importer/import/project_creator.rb +++ b/lib/decidim/budgets_importer/import/project_creator.rb @@ -116,6 +116,7 @@ def related_taxonomies @taxonomies = taxonomies end + def available_locales @available_locales ||= component.organization.available_locales end diff --git a/spec/commands/decidim/budgets_importer/admin/import_project_spec.rb b/spec/commands/decidim/budgets_importer/admin/import_project_spec.rb index 8c90c9b..e2e1afe 100644 --- a/spec/commands/decidim/budgets_importer/admin/import_project_spec.rb +++ b/spec/commands/decidim/budgets_importer/admin/import_project_spec.rb @@ -7,15 +7,15 @@ module BudgetsImporter module Admin describe ImportProject do describe "call" do - let(:organization) { create :organization } - let(:current_user) { create :user, :admin, :confirmed, organization: organization } - let(:participatory_process) { create :participatory_process, organization: organization } + let(:organization) { create(:organization) } + let(:current_user) { create(:user, :admin, :confirmed, organization: organization) } + let(:participatory_process) { create(:participatory_process, organization: organization) } let(:current_component) { create(:component, manifest_name: :budgets, participatory_space: participatory_process) } let!(:proposal_component) { create(:proposal_component, participatory_space: participatory_process) } let!(:proposal) { create(:proposal, id: 1, component: proposal_component) } let!(:proposal2) { create(:proposal, id: 2, component: proposal_component) } - let(:budget) { create :budget, component: current_component } - let!(:taxonomy) { create(:taxonomy, :with_parent, id: 1, organization:) } + let(:budget) { create(:budget, component: current_component) } + let!(:taxonomy) { create(:taxonomy, :with_parent, id: 1, organization:) } let(:document) { upload_test_file(fixture_test_file(filename, mime_type)) } let(:filename) { "projects-import.csv" } let(:mime_type) { "text/csv" } From f88b4d25099b07a0f896f5b73607f49c6fd20969 Mon Sep 17 00:00:00 2001 From: stephanie rousset Date: Wed, 4 Mar 2026 17:32:53 +0100 Subject: [PATCH 15/17] refactor: project_creator methods with rubocop --- .../budgets_importer/import/project_creator.rb | 12 ++++-------- 1 file changed, 4 insertions(+), 8 deletions(-) diff --git a/lib/decidim/budgets_importer/import/project_creator.rb b/lib/decidim/budgets_importer/import/project_creator.rb index c87f920..bb7b3c6 100644 --- a/lib/decidim/budgets_importer/import/project_creator.rb +++ b/lib/decidim/budgets_importer/import/project_creator.rb @@ -62,19 +62,15 @@ def budget_amount def proposal_ids return [data[:related_proposals].to_i] if data[:related_proposals].is_a? Float - data[:related_proposals] - &.split(",") - &.flatten - &.map(&:to_i) || [] + ids = data[:related_proposals]&.split(",") + ids&.flatten&.map(&:to_i) || [] end def taxonomy_ids return [data[:"taxonomies/ids"].to_i] if data[:"taxonomies/ids"].is_a? Float - data[:"taxonomies/ids"] - &.split(",") - &.flatten - &.map(&:to_i) || [] + ids = data[:"taxonomies/ids"]&.split(",") + ids&.flatten&.map(&:to_i) || [] end def component From e82af44d2c3b92b0b30219ad996e3ed615c82775 Mon Sep 17 00:00:00 2001 From: AyakorK Date: Mon, 23 Mar 2026 17:23:39 +0100 Subject: [PATCH 16/17] fix: Change import page to match 0.31 design --- .../admin/projects_imports/new.html.erb | 46 +++++++++++-------- 1 file changed, 26 insertions(+), 20 deletions(-) diff --git a/app/views/decidim/budgets_importer/admin/projects_imports/new.html.erb b/app/views/decidim/budgets_importer/admin/projects_imports/new.html.erb index 3ec2056..99eedb5 100644 --- a/app/views/decidim/budgets_importer/admin/projects_imports/new.html.erb +++ b/app/views/decidim/budgets_importer/admin/projects_imports/new.html.erb @@ -1,24 +1,30 @@ -<%= decidim_form_for(@form, url: budget_projects_import_index_path(budget), html: { class: "form import_projects" }) do |f| %> -
-
-

<%= t(".title") %>

-
- -
-

<%== t(".callout.help") %>

- -
-
- <%= t(".document_legend") %> -
- <%= f.upload :document, optional: false, help_i18n_messages: ["import_document", "import_accepted_formats"] %> +<% add_decidim_page_title(t(".title")) %> +
+

+ <%= t(".title") %> +

+
+
+
+ <%= decidim_form_for(@form, url: budget_projects_import_index_path(budget), html: { class: "form import_projects" }) do |f| %> +
+
+
+
+

<%== t(".callout.help") %>

+
+
+ <%= f.upload :document, optional: false, help_i18n_messages: ["import_document", "import_accepted_formats"], button_class: "button button__sm button__transparent-secondary" %> +
-
+
-
-
-
- <%= f.submit t(".create") %> +
+
+ <%= f.submit t(".create"), class: "button button__sm button__secondary" %> +
+
+ <% end %>
-<% end %> + From 509ab6e37fc19ed1825ff0096545c4c8fc233604 Mon Sep 17 00:00:00 2001 From: AyakorK Date: Mon, 23 Mar 2026 17:48:59 +0100 Subject: [PATCH 17/17] fix: remove unused locales --- config/locales/en.yml | 1 - config/locales/fr.yml | 1 - 2 files changed, 2 deletions(-) diff --git a/config/locales/en.yml b/config/locales/en.yml index cafc5ee..511b9d2 100644 --- a/config/locales/en.yml +++ b/config/locales/en.yml @@ -30,7 +30,6 @@ en: and 'description/ca') and 'budget_amount'. Also 'taxonomies/ids' and 'related_proposals' columns are supported. create: Import - document_legend: Join the document to import title: Import projects in current budget command: import: diff --git a/config/locales/fr.yml b/config/locales/fr.yml index c0ca84a..ffb3f14 100644 --- a/config/locales/fr.yml +++ b/config/locales/fr.yml @@ -30,7 +30,6 @@ fr: 'description/en') et 'budget_amount'. Les colonnes taxonomies/ids et 'related_proposals' sont supportées et optionnelles. create: Importer - document_legend: Joindre le document à importer title: Importer des projets dans le budget command: import: