Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
22 commits
Select commit Hold shift + click to select a range
e55cff9
LG-14933 Remove extra space from document capture form. (#11842)
jmax-gsa Feb 6, 2025
9bd1067
LG-15559: Add support for A/B tests daily reporting (#11835)
aduth Feb 6, 2025
e02df31
LG-14753 Bug fix for sign-in page losing user progress (#11783)
kevinsmaster5 Feb 6, 2025
0cb8aa3
Omit errors from serialized form response if details present (#11846)
aduth Feb 6, 2025
910c5f0
LG-15294: Integrate Flow Policy with IPP steps - State ID and Address…
jennyverdeyen Feb 7, 2025
155094e
LG-14947 - stale data trigger update idp job (#11797)
colter-nattrass Feb 7, 2025
aa462e3
Remove fetch to avoid unnecessary hash allocation (#11854)
Feb 7, 2025
f11a1e6
Remove method_missing usage in Idv::Session (#11857)
zachmargolis Feb 7, 2025
4977a5d
Update to Ruby 3.4.1 (#11856)
Feb 7, 2025
a2eb0ba
Invert default logging behavior for A/B test (#11862)
aduth Feb 10, 2025
41aff44
Update AnalyticsEventsDocumenter to require exact "**extra" (#11860)
aduth Feb 10, 2025
4a29ca2
LG-15560: Enhance A/B tests to support configurable max participants …
aduth Feb 10, 2025
3ff04e0
Bump phonelib from 0.10.3 to 0.10.4 (#11863)
dependabot[bot] Feb 10, 2025
a21efa9
Lg-14066 implement new language for rate limit screen (#11849)
AShukla-GSA Feb 10, 2025
583006d
Log errors for profile reactivity password submitted (#11822)
aduth Feb 10, 2025
d70e876
Add A/B testing documentation (#11859)
aduth Feb 10, 2025
adfd630
Update net-imap gem to 0.5.6 (#11865)
aduth Feb 10, 2025
fa802ad
Experiment: remove (believed unnecessary) filter skips. (#11861)
jmax-gsa Feb 10, 2025
2f0b7e5
changelog: Internal, Analytics, Add list of integrations not includin…
Sgtpluck Feb 11, 2025
e38f6fb
Lg 15490 track tab navigation click (#11839)
mdiarra3 Feb 11, 2025
35dcaf2
LG-15456: Source AAMVA requested attributes from request (#11826)
lmgeorge Feb 11, 2025
680134d
Limit Webpack dev server allowed CORS origins (#11866)
aduth Feb 11, 2025
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .gitlab-ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ variables:
FF_SCRIPT_SECTIONS: 'true'
JUNIT_OUTPUT: 'true'
ECR_REGISTRY: '${AWS_ACCOUNT_ID}.dkr.ecr.${AWS_REGION}.amazonaws.com'
IDP_CI_SHA: 'sha256:37766e5b4aaeaad72dc8d18aa73236558ae5abd478073f5005783c44d6d6e87e'
IDP_CI_SHA: 'sha256:96e9cfbcedcc8d2c6736d736ebc6462bbd2fed3250f513facb632f6f87c0c862'
PKI_IMAGE_TAG: 'main'
DASHBOARD_IMAGE_TAG: 'main'
APPLICATION_MANIFEST: dockerfiles/application.yaml
Expand Down
2 changes: 1 addition & 1 deletion .rubocop.yml
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ AllCops:
- 'tmp/**/*'
- 'vendor/**/*'
- 'public/**/*'
TargetRubyVersion: 3.3.0
TargetRubyVersion: 3.4
TargetRailsVersion: 8.0
UseCache: true
DisabledByDefault: true
Expand Down
2 changes: 1 addition & 1 deletion .ruby-version
Original file line number Diff line number Diff line change
@@ -1 +1 @@
3.3.6
3.4.1
3 changes: 1 addition & 2 deletions Gemfile
Original file line number Diff line number Diff line change
Expand Up @@ -109,10 +109,9 @@ group :development, :test do
gem 'knapsack'
gem 'listen'
gem 'net-http-persistent', '~> 4.0.2', require: false
gem 'nokogiri', '~> 1.16.0'
gem 'nokogiri', '~> 1.18.0'
gem 'pg_query', require: false
gem 'pry-byebug'
gem 'pry-doc'
gem 'pry-rails'
gem 'psych'
gem 'rspec', '~> 3.13.0'
Expand Down
28 changes: 12 additions & 16 deletions Gemfile.lock
Original file line number Diff line number Diff line change
Expand Up @@ -230,7 +230,7 @@ GEM
smart_properties
bigdecimal (3.1.9)
bindata (2.4.15)
bootsnap (1.18.3)
bootsnap (1.18.4)
msgpack (~> 1.2)
brakeman (6.2.2)
racc
Expand Down Expand Up @@ -338,7 +338,7 @@ GEM
net-http (>= 0.5.0)
faraday-retry (2.0.0)
faraday (~> 2.0)
ffi (1.17.0)
ffi (1.17.1)
ffi-compiler (1.3.2)
ffi (>= 1.15.5)
rake
Expand All @@ -358,7 +358,7 @@ GEM
fugit (>= 1.11.0)
railties (>= 6.1.0)
thor (>= 1.0.0)
google-protobuf (4.29.1)
google-protobuf (4.29.3)
bigdecimal
rake (>= 13)
hashdiff (1.1.2)
Expand Down Expand Up @@ -440,13 +440,13 @@ GEM
mini_mime (1.1.5)
mini_portile2 (2.8.8)
minitest (5.25.4)
msgpack (1.7.5)
msgpack (1.8.0)
multiset (0.5.3)
net-http (0.6.0)
uri
net-http-persistent (4.0.2)
connection_pool (~> 2.2)
net-imap (0.5.1)
net-imap (0.5.6)
date
net-protocol
net-pop (0.1.2)
Expand All @@ -460,7 +460,7 @@ GEM
net-ssh (6.1.0)
newrelic_rpm (9.7.0)
nio4r (2.7.4)
nokogiri (1.16.8)
nokogiri (1.18.2)
mini_portile2 (~> 2.8.2)
racc (~> 1.4)
numbers_and_words (0.11.12)
Expand All @@ -477,7 +477,7 @@ GEM
pg (1.5.9)
pg_query (5.1.0)
google-protobuf (>= 3.22.3)
phonelib (0.10.3)
phonelib (0.10.4)
pkcs11 (0.3.4)
premailer (1.27.0)
addressable
Expand All @@ -501,12 +501,9 @@ GEM
pry-byebug (3.10.1)
byebug (~> 11.0)
pry (>= 0.13, < 0.15)
pry-doc (1.5.0)
pry (~> 0.11)
yard (~> 0.9.11)
pry-rails (0.3.11)
pry (>= 0.13.0)
psych (5.2.1)
psych (5.2.3)
date
stringio
public_suffix (6.0.1)
Expand Down Expand Up @@ -688,7 +685,7 @@ GEM
simplecov_json_formatter (0.1.4)
simpleidn (0.2.3)
smart_properties (1.17.0)
sqlite3 (2.4.1)
sqlite3 (2.5.0)
mini_portile2 (~> 2.8.0)
stringex (2.8.5)
stringio (3.1.2)
Expand Down Expand Up @@ -820,7 +817,7 @@ DEPENDENCIES
net-http-persistent (~> 4.0.2)
net-sftp
newrelic_rpm (~> 9.0)
nokogiri (~> 1.16.0)
nokogiri (~> 1.18.0)
numbers_and_words (~> 0.11.12)
pg
pg_query
Expand All @@ -830,7 +827,6 @@ DEPENDENCIES
prometheus_exporter
propshaft
pry-byebug
pry-doc
pry-rails
psych
puma (~> 6.0)
Expand Down Expand Up @@ -888,7 +884,7 @@ DEPENDENCIES
zxcvbn (= 0.1.12)

RUBY VERSION
ruby 3.3.6p108
ruby 3.4.1p0

BUNDLED WITH
2.5.23
2.6.3
1 change: 1 addition & 0 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@
CONFIG = config/application.yml
HOST ?= localhost
PORT ?= 3000
ORIGIN_PORT ?= $(PORT)
GZIP_COMMAND ?= gzip
ARTIFACT_DESTINATION_FILE ?= ./tmp/idp.tar.gz

Expand Down
2 changes: 1 addition & 1 deletion Procfile
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
web: WEBPACK_PORT=${WEBPACK_PORT:-3035} bundle exec rackup config.ru --port ${PORT:-3000} --host ${FOREMAN_HOST:-${HOST:-localhost}}
worker: bundle exec good_job start
js: WEBPACK_PORT=${WEBPACK_PORT:-3035} yarn webpack --watch
js: WEBPACK_PORT=${WEBPACK_PORT:-3035} ORIGIN_PORT=${ORIGIN_PORT:-3000} yarn webpack --watch
css: yarn build:css --watch
1 change: 1 addition & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,7 @@ Refer to the [_Local Development_ documentation](./docs/local-development.md) to

## Documentation

- [A/B Testing](docs/ab-testing.md)
- [Back-end Architecture](docs/backend.md)
- [Front-end Architecture](docs/frontend.md)
- [Local Development](docs/local-development.md)
Expand Down
3 changes: 3 additions & 0 deletions app/assets/stylesheets/design-system-waiting-room.scss
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,9 @@ ul {
.break-word {
word-wrap: break-word;
}
.display-list-item {
display: list-item;
}

.truncate {
max-width: 100%;
Expand Down
13 changes: 10 additions & 3 deletions app/components/click_observer_component.rb
Original file line number Diff line number Diff line change
@@ -1,14 +1,21 @@
# frozen_string_literal: true

class ClickObserverComponent < BaseComponent
attr_reader :event_name, :tag_options
attr_reader :event_name, :tag_options, :payload

def initialize(event_name:, **tag_options)
def initialize(event_name:, payload: nil, **tag_options)
@event_name = event_name
@payload = payload
@tag_options = tag_options
end

def call
content_tag(:'lg-click-observer', content, 'event-name': @event_name, **tag_options)
content_tag(
:'lg-click-observer',
content,
'event-name': @event_name,
payload: payload.to_json,
**tag_options,
)
end
end
32 changes: 24 additions & 8 deletions app/components/tab_navigation_component.html.erb
Original file line number Diff line number Diff line change
@@ -1,14 +1,30 @@
<%= content_tag(:nav, aria: { label: }, **tag_options, class: [*tag_options[:class], 'tab-navigation']) do %>
<ul class="usa-button-group usa-button-group--segmented">
<% routes.each do |route| %>
<li class="usa-button-group__item">
<%= render ButtonComponent.new(
url: route[:path],
big: true,
outline: !current_path?(route[:path]),
aria: { current: current_path?(route[:path]) ? 'page' : nil },
).with_content(route[:text]) %>
</li>
<% if current_path?(route[:path]) %>
<%= render ClickObserverComponent.new(
event_name: 'tab_navigation_current_page_clicked',
payload: { path: route[:path] },
role: 'listitem',
class: 'usa-button-group__item display-list-item',
) do %>
<%= render ButtonComponent.new(
url: route[:path],
big: true,
outline: !current_path?(route[:path]),
aria: { current: current_path?(route[:path]) ? 'page' : nil },
).with_content(route[:text]) %>
<% end %>
<% else %>
<li class="usa-button-group__item">
<%= render ButtonComponent.new(
url: route[:path],
big: true,
outline: !current_path?(route[:path]),
aria: { current: current_path?(route[:path]) ? 'page' : nil },
).with_content(route[:text]) %>
</li>
<% end %>
<% end %>
</ul>
<% end %>
11 changes: 3 additions & 8 deletions app/controllers/concerns/rate_limit_concern.rb
Original file line number Diff line number Diff line change
Expand Up @@ -5,9 +5,9 @@ module RateLimitConcern

ALL_IDV_RATE_LIMITERS = [:idv_resolution, :idv_doc_auth, :proof_ssn].freeze

def confirm_not_rate_limited(rate_limiters = ALL_IDV_RATE_LIMITERS)
def confirm_not_rate_limited(rate_limiters = ALL_IDV_RATE_LIMITERS, check_last_submission: false)
exceeded_rate_limits = check_for_exceeded_rate_limits(rate_limiters)
if exceeded_rate_limits.any? && !final_hybrid_submission_passed?
if exceeded_rate_limits.any? && !(check_last_submission && final_submission_passed?)
rate_limit_redirect!(exceeded_rate_limits.first)
return true
end
Expand All @@ -28,18 +28,13 @@ def confirm_not_rate_limited_for_phone_address_verification

private

def final_hybrid_submission_passed?
def final_submission_passed?
doc_session_idv = user_session.to_h['idv']
return false if doc_session_idv.blank?

doc_session_uuid = doc_session_idv['document_capture_session_uuid']
return false if doc_session_uuid.blank?

flow_path = doc_session_idv['flow_path']
return false if flow_path.blank?

return false if flow_path != 'hybrid'

document_capture_session = DocumentCaptureSession.find_by(uuid: doc_session_uuid)
return false if document_capture_session.nil?

Expand Down
1 change: 1 addition & 0 deletions app/controllers/frontend_log_controller.rb
Original file line number Diff line number Diff line change
Expand Up @@ -58,6 +58,7 @@ class FrontendLogController < ApplicationController
idv_selfie_image_added
idv_selfie_image_clicked
phone_input_country_changed
tab_navigation_current_page_clicked
].freeze

EVENT_MAP = ALLOWED_EVENTS.index_by(&:to_s).merge(LEGACY_EVENT_MAP).freeze
Expand Down
2 changes: 1 addition & 1 deletion app/controllers/idv/document_capture_controller.rb
Original file line number Diff line number Diff line change
Expand Up @@ -60,7 +60,7 @@ def self.step_info
Idv::StepInfo.new(
key: :document_capture,
controller: self,
next_steps: [:ssn, :ipp_ssn], # :ipp_state_id
next_steps: [:ssn, :ipp_state_id],
preconditions: ->(idv_session:, user:) {
idv_session.flow_path == 'standard' && (
# mobile
Expand Down
23 changes: 4 additions & 19 deletions app/controllers/idv/in_person/address_controller.rb
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ class AddressController < ApplicationController
include Idv::AvailabilityConcern
include IdvStepConcern

before_action :confirm_in_person_state_id_step_complete
before_action :confirm_step_allowed
before_action :confirm_in_person_address_step_needed, only: :show
before_action :set_usps_form_presenter

Expand Down Expand Up @@ -45,36 +45,26 @@ def extra_view_variables
}
end

# update Idv::DocumentCaptureController.step_info.next_steps to include
# :ipp_address instead of :ipp_ssn in delete PR
def self.step_info
Idv::StepInfo.new(
key: :ipp_address,
controller: self,
next_steps: [:ipp_ssn],
preconditions: ->(idv_session:, user:) { idv_session.ipp_state_id_complete? },
undo_step: ->(idv_session:, user:) do
flow_session[:pii_from_user][:address1] = nil
flow_session[:pii_from_user][:address2] = nil
flow_session[:pii_from_user][:city] = nil
flow_session[:pii_from_user][:zipcode] = nil
flow_session[:pii_from_user][:state] = nil
idv_session.invalidate_in_person_address_step!
end,
)
end

private

def flow_session
user_session.fetch('idv/in_person', {})
end

def updating_address?
flow_session[:pii_from_user].has_key?(:address1) && user_session[:idv].has_key?(:ssn)
pii_from_user.has_key?(:address1) && user_session[:idv].has_key?(:ssn)
end

def pii
data = flow_session[:pii_from_user]
data = pii_from_user
data = data.merge(flow_params) if params.has_key?(:in_person_address)
data.deep_symbolize_keys
end
Expand Down Expand Up @@ -106,11 +96,6 @@ def redirect_to_next_page
end
end

def confirm_in_person_state_id_step_complete
return if pii_from_user&.has_key?(:identity_doc_address1)
redirect_to idv_in_person_state_id_url
end

def confirm_in_person_address_step_needed
return if pii_from_user&.dig(:same_address_as_id) == 'false' &&
!pii_from_user.has_key?(:address1)
Expand Down
Loading