From 9353a8af6b78d0bcf743420713700dcb58e64e66 Mon Sep 17 00:00:00 2001 From: Sebb Date: Mon, 27 May 2024 15:34:06 +0100 Subject: [PATCH 1/9] Merge mail_list into main class --- lib/whimsy/asf/committee.rb | 42 ++++++++++++++++++++++++++++ lib/whimsy/asf/mail.rb | 56 ------------------------------------- lib/whimsy/asf/podling.rb | 10 +++++++ 3 files changed, 52 insertions(+), 56 deletions(-) diff --git a/lib/whimsy/asf/committee.rb b/lib/whimsy/asf/committee.rb index 0e9f0e7461..d9f53bfb8b 100644 --- a/lib/whimsy/asf/committee.rb +++ b/lib/whimsy/asf/committee.rb @@ -105,6 +105,48 @@ def self.to_canonical(name) @@namemap.call(name.downcase) end + # mailing list for this committee. Generally returns the first name in + # the dns (e.g. whimsical). If so, it can be prefixed by a number of + # list names (e.g. dev, private) and .apache.org is to be + # appended. In some cases, the name contains an @ sign and + # is the full name for the mail list. + def mail_list + case name.downcase + when 'comdev' + 'community' + when 'httpcomponents' + 'hc' + when 'whimsy' + 'whimsical' + + when 'brand' + 'trademarks@apache.org' + when 'infrastructure' + 'infra' + when 'dataprivacy' + 'privacy@apache.org' + when 'legalaffairs' # Not sure what uses this + 'legal-internal@apache.org' + when 'legal' # This seems to be used by the board agenda + 'legal-private@apache.org' + when 'fundraising' + 'fundraising-private@apache.org' + when 'marketingandpublicity' + 'press@apache.org' + # now using private@tac.apache.org + # when 'tac' + # 'travel-assistance@apache.org' + when 'w3crelations' + 'w3c@apache.org' + when 'concom' + 'planners@apachecon.com' + when 'publicaffairs' + 'public-affairs-private@apache.org' + else + name.downcase + end + end + # load committee info from committee-info.txt. Will not reparse # if the file has already been parsed and the underlying file has not # changed. diff --git a/lib/whimsy/asf/mail.rb b/lib/whimsy/asf/mail.rb index 38cea63142..944917f424 100644 --- a/lib/whimsy/asf/mail.rb +++ b/lib/whimsy/asf/mail.rb @@ -331,60 +331,4 @@ def all_mail end end - class Committee - # mailing list for this committee. Generally returns the first name in - # the dns (e.g. whimsical). If so, it can be prefixed by a number of - # list names (e.g. dev, private) and .apache.org is to be - # appended. In some cases, the name contains an @ sign and - # is the full name for the mail list. - def mail_list - case name.downcase - when 'comdev' - 'community' - when 'httpcomponents' - 'hc' - when 'whimsy' - 'whimsical' - - when 'brand' - 'trademarks@apache.org' - when 'infrastructure' - 'infra' - when 'dataprivacy' - 'privacy@apache.org' - when 'legalaffairs' # Not sure what uses this - 'legal-internal@apache.org' - when 'legal' # This seems to be used by the board agenda - 'legal-private@apache.org' - when 'fundraising' - 'fundraising-private@apache.org' - when 'marketingandpublicity' - 'press@apache.org' - # now using private@tac.apache.org - # when 'tac' - # 'travel-assistance@apache.org' - when 'w3crelations' - 'w3c@apache.org' - when 'concom' - 'planners@apachecon.com' - when 'publicaffairs' - 'public-affairs-private@apache.org' - else - name.downcase - end - end - end - - class Podling - # base name used in constructing mailing list name. - def mail_list - case name.downcase - when 'odftoolkit' - 'odf' - else - name.downcase - end - end - end - end diff --git a/lib/whimsy/asf/podling.rb b/lib/whimsy/asf/podling.rb index d2fa0cf374..b0ffb8c796 100644 --- a/lib/whimsy/asf/podling.rb +++ b/lib/whimsy/asf/podling.rb @@ -285,6 +285,16 @@ def hasLDAP? ASF::Project.find(id).hasLDAP? end + # base name used in constructing mailing list name. + def mail_list + case name.downcase + when 'odftoolkit' + 'odf' + else + name.downcase + end + end + # development mailing list associated with a given podling def dev_mail_list case name From 6abaa7ce9d7700461198be2c6005713d08d9c214 Mon Sep 17 00:00:00 2001 From: Sebb Date: Mon, 27 May 2024 15:39:29 +0100 Subject: [PATCH 2/9] Update checkout action --- .github/workflows/unittestagenda.yml | 2 +- .github/workflows/unittestlib.yml | 2 +- .github/workflows/unittestnavigation.yml | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/.github/workflows/unittestagenda.yml b/.github/workflows/unittestagenda.yml index e383eab185..63c42b0183 100644 --- a/.github/workflows/unittestagenda.yml +++ b/.github/workflows/unittestagenda.yml @@ -36,7 +36,7 @@ jobs: - uses: actions/setup-node@v3 with: node-version: 'v21.4.0' # works on macOS - - uses: actions/checkout@v3 + - uses: actions/checkout@v4 with: persist-credentials: false - uses: ruby/setup-ruby@v1 diff --git a/.github/workflows/unittestlib.yml b/.github/workflows/unittestlib.yml index 5653624a3a..ca0108ca3b 100644 --- a/.github/workflows/unittestlib.yml +++ b/.github/workflows/unittestlib.yml @@ -34,7 +34,7 @@ jobs: run: | brew install subversion if: ${{ runner.os == 'macOS' }} - - uses: actions/checkout@v3 + - uses: actions/checkout@v4 with: persist-credentials: false - name: ruby diff --git a/.github/workflows/unittestnavigation.yml b/.github/workflows/unittestnavigation.yml index 0eb5843d30..4984c72741 100644 --- a/.github/workflows/unittestnavigation.yml +++ b/.github/workflows/unittestnavigation.yml @@ -26,7 +26,7 @@ jobs: node-version: '18.16.0' # it seems that using the default Ubuntu version of node (14.19.0) # somehow fails to set the correct path for rake to use - - uses: actions/checkout@v3 + - uses: actions/checkout@v4 with: persist-credentials: false - uses: ruby/setup-ruby@v1 From d01b70f2f0d7998a953a78a01ddfd32e8e9b61c1 Mon Sep 17 00:00:00 2001 From: Sebb Date: Mon, 27 May 2024 15:45:22 +0100 Subject: [PATCH 3/9] Try an earlier macOS --- .github/workflows/unittestagenda.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/unittestagenda.yml b/.github/workflows/unittestagenda.yml index 63c42b0183..d375100513 100644 --- a/.github/workflows/unittestagenda.yml +++ b/.github/workflows/unittestagenda.yml @@ -16,7 +16,7 @@ jobs: strategy: fail-fast: true matrix: - os: [ubuntu-20.04, macos-latest] + os: [ubuntu-20.04, macos-13] ruby: [2.7] # os: [ubuntu-20.04, ubuntu-22.04] # ruby: [2.7, 3.1] @@ -32,7 +32,7 @@ jobs: sudo apt-get install libldap2-dev sudo apt-get install libsasl2-dev sudo apt-get install libyaml-dev # seems to be needed for installing ruby since psych 5.0.0 release - if: matrix.os != 'macos-latest' + if: runner.os != 'macOS' - uses: actions/setup-node@v3 with: node-version: 'v21.4.0' # works on macOS From d53fb891297c44913228dbc482e701ec129887ab Mon Sep 17 00:00:00 2001 From: Sebb Date: Mon, 27 May 2024 15:56:28 +0100 Subject: [PATCH 4/9] No need to create top-level dir --- .github/workflows/unittestagenda.yml | 9 ++++----- 1 file changed, 4 insertions(+), 5 deletions(-) diff --git a/.github/workflows/unittestagenda.yml b/.github/workflows/unittestagenda.yml index d375100513..f4b8dea1f6 100644 --- a/.github/workflows/unittestagenda.yml +++ b/.github/workflows/unittestagenda.yml @@ -14,9 +14,9 @@ permissions: # added using https://github.com/step-security/secure-workflows jobs: test: strategy: - fail-fast: true + fail-fast: false matrix: - os: [ubuntu-20.04, macos-13] + os: [ubuntu-20.04, macos-latest] ruby: [2.7] # os: [ubuntu-20.04, ubuntu-22.04] # ruby: [2.7, 3.1] @@ -50,10 +50,9 @@ jobs: - name: setup agenda 2 # need to run the ruby that has all the gems installed run: | - sudo mkdir -p /srv - sudo bash -c 'printf "\n\n\n" >/srv/ldap.txt' - ls -l /srv + bash -c 'printf "\n\n\n" >.ldap.txt' echo ":ldap: ldaps://ldap-us.apache.org:636" >> .whimsy + echo ":ldap_creds: $PWD/.ldap.txt" >> .whimsy sudo $(which ruby) -I $PWD/lib -r whimsy/asf -e "ASF::LDAP.configure" - name: show environ run: | From 90febbbe7fef7209e23f0c3d87ddc1a060751ff9 Mon Sep 17 00:00:00 2001 From: Sebb Date: Mon, 27 May 2024 16:46:38 +0100 Subject: [PATCH 5/9] Add subversion --- .github/workflows/unittestagenda.yml | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/.github/workflows/unittestagenda.yml b/.github/workflows/unittestagenda.yml index f4b8dea1f6..a7c9ef49bc 100644 --- a/.github/workflows/unittestagenda.yml +++ b/.github/workflows/unittestagenda.yml @@ -33,6 +33,11 @@ jobs: sudo apt-get install libsasl2-dev sudo apt-get install libyaml-dev # seems to be needed for installing ruby since psych 5.0.0 release if: runner.os != 'macOS' + # Default host no longer includes subversion + - name: setup macos + run: | + brew install subversion + if: ${{ runner.os == 'macOS' }} - uses: actions/setup-node@v3 with: node-version: 'v21.4.0' # works on macOS From 64d3018509df0e4e6c5ee1dd402159c4577d3c9c Mon Sep 17 00:00:00 2001 From: Sebb Date: Mon, 27 May 2024 17:07:43 +0100 Subject: [PATCH 6/9] Update to last Vue 2 release --- www/board/agenda/package.json | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/www/board/agenda/package.json b/www/board/agenda/package.json index 620276f6c5..e40ac3bce3 100644 --- a/www/board/agenda/package.json +++ b/www/board/agenda/package.json @@ -9,7 +9,7 @@ "jsdom": "^22.0.0", "jsdom-global": "^3.0.2", "jquery": "^3.2.1", - "vue": "^2.4.4", - "vue-server-renderer": "^2.4.4" + "vue": "^2.7.16", + "vue-server-renderer": "^2.7.16" } } From c7f0fc0fbe6b5df3e3e26bdc0e615e99ea8c20da Mon Sep 17 00:00:00 2001 From: Sebb Date: Mon, 27 May 2024 17:41:50 +0100 Subject: [PATCH 7/9] Try upgrade to Vue3 (compat) --- .github/workflows/unittestagenda.yml | 2 +- www/board/agenda/package.json | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/.github/workflows/unittestagenda.yml b/.github/workflows/unittestagenda.yml index a7c9ef49bc..a9a0ccba00 100644 --- a/.github/workflows/unittestagenda.yml +++ b/.github/workflows/unittestagenda.yml @@ -1,6 +1,6 @@ name: Unit test agenda on: - # push: + push: # paths: # - '**/unittestagenda.yml' # - 'www/board/agenda/**' diff --git a/www/board/agenda/package.json b/www/board/agenda/package.json index e40ac3bce3..ed2a2ff960 100644 --- a/www/board/agenda/package.json +++ b/www/board/agenda/package.json @@ -9,7 +9,7 @@ "jsdom": "^22.0.0", "jsdom-global": "^3.0.2", "jquery": "^3.2.1", - "vue": "^2.7.16", - "vue-server-renderer": "^2.7.16" + "vue": "^3.1.0", + "@vue/compat": "^3.1.0" } } From 252ca21250fc6e8229713ec9a9899d66590ac191 Mon Sep 17 00:00:00 2001 From: Sebb Date: Mon, 27 May 2024 17:46:13 +0100 Subject: [PATCH 8/9] productionTip no longer available --- .github/workflows/unittestagenda.yml | 2 +- www/board/agenda/spec/vue_server.rb | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/unittestagenda.yml b/.github/workflows/unittestagenda.yml index a9a0ccba00..d58c98b9da 100644 --- a/.github/workflows/unittestagenda.yml +++ b/.github/workflows/unittestagenda.yml @@ -16,7 +16,7 @@ jobs: strategy: fail-fast: false matrix: - os: [ubuntu-20.04, macos-latest] + os: [ubuntu-20.04] ruby: [2.7] # os: [ubuntu-20.04, ubuntu-22.04] # ruby: [2.7, 3.1] diff --git a/www/board/agenda/spec/vue_server.rb b/www/board/agenda/spec/vue_server.rb index 97bc2ef861..42382b444b 100644 --- a/www/board/agenda/spec/vue_server.rb +++ b/www/board/agenda/spec/vue_server.rb @@ -78,7 +78,7 @@ def self.stop process.env.VUE_ENV = 'server' Vue = require('vue') - Vue.config.productionTip = false + # Vue.config.productionTip = false # render a response, using server side rendering def Vue.renderResponse(component, response) From 4027a9329554723363613bd58da336bec3e8535b Mon Sep 17 00:00:00 2001 From: Sebb Date: Mon, 27 May 2024 17:55:57 +0100 Subject: [PATCH 9/9] Any good? --- www/board/agenda/views/vue-config.js.rb | 4 ++-- www/project/icla/views/vue-config.js.rb | 4 ++-- www/roster/views/vue-config.js.rb | 4 ++-- www/secretary/workbench/views/vue-config.js.rb | 4 ++-- 4 files changed, 8 insertions(+), 8 deletions(-) diff --git a/www/board/agenda/views/vue-config.js.rb b/www/board/agenda/views/vue-config.js.rb index b2e9ae5746..688b7b29fa 100644 --- a/www/board/agenda/views/vue-config.js.rb +++ b/www/board/agenda/views/vue-config.js.rb @@ -1,10 +1,10 @@ # Filter out "data property already declared as a prop" warnings -Vue.config.warnHandler = proc do |msg, vm, trace| +app.config.warnHandler = proc do |msg, vm, trace| return if msg =~ /^The data property "\w+" is already declared as a prop\./ console.error "[Vue warn]: " + msg + trace if defined? console end # reraise uncapturable errors asynchronously to enable easier debugging -Vue.config.errorHandler = proc do |err, vm, info| +app.config.errorHandler = proc do |err, vm, info| setTimeout(0) { raise err } end diff --git a/www/project/icla/views/vue-config.js.rb b/www/project/icla/views/vue-config.js.rb index b2e9ae5746..688b7b29fa 100644 --- a/www/project/icla/views/vue-config.js.rb +++ b/www/project/icla/views/vue-config.js.rb @@ -1,10 +1,10 @@ # Filter out "data property already declared as a prop" warnings -Vue.config.warnHandler = proc do |msg, vm, trace| +app.config.warnHandler = proc do |msg, vm, trace| return if msg =~ /^The data property "\w+" is already declared as a prop\./ console.error "[Vue warn]: " + msg + trace if defined? console end # reraise uncapturable errors asynchronously to enable easier debugging -Vue.config.errorHandler = proc do |err, vm, info| +app.config.errorHandler = proc do |err, vm, info| setTimeout(0) { raise err } end diff --git a/www/roster/views/vue-config.js.rb b/www/roster/views/vue-config.js.rb index b2e9ae5746..688b7b29fa 100644 --- a/www/roster/views/vue-config.js.rb +++ b/www/roster/views/vue-config.js.rb @@ -1,10 +1,10 @@ # Filter out "data property already declared as a prop" warnings -Vue.config.warnHandler = proc do |msg, vm, trace| +app.config.warnHandler = proc do |msg, vm, trace| return if msg =~ /^The data property "\w+" is already declared as a prop\./ console.error "[Vue warn]: " + msg + trace if defined? console end # reraise uncapturable errors asynchronously to enable easier debugging -Vue.config.errorHandler = proc do |err, vm, info| +app.config.errorHandler = proc do |err, vm, info| setTimeout(0) { raise err } end diff --git a/www/secretary/workbench/views/vue-config.js.rb b/www/secretary/workbench/views/vue-config.js.rb index b2e9ae5746..688b7b29fa 100644 --- a/www/secretary/workbench/views/vue-config.js.rb +++ b/www/secretary/workbench/views/vue-config.js.rb @@ -1,10 +1,10 @@ # Filter out "data property already declared as a prop" warnings -Vue.config.warnHandler = proc do |msg, vm, trace| +app.config.warnHandler = proc do |msg, vm, trace| return if msg =~ /^The data property "\w+" is already declared as a prop\./ console.error "[Vue warn]: " + msg + trace if defined? console end # reraise uncapturable errors asynchronously to enable easier debugging -Vue.config.errorHandler = proc do |err, vm, info| +app.config.errorHandler = proc do |err, vm, info| setTimeout(0) { raise err } end