Skip to content

Commit

Permalink
Merge pull request #338 from sanger/depfu/update/group/rails-7.0.8.3
Browse files Browse the repository at this point in the history
🚨 [security] Update rails 6.1.7.7 → 7.0.8.3 (major)
  • Loading branch information
BenTopping authored Jun 24, 2024
2 parents c7050f2 + 25f2ea6 commit 3cc8fd3
Show file tree
Hide file tree
Showing 13 changed files with 107 additions and 153 deletions.
2 changes: 1 addition & 1 deletion Gemfile
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

source 'https://rubygems.org'

gem 'rails', '~>6.1.0'
gem 'rails', '~> 7.0.8'

group :development, :test do
gem 'byebug'
Expand Down
158 changes: 79 additions & 79 deletions Gemfile.lock
Original file line number Diff line number Diff line change
Expand Up @@ -7,40 +7,47 @@ GIT
GEM
remote: https://rubygems.org/
specs:
actioncable (6.1.7.7)
actionpack (= 6.1.7.7)
activesupport (= 6.1.7.7)
actioncable (7.0.8.3)
actionpack (= 7.0.8.3)
activesupport (= 7.0.8.3)
nio4r (~> 2.0)
websocket-driver (>= 0.6.1)
actionmailbox (6.1.7.7)
actionpack (= 6.1.7.7)
activejob (= 6.1.7.7)
activerecord (= 6.1.7.7)
activestorage (= 6.1.7.7)
activesupport (= 6.1.7.7)
actionmailbox (7.0.8.3)
actionpack (= 7.0.8.3)
activejob (= 7.0.8.3)
activerecord (= 7.0.8.3)
activestorage (= 7.0.8.3)
activesupport (= 7.0.8.3)
mail (>= 2.7.1)
actionmailer (6.1.7.7)
actionpack (= 6.1.7.7)
actionview (= 6.1.7.7)
activejob (= 6.1.7.7)
activesupport (= 6.1.7.7)
net-imap
net-pop
net-smtp
actionmailer (7.0.8.3)
actionpack (= 7.0.8.3)
actionview (= 7.0.8.3)
activejob (= 7.0.8.3)
activesupport (= 7.0.8.3)
mail (~> 2.5, >= 2.5.4)
net-imap
net-pop
net-smtp
rails-dom-testing (~> 2.0)
actionpack (6.1.7.7)
actionview (= 6.1.7.7)
activesupport (= 6.1.7.7)
rack (~> 2.0, >= 2.0.9)
actionpack (7.0.8.3)
actionview (= 7.0.8.3)
activesupport (= 7.0.8.3)
rack (~> 2.0, >= 2.2.4)
rack-test (>= 0.6.3)
rails-dom-testing (~> 2.0)
rails-html-sanitizer (~> 1.0, >= 1.2.0)
actiontext (6.1.7.7)
actionpack (= 6.1.7.7)
activerecord (= 6.1.7.7)
activestorage (= 6.1.7.7)
activesupport (= 6.1.7.7)
actiontext (7.0.8.3)
actionpack (= 7.0.8.3)
activerecord (= 7.0.8.3)
activestorage (= 7.0.8.3)
activesupport (= 7.0.8.3)
globalid (>= 0.6.0)
nokogiri (>= 1.8.5)
actionview (6.1.7.7)
activesupport (= 6.1.7.7)
actionview (7.0.8.3)
activesupport (= 7.0.8.3)
builder (~> 3.1)
erubi (~> 1.4)
rails-dom-testing (~> 2.0)
Expand All @@ -50,40 +57,39 @@ GEM
activemodel (>= 4.1)
case_transform (>= 0.2)
jsonapi-renderer (>= 0.1.1.beta1, < 0.3)
activejob (6.1.7.7)
activesupport (= 6.1.7.7)
activejob (7.0.8.3)
activesupport (= 7.0.8.3)
globalid (>= 0.3.6)
activemodel (6.1.7.7)
activesupport (= 6.1.7.7)
activerecord (6.1.7.7)
activemodel (= 6.1.7.7)
activesupport (= 6.1.7.7)
activestorage (6.1.7.7)
actionpack (= 6.1.7.7)
activejob (= 6.1.7.7)
activerecord (= 6.1.7.7)
activesupport (= 6.1.7.7)
activemodel (7.0.8.3)
activesupport (= 7.0.8.3)
activerecord (7.0.8.3)
activemodel (= 7.0.8.3)
activesupport (= 7.0.8.3)
activestorage (7.0.8.3)
actionpack (= 7.0.8.3)
activejob (= 7.0.8.3)
activerecord (= 7.0.8.3)
activesupport (= 7.0.8.3)
marcel (~> 1.0)
mini_mime (>= 1.1.0)
activesupport (6.1.7.7)
activesupport (7.0.8.3)
concurrent-ruby (~> 1.0, >= 1.0.2)
i18n (>= 1.6, < 2)
minitest (>= 5.1)
tzinfo (~> 2.0)
zeitwerk (~> 2.3)
ast (2.4.2)
bootsnap (1.18.3)
msgpack (~> 1.2)
builder (3.2.4)
builder (3.3.0)
byebug (11.1.3)
case_transform (0.2)
activesupport
coderay (1.1.3)
concurrent-ruby (1.2.3)
concurrent-ruby (1.3.3)
crass (1.0.6)
date (3.3.4)
diff-lcs (1.5.1)
erubi (1.12.0)
erubi (1.13.0)
exception_notification (4.5.0)
actionmailer (>= 5.2, < 8)
activesupport (>= 5.2, < 8)
Expand All @@ -95,7 +101,7 @@ GEM
ffi (1.16.3)
globalid (1.2.1)
activesupport (>= 6.1)
i18n (1.14.4)
i18n (1.14.5)
concurrent-ruby (~> 1.0)
json (2.7.2)
jsonapi-renderer (0.2.2)
Expand All @@ -111,29 +117,29 @@ GEM
net-imap
net-pop
net-smtp
marcel (1.0.2)
method_source (1.0.0)
marcel (1.0.4)
method_source (1.1.0)
mini_mime (1.1.5)
minitest (5.22.3)
minitest (5.24.0)
mocha (2.3.0)
ruby2_keywords (>= 0.0.5)
msgpack (1.7.2)
mysql2 (0.5.6)
net-imap (0.4.10)
net-imap (0.4.13)
date
net-protocol
net-pop (0.1.2)
net-protocol
net-protocol (0.2.2)
timeout
net-smtp (0.4.0.1)
net-smtp (0.5.0)
net-protocol
nio4r (2.7.0)
nokogiri (1.16.5-arm64-darwin)
nio4r (2.7.3)
nokogiri (1.16.6-arm64-darwin)
racc (~> 1.4)
nokogiri (1.16.5-x86_64-darwin)
nokogiri (1.16.6-x86_64-darwin)
racc (~> 1.4)
nokogiri (1.16.5-x86_64-linux)
nokogiri (1.16.6-x86_64-linux)
racc (~> 1.4)
parallel (1.24.0)
parser (3.3.1.0)
Expand All @@ -150,21 +156,20 @@ GEM
rack (>= 2.0.0)
rack-test (2.1.0)
rack (>= 1.3)
rails (6.1.7.7)
actioncable (= 6.1.7.7)
actionmailbox (= 6.1.7.7)
actionmailer (= 6.1.7.7)
actionpack (= 6.1.7.7)
actiontext (= 6.1.7.7)
actionview (= 6.1.7.7)
activejob (= 6.1.7.7)
activemodel (= 6.1.7.7)
activerecord (= 6.1.7.7)
activestorage (= 6.1.7.7)
activesupport (= 6.1.7.7)
rails (7.0.8.3)
actioncable (= 7.0.8.3)
actionmailbox (= 7.0.8.3)
actionmailer (= 7.0.8.3)
actionpack (= 7.0.8.3)
actiontext (= 7.0.8.3)
actionview (= 7.0.8.3)
activejob (= 7.0.8.3)
activemodel (= 7.0.8.3)
activerecord (= 7.0.8.3)
activestorage (= 7.0.8.3)
activesupport (= 7.0.8.3)
bundler (>= 1.15.0)
railties (= 6.1.7.7)
sprockets-rails (>= 2.0.0)
railties (= 7.0.8.3)
rails-dom-testing (2.2.0)
activesupport (>= 5.0.0)
minitest
Expand All @@ -173,14 +178,15 @@ GEM
loofah (~> 2.21)
nokogiri (~> 1.14)
rails-perftest (0.0.7)
railties (6.1.7.7)
actionpack (= 6.1.7.7)
activesupport (= 6.1.7.7)
railties (7.0.8.3)
actionpack (= 7.0.8.3)
activesupport (= 7.0.8.3)
method_source
rake (>= 12.2)
thor (~> 1.0)
zeitwerk (~> 2.5)
rainbow (3.1.1)
rake (13.1.0)
rake (13.2.1)
rb-fsevent (0.11.2)
rb-inotify (0.10.1)
ffi (~> 1.0)
Expand Down Expand Up @@ -238,13 +244,6 @@ GEM
ruby2_keywords (0.0.5)
spring (4.2.1)
sprint_client (0.1.0)
sprockets (4.2.1)
concurrent-ruby (~> 1.0)
rack (>= 2.2.4, < 4)
sprockets-rails (3.4.2)
actionpack (>= 5.2)
activesupport (>= 5.2)
sprockets (>= 3.0.0)
sqlite3 (1.7.3-arm64-darwin)
sqlite3 (1.7.3-x86_64-darwin)
sqlite3 (1.7.3-x86_64-linux)
Expand All @@ -257,10 +256,11 @@ GEM
websocket-driver (0.7.6)
websocket-extensions (>= 0.1.0)
websocket-extensions (0.1.5)
zeitwerk (2.6.13)
zeitwerk (2.6.16)

PLATFORMS
arm64-darwin-22
arm64-darwin-23
x86_64-darwin-21
x86_64-linux

Expand All @@ -277,7 +277,7 @@ DEPENDENCIES
psd_logger!
puma
rack-cors
rails (~> 6.1.0)
rails (~> 7.0.8)
rails-perftest
rspec-rails
rubocop
Expand Down
10 changes: 0 additions & 10 deletions app/label_printer/label_printer/print_job.rb
Original file line number Diff line number Diff line change
Expand Up @@ -10,16 +10,6 @@ module LabelPrinter
# TOF is also available to check that the text is
# correct or to allow you to send a job manually.
module PrintJob
# This is neccessary for Travis to pass.
# When the build method is called in tests the
# subclasses of print job are not loaded
# so we get a constant does not exist method.
# TODO: modify the build method so it doesn't use constantize."
require_relative 'print_job/base'
require_relative 'print_job/LPD'
require_relative 'print_job/IPP'
require_relative 'print_job/TOF'

##
# Build a new print job based on the protocol
# of the printer name that is passed.
Expand Down
3 changes: 0 additions & 3 deletions app/label_printer/label_printer/print_job/base.rb
Original file line number Diff line number Diff line change
Expand Up @@ -13,9 +13,6 @@ module PrintJob
class Base
include ActiveModel::Model
include ActiveModel::Serialization
include SubclassChecker

subclasses :LPD, :IPP, :TOF

attr_accessor :printer_name, :label_template_id, :printer, :labels
attr_reader :label_template, :data_input
Expand Down
20 changes: 0 additions & 20 deletions app/models/concerns/subclass_checker.rb

This file was deleted.

12 changes: 8 additions & 4 deletions app/models/drawing.rb
Original file line number Diff line number Diff line change
Expand Up @@ -7,17 +7,13 @@
# respect to its label.
# Each drawing must have a field name, x origin and y origin
class Drawing < ApplicationRecord
include SubclassChecker

before_create :add_placeholder_id

belongs_to :label, optional: true

validates :field_name, presence: true, format: { with: /\A[\w_]+\z/ }
validates :x_origin, :y_origin, presence: true, format: { with: /\A\d{4}\z/ }

subclasses :bitmap, :barcode

##
# e.g. 0001
def padded_placeholder_id
Expand Down Expand Up @@ -50,6 +46,14 @@ def self.permitted_attributes
(stored_attributes[:options] || []) + %i[x_origin y_origin field_name]
end

def barcode?
instance_of?(Barcode)
end

def bitmap?
instance_of?(Bitmap)
end

private

def add_placeholder_id
Expand Down
2 changes: 1 addition & 1 deletion config/application.rb
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@
module PrintMyBarcode
class Application < Rails::Application
# Initialize configuration defaults for originally generated Rails version.
config.load_defaults 6.1
config.load_defaults 7.0

# Settings in config/environments/* take precedence over those specified here.
# Application configuration can go into files in config/initializers
Expand Down
8 changes: 0 additions & 8 deletions config/environments/development.rb
Original file line number Diff line number Diff line change
Expand Up @@ -44,14 +44,6 @@
# Highlight code that triggered database queries in logs.
config.active_record.verbose_query_logs = true

# Debug mode disables concatenation and preprocessing of assets.
# This option may cause significant delays in view rendering with a large
# number of complex assets.
config.assets.debug = true

# Suppress logger output for asset requests.
config.assets.quiet = true

# Default setting for adding printers to cupsd server on printer create
config.auto_create_printer_in_cupsd = false

Expand Down
9 changes: 0 additions & 9 deletions config/environments/production.rb
Original file line number Diff line number Diff line change
Expand Up @@ -22,15 +22,6 @@
# Apache or NGINX already handles this.
config.public_file_server.enabled = ENV['RAILS_SERVE_STATIC_FILES'].present?

# Compress JavaScripts and CSS.
config.assets.js_compressor = :uglifier
# config.assets.css_compressor = :sass

# Do not fallback to assets pipeline if a precompiled asset is missed.
config.assets.compile = false

# `config.assets.precompile` and `config.assets.version` have moved to config/initializers/assets.rb

# Enable serving of images, stylesheets, and JavaScripts from an asset server.
# config.action_controller.asset_host = 'http://assets.example.com'

Expand Down
Loading

0 comments on commit 3cc8fd3

Please sign in to comment.