Skip to content

Commit b4bfd63

Browse files
authored
CI clean up to fix lint task and remove Windows / MacOS from matrix (#3122)
* Remove unused travis CI config * Bump eslint and friends * Fix lint errors after eslint upgrade * Remove windows and macos from CI workflow as they are actually running linux Removes the windows and macos matrix from the CI workflow as they were never actually setting the OS. Both were running against the "ubuntu-latest" OS. Trying to actually use them would not work either as neither windows or macos is supported for service containers. A different means will be needed to test on those platforms. Until that's done, this removes those from the matrix as we were simply running the same thing 3x for the same node versions.
1 parent 2a8efbe commit b4bfd63

File tree

6 files changed

+499
-478
lines changed

6 files changed

+499
-478
lines changed

.github/workflows/ci.yml

+12-3
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,6 @@ jobs:
2121
- run: yarn lint
2222
build:
2323
needs: lint
24-
runs-on: ubuntu-latest
2524
services:
2625
postgres:
2726
image: postgres:11
@@ -35,9 +34,16 @@ jobs:
3534
options: --health-cmd pg_isready --health-interval 10s --health-timeout 5s --health-retries 5
3635
strategy:
3736
matrix:
38-
node: ['10', '12', '14', '16', '18']
39-
os: [ubuntu-latest, windows-latest, macos-latest]
37+
node:
38+
- '10'
39+
- '12'
40+
- '14'
41+
- '16'
42+
- '18'
43+
os:
44+
- ubuntu-latest
4045
name: Node.js ${{ matrix.node }} (${{ matrix.os }})
46+
runs-on: ${{ matrix.os }}
4147
env:
4248
PGUSER: postgres
4349
PGHOST: localhost
@@ -47,6 +53,9 @@ jobs:
4753
SCRAM_TEST_PGUSER: scram_test
4854
SCRAM_TEST_PGPASSWORD: test4scram
4955
steps:
56+
- name: Show OS
57+
run: |
58+
uname -a
5059
- run: |
5160
psql \
5261
-c "SET password_encryption = 'scram-sha-256'" \

.travis.yml

-100
This file was deleted.

package.json

+4-4
Original file line numberDiff line numberDiff line change
@@ -20,12 +20,12 @@
2020
"lint": "eslint '*/**/*.{js,ts,tsx}'"
2121
},
2222
"devDependencies": {
23-
"@typescript-eslint/eslint-plugin": "^4.4.0",
24-
"@typescript-eslint/parser": "^4.4.0",
25-
"eslint": "^7.11.0",
23+
"@typescript-eslint/eslint-plugin": "^6.17.0",
24+
"@typescript-eslint/parser": "^6.17.0",
25+
"eslint": "^8.56.0",
2626
"eslint-config-prettier": "^8.5.0",
2727
"eslint-plugin-node": "^11.1.0",
28-
"eslint-plugin-prettier": "^3.1.4",
28+
"eslint-plugin-prettier": "^5.1.2",
2929
"lerna": "^3.19.0",
3030
"prettier": "3.0.3",
3131
"typescript": "^4.0.3"

packages/pg-connection-string/.travis.yml

-6
This file was deleted.

packages/pg-protocol/src/messages.ts

+42-10
Original file line numberDiff line numberDiff line change
@@ -111,14 +111,21 @@ export class DatabaseError extends Error implements NoticeOrError {
111111
public file: string | undefined
112112
public line: string | undefined
113113
public routine: string | undefined
114-
constructor(message: string, public readonly length: number, public readonly name: MessageName) {
114+
constructor(
115+
message: string,
116+
public readonly length: number,
117+
public readonly name: MessageName
118+
) {
115119
super(message)
116120
}
117121
}
118122

119123
export class CopyDataMessage {
120124
public readonly name = 'copyData'
121-
constructor(public readonly length: number, public readonly chunk: Buffer) {}
125+
constructor(
126+
public readonly length: number,
127+
public readonly chunk: Buffer
128+
) {}
122129
}
123130

124131
export class CopyResponse {
@@ -148,15 +155,21 @@ export class Field {
148155
export class RowDescriptionMessage {
149156
public readonly name: MessageName = 'rowDescription'
150157
public readonly fields: Field[]
151-
constructor(public readonly length: number, public readonly fieldCount: number) {
158+
constructor(
159+
public readonly length: number,
160+
public readonly fieldCount: number
161+
) {
152162
this.fields = new Array(this.fieldCount)
153163
}
154164
}
155165

156166
export class ParameterDescriptionMessage {
157167
public readonly name: MessageName = 'parameterDescription'
158168
public readonly dataTypeIDs: number[]
159-
constructor(public readonly length: number, public readonly parameterCount: number) {
169+
constructor(
170+
public readonly length: number,
171+
public readonly parameterCount: number
172+
) {
160173
this.dataTypeIDs = new Array(this.parameterCount)
161174
}
162175
}
@@ -172,12 +185,19 @@ export class ParameterStatusMessage {
172185

173186
export class AuthenticationMD5Password implements BackendMessage {
174187
public readonly name: MessageName = 'authenticationMD5Password'
175-
constructor(public readonly length: number, public readonly salt: Buffer) {}
188+
constructor(
189+
public readonly length: number,
190+
public readonly salt: Buffer
191+
) {}
176192
}
177193

178194
export class BackendKeyDataMessage {
179195
public readonly name: MessageName = 'backendKeyData'
180-
constructor(public readonly length: number, public readonly processID: number, public readonly secretKey: number) {}
196+
constructor(
197+
public readonly length: number,
198+
public readonly processID: number,
199+
public readonly secretKey: number
200+
) {}
181201
}
182202

183203
export class NotificationResponseMessage {
@@ -192,24 +212,36 @@ export class NotificationResponseMessage {
192212

193213
export class ReadyForQueryMessage {
194214
public readonly name: MessageName = 'readyForQuery'
195-
constructor(public readonly length: number, public readonly status: string) {}
215+
constructor(
216+
public readonly length: number,
217+
public readonly status: string
218+
) {}
196219
}
197220

198221
export class CommandCompleteMessage {
199222
public readonly name: MessageName = 'commandComplete'
200-
constructor(public readonly length: number, public readonly text: string) {}
223+
constructor(
224+
public readonly length: number,
225+
public readonly text: string
226+
) {}
201227
}
202228

203229
export class DataRowMessage {
204230
public readonly fieldCount: number
205231
public readonly name: MessageName = 'dataRow'
206-
constructor(public length: number, public fields: any[]) {
232+
constructor(
233+
public length: number,
234+
public fields: any[]
235+
) {
207236
this.fieldCount = fields.length
208237
}
209238
}
210239

211240
export class NoticeMessage implements BackendMessage, NoticeOrError {
212-
constructor(public readonly length: number, public readonly message: string | undefined) {}
241+
constructor(
242+
public readonly length: number,
243+
public readonly message: string | undefined
244+
) {}
213245
public readonly name = 'notice'
214246
public severity: string | undefined
215247
public code: string | undefined

0 commit comments

Comments
 (0)