Compare commits

...

218 Commits

Author SHA1 Message Date
standardci
59107f8553 chore(release): publish new version
- @standardnotes/analytics@2.27.4
 - @standardnotes/api-gateway@1.75.9
 - @standardnotes/auth-server@1.150.1
 - @standardnotes/domain-events-infra@1.14.1
 - @standardnotes/event-store@1.12.4
 - @standardnotes/files-server@1.25.2
 - @standardnotes/home-server@1.16.16
 - @standardnotes/revisions-server@1.38.7
 - @standardnotes/scheduler-server@1.21.4
 - @standardnotes/syncing-server@1.110.4
 - @standardnotes/websockets-server@1.11.4
2023-10-03 13:32:00 +00:00
Karol Sójko
e066b6a126 fix(domain-events-infra): change segment closing 2023-10-03 14:57:59 +02:00
standardci
a0e4926135 chore(release): publish new version
- @standardnotes/analytics@2.27.3
 - @standardnotes/api-gateway@1.75.8
 - @standardnotes/auth-server@1.150.0
 - @standardnotes/domain-events-infra@1.14.0
 - @standardnotes/event-store@1.12.3
 - @standardnotes/files-server@1.25.1
 - @standardnotes/home-server@1.16.15
 - @standardnotes/revisions-server@1.38.6
 - @standardnotes/scheduler-server@1.21.3
 - @standardnotes/syncing-server@1.110.3
 - @standardnotes/websockets-server@1.11.3
2023-10-03 06:53:13 +00:00
Karol Sójko
b1b244a2cf feat: add xray segment tracing on auth-worker 2023-10-03 08:21:57 +02:00
standardci
b4a38d9dcc chore(release): publish new version
- @standardnotes/auth-server@1.149.1
 - @standardnotes/home-server@1.16.14
2023-10-02 15:45:45 +00:00
Karol Sójko
71e2a4187e fix(auth): enable xray only for server 2023-10-02 16:53:03 +02:00
standardci
c94f9c1a60 chore(release): publish new version
- @standardnotes/auth-server@1.149.0
 - @standardnotes/home-server@1.16.13
 - @standardnotes/revisions-server@1.38.5
 - @standardnotes/syncing-server@1.110.2
2023-10-02 13:56:17 +00:00
Karol Sójko
b9907924be chore: fix run name for e2e test suite to include suite 2023-10-02 14:37:10 +02:00
Karol Sójko
d4c188c096 feat: divide suites furthermore 2023-10-02 14:19:12 +02:00
Karol Sójko
2ccaf490df feat: divide test suites on a higher level 2023-10-02 13:47:32 +02:00
Karol Sójko
cd893b41d7 fix: temproarily disable transitions to empty overpopulated queues 2023-10-02 13:05:54 +02:00
Karol Sójko
3838358081 fix(auth): add aws xray ecs and ec2 plugins 2023-10-02 12:56:06 +02:00
Karol Sójko
1a388f00c3 feat(auth): introduce AWS X-Ray SDK (#859)
* feat(auth): configure aws-xray-sdk for express

* configured aws sdk clients

* configure setting user metadata on segment

* fix binding

* fix binding order
2023-10-02 12:52:49 +02:00
Karol Sójko
bd71422fab fix(auth): prevent from loop disabling of email settings (#858) 2023-10-02 10:56:35 +02:00
standardci
3e1697f47f chore(release): publish new version
- @standardnotes/home-server@1.16.12
 - @standardnotes/revisions-server@1.38.4
 - @standardnotes/syncing-server@1.110.1
2023-09-29 13:13:19 +00:00
Karol Sójko
032cde7723 fix: keep transition in-progress status alive 2023-09-29 14:08:31 +02:00
standardci
34b956b482 chore(release): publish new version
- @standardnotes/auth-server@1.148.2
 - @standardnotes/home-server@1.16.11
 - @standardnotes/revisions-server@1.38.3
 - @standardnotes/syncing-server@1.110.0
2023-09-29 10:23:26 +00:00
Karol Sójko
681e0378ae fix(auth): increase ttl for in progress duration of transitions 2023-09-29 11:05:54 +02:00
Karol Sójko
609e85f926 feat(syncing-server): allow surviving only upon account deletion (#857) 2023-09-29 10:51:26 +02:00
Karol Sójko
e4ca310707 fix: add paging memory to integrity check 2023-09-29 10:47:50 +02:00
standardci
d606493356 chore(release): publish new version
- @standardnotes/auth-server@1.148.1
 - @standardnotes/home-server@1.16.10
2023-09-29 08:14:08 +00:00
Karol Sójko
5ef6c5c14a fix(auth): disable transitions retriggering if they are in progress 2023-09-28 14:40:37 +02:00
standardci
0188f290f9 chore(release): publish new version
- @standardnotes/analytics@2.27.2
 - @standardnotes/api-gateway@1.75.7
 - @standardnotes/auth-server@1.148.0
 - @standardnotes/domain-events-infra@1.13.1
 - @standardnotes/domain-events@2.131.1
 - @standardnotes/event-store@1.12.2
 - @standardnotes/files-server@1.25.0
 - @standardnotes/home-server@1.16.9
 - @standardnotes/revisions-server@1.38.2
 - @standardnotes/scheduler-server@1.21.2
 - @standardnotes/security@1.15.0
 - @standardnotes/syncing-server@1.109.2
 - @standardnotes/time@1.17.0
 - @standardnotes/websockets-server@1.11.2
2023-09-28 11:39:49 +00:00
Karol Sójko
676cf36f8d feat: block file operations during transition (#856)
* feat: block file operations during transition

* fix: tracing sessions

* fix fs file removal

* fix: checking if directory exists before listing files

* fix: removing shared vault user on auth side
2023-09-28 13:10:58 +02:00
Karol Sójko
f8aef6c8ef feat: archiving failed run logs 2023-09-27 14:20:34 +02:00
Karol Sójko
5bf8cf49c1 feat: parametrize test suite to be run 2023-09-27 12:14:33 +02:00
standardci
51cd0a4dad chore(release): publish new version
- @standardnotes/analytics@2.27.1
 - @standardnotes/api-gateway@1.75.6
 - @standardnotes/auth-server@1.147.1
 - @standardnotes/domain-core@1.34.1
 - @standardnotes/event-store@1.12.1
 - @standardnotes/files-server@1.24.1
 - @standardnotes/home-server@1.16.8
 - @standardnotes/revisions-server@1.38.1
 - @standardnotes/scheduler-server@1.21.1
 - @standardnotes/settings@1.21.41
 - @standardnotes/syncing-server@1.109.1
 - @standardnotes/websockets-server@1.11.1
2023-09-27 09:45:40 +00:00
Karol Sójko
1d06ffe9d5 fix: removing items in a vault and notifying about designated survivor (#855)
* fix: removing items in a vault and notifying about designated survivor

* fix deleting shared vault items
2023-09-27 11:10:41 +02:00
standardci
dbf532f55e chore(release): publish new version
- @standardnotes/analytics@2.27.0
 - @standardnotes/api-gateway@1.75.5
 - @standardnotes/auth-server@1.147.0
 - @standardnotes/common@1.51.0
 - @standardnotes/domain-core@1.34.0
 - @standardnotes/domain-events-infra@1.13.0
 - @standardnotes/domain-events@2.131.0
 - @standardnotes/event-store@1.12.0
 - @standardnotes/files-server@1.24.0
 - @standardnotes/home-server@1.16.7
 - @standardnotes/predicates@1.7.0
 - @standardnotes/revisions-server@1.38.0
 - @standardnotes/scheduler-server@1.21.0
 - @standardnotes/security@1.14.0
 - @standardnotes/settings@1.21.40
 - @standardnotes/syncing-server@1.109.0
 - @standardnotes/time@1.16.0
 - @standardnotes/websockets-server@1.11.0
2023-09-26 10:05:20 +00:00
Karol Sójko
ca6dbc0053 feat: refactor handling revision creation from dump (#854)
* feat: refactor handling revision creation from dump

* fix: dump repository handling
2023-09-26 11:47:41 +02:00
standardci
1bb5980b45 chore(release): publish new version
- @standardnotes/analytics@2.26.24
 - @standardnotes/api-gateway@1.75.4
 - @standardnotes/auth-server@1.146.4
 - @standardnotes/domain-core@1.33.2
 - @standardnotes/event-store@1.11.52
 - @standardnotes/files-server@1.23.2
 - @standardnotes/home-server@1.16.6
 - @standardnotes/revisions-server@1.37.3
 - @standardnotes/scheduler-server@1.20.56
 - @standardnotes/settings@1.21.39
 - @standardnotes/syncing-server@1.108.2
 - @standardnotes/websockets-server@1.10.53
2023-09-25 16:42:43 +00:00
Karol Sójko
a02a28774b fix(domain-core): notification paylod to string casting 2023-09-25 18:24:38 +02:00
standardci
2d9b3578b6 chore(release): publish new version
- @standardnotes/analytics@2.26.23
 - @standardnotes/api-gateway@1.75.3
 - @standardnotes/auth-server@1.146.3
 - @standardnotes/domain-core@1.33.1
 - @standardnotes/event-store@1.11.51
 - @standardnotes/files-server@1.23.1
 - @standardnotes/home-server@1.16.5
 - @standardnotes/revisions-server@1.37.2
 - @standardnotes/scheduler-server@1.20.55
 - @standardnotes/settings@1.21.38
 - @standardnotes/syncing-server@1.108.1
 - @standardnotes/websockets-server@1.10.52
2023-09-25 15:28:21 +00:00
Karol Sójko
3d5e747590 fix(syncing-server): another spec 2023-09-25 17:10:30 +02:00
Karol Sójko
94467747ac fix(syncing-server): specs 2023-09-25 15:52:35 +02:00
Karol Sójko
cebab59a02 fix: refactor the structure of notifications (#853) 2023-09-25 15:40:51 +02:00
standardci
09e1a892ca chore(release): publish new version
- @standardnotes/analytics@2.26.22
 - @standardnotes/api-gateway@1.75.2
 - @standardnotes/auth-server@1.146.2
 - @standardnotes/domain-events-infra@1.12.34
 - @standardnotes/domain-events@2.130.0
 - @standardnotes/event-store@1.11.50
 - @standardnotes/files-server@1.23.0
 - @standardnotes/home-server@1.16.4
 - @standardnotes/revisions-server@1.37.1
 - @standardnotes/scheduler-server@1.20.54
 - @standardnotes/syncing-server@1.108.0
 - @standardnotes/websockets-server@1.10.51
2023-09-25 11:53:52 +00:00
Karol Sójko
7b1eec21e5 feat: remove shared vault files upon shared vault removal (#852)
* feat: remove shared vault files upon shared vault removal

* fix: link files queue with syncing-server-js topic
2023-09-25 12:56:31 +02:00
standardci
a58262d584 chore(release): publish new version
- @standardnotes/home-server@1.16.3
 - @standardnotes/syncing-server@1.107.0
2023-09-25 09:43:23 +00:00
Karol Sójko
a8f03e157b feat(syncing-server): transfer shared vault items (#851) 2023-09-25 11:09:33 +02:00
standardci
a401962bcd chore(release): publish new version
- @standardnotes/home-server@1.16.2
 - @standardnotes/revisions-server@1.37.0
 - @standardnotes/syncing-server@1.106.0
2023-09-25 08:15:14 +00:00
Karol Sójko
9759814f63 feat: add storing paging progress in redis 2023-09-25 09:40:49 +02:00
standardci
c7cf53722c chore(release): publish new version
- @standardnotes/analytics@2.26.21
 - @standardnotes/api-gateway@1.75.1
 - @standardnotes/auth-server@1.146.1
 - @standardnotes/domain-events-infra@1.12.33
 - @standardnotes/domain-events@2.129.1
 - @standardnotes/event-store@1.11.49
 - @standardnotes/files-server@1.22.28
 - @standardnotes/home-server@1.16.1
 - @standardnotes/revisions-server@1.36.7
 - @standardnotes/scheduler-server@1.20.53
 - @standardnotes/syncing-server@1.105.1
 - @standardnotes/websockets-server@1.10.50
2023-09-25 07:30:06 +00:00
Karol Sójko
8cb33dc906 fix: add paging progress log 2023-09-25 08:51:33 +02:00
Karol Sójko
1d73e4f072 fix: remember paging progress on transitioning 2023-09-25 08:50:59 +02:00
standardci
0a0f82ea3d chore(release): publish new version
- @standardnotes/auth-server@1.146.0
 - @standardnotes/home-server@1.16.0
 - @standardnotes/revisions-server@1.36.6
 - @standardnotes/syncing-server@1.105.0
2023-09-22 12:43:13 +00:00
Karol Sójko
f9b1f40ddf fix(auth): register specs 2023-09-22 14:23:21 +02:00
Karol Sójko
0562b0a621 fix: add more logs to transition process 2023-09-22 14:19:14 +02:00
Karol Sójko
15ed1fd789 fix: remove excessive logs 2023-09-22 14:16:51 +02:00
Karol Sójko
5001496c7b feat: remove transition mode from code 2023-09-22 14:13:32 +02:00
Karol Sójko
0a1080ce2a feat(syncing-server): transfer shared vault ownership to designated survivor upon account deletion (#845) 2023-09-22 14:11:01 +02:00
standardci
4802d7e876 chore(release): publish new version
- @standardnotes/home-server@1.15.80
 - @standardnotes/syncing-server@1.104.0
2023-09-22 11:33:45 +00:00
Karol Sójko
bcd95cdbe9 feat(syncing-server): add designated survivors in fetching shared vaults response (#844) 2023-09-22 13:15:11 +02:00
standardci
d50c4440c2 chore(release): publish new version
- @standardnotes/home-server@1.15.79
 - @standardnotes/revisions-server@1.36.5
 - @standardnotes/syncing-server@1.103.1
2023-09-22 09:57:54 +00:00
Karol Sójko
921c30f641 fix: integrity check during transition 2023-09-22 11:27:54 +02:00
Karol Sójko
22540ee834 fix: processing migration optimization 2023-09-22 11:17:03 +02:00
Karol Sójko
4f4443a882 fix: disable cleaning secondary database on transition 2023-09-22 11:17:02 +02:00
standardci
80dbacf933 chore(release): publish new version
- @standardnotes/auth-server@1.145.0
 - @standardnotes/home-server@1.15.78
 - @standardnotes/syncing-server@1.103.0
2023-09-22 09:07:07 +00:00
Karol Sójko
dc77ff3e45 feat: remove user from all shared vaults upon account deletion (#843) 2023-09-22 10:49:53 +02:00
standardci
6515dcf487 chore(release): publish new version
- @standardnotes/home-server@1.15.77
 - @standardnotes/syncing-server@1.102.2
2023-09-22 07:54:08 +00:00
Karol Sójko
d0fd6b98df fix(syncing-server): error message 2023-09-22 09:35:37 +02:00
standardci
345efacb44 chore(release): publish new version
- @standardnotes/home-server@1.15.76
 - @standardnotes/revisions-server@1.36.4
2023-09-21 13:20:19 +00:00
Karol Sójko
d0dba1b66d fix(revisions): add log info about skipping already existing revision 2023-09-21 15:00:05 +02:00
standardci
da119af8b2 chore(release): publish new version
- @standardnotes/home-server@1.15.75
 - @standardnotes/syncing-server@1.102.1
2023-09-21 12:46:35 +00:00
Karol Sójko
a5da42bddd fix(syncing-server): add missing binding 2023-09-21 14:28:36 +02:00
standardci
12767237d2 chore(release): publish new version
- @standardnotes/analytics@2.26.20
 - @standardnotes/api-gateway@1.75.0
 - @standardnotes/auth-server@1.144.0
 - @standardnotes/domain-core@1.33.0
 - @standardnotes/domain-events-infra@1.12.32
 - @standardnotes/domain-events@2.129.0
 - @standardnotes/event-store@1.11.48
 - @standardnotes/files-server@1.22.27
 - @standardnotes/home-server@1.15.74
 - @standardnotes/revisions-server@1.36.3
 - @standardnotes/scheduler-server@1.20.52
 - @standardnotes/settings@1.21.37
 - @standardnotes/syncing-server@1.102.0
 - @standardnotes/websockets-server@1.10.49
2023-09-21 11:12:44 +00:00
Karol Sójko
230c96dcf1 feat: add designating a survivor in shared vault (#841)
* feat: add designating a survivor in shared vault

* add designated survivor property to http representation

* fix: specs

* fix: more specs

* fix: another spec fix

* fix: yet another spec fix
2023-09-21 12:26:08 +02:00
standardci
e2696fcd1a chore(release): publish new version
- @standardnotes/home-server@1.15.73
 - @standardnotes/revisions-server@1.36.2
2023-09-21 10:13:33 +00:00
Karol Sójko
a621cf1e3b fix(revisions): rename revisions table to all users stuck mid-migration process - fixes #836 (#842) 2023-09-21 11:55:55 +02:00
standardci
db35b9fcab chore(release): publish new version
- @standardnotes/home-server@1.15.72
 - @standardnotes/revisions-server@1.36.1
 - @standardnotes/syncing-server@1.101.1
2023-09-21 07:34:07 +00:00
Karol Sójko
880db1038a fix: secondary database catch up time 2023-09-21 09:17:00 +02:00
standardci
414b090efb chore(release): publish new version
- @standardnotes/analytics@2.26.19
 - @standardnotes/api-gateway@1.74.17
 - @standardnotes/auth-server@1.143.9
 - @standardnotes/domain-core@1.32.0
 - @standardnotes/domain-events-infra@1.12.31
 - @standardnotes/domain-events@2.128.0
 - @standardnotes/event-store@1.11.47
 - @standardnotes/files-server@1.22.26
 - @standardnotes/home-server@1.15.71
 - @standardnotes/revisions-server@1.36.0
 - @standardnotes/scheduler-server@1.20.51
 - @standardnotes/settings@1.21.36
 - @standardnotes/syncing-server@1.101.0
 - @standardnotes/websockets-server@1.10.48
2023-09-20 14:13:03 +00:00
Karol Sójko
41e2136bc0 feat(syncing-server): distinct notifications upon user removal from shared vault (#840) 2023-09-20 15:31:57 +02:00
Karol Sójko
378ecedfcc feat: add unassigning items and revisions upon shared vault removal (#839)
* feat: add unassigning items and revisions upon shared vault removal

* fix(syncing-server): update event payload creation
2023-09-20 15:03:17 +02:00
standardci
06d4200909 chore(release): publish new version
- @standardnotes/home-server@1.15.70
 - @standardnotes/syncing-server@1.100.0
2023-09-20 11:17:47 +00:00
Karol Sójko
22a8cc90f1 feat(syncing-server): remove owned shared vaults upon account deletion (#838) 2023-09-20 12:59:03 +02:00
standardci
5cf84e31b0 chore(release): publish new version
- @standardnotes/analytics@2.26.18
 - @standardnotes/api-gateway@1.74.16
 - @standardnotes/auth-server@1.143.8
 - @standardnotes/domain-core@1.31.0
 - @standardnotes/event-store@1.11.46
 - @standardnotes/files-server@1.22.25
 - @standardnotes/home-server@1.15.69
 - @standardnotes/revisions-server@1.35.8
 - @standardnotes/scheduler-server@1.20.50
 - @standardnotes/settings@1.21.35
 - @standardnotes/syncing-server@1.99.0
 - @standardnotes/websockets-server@1.10.47
2023-09-20 09:04:29 +00:00
Karol Sójko
31e7aaf253 feat(syncing-server): add notification for user upon declined shared vault invitation (#837) 2023-09-20 10:47:19 +02:00
standardci
8ec3d37c18 chore(release): publish new version
- @standardnotes/analytics@2.26.17
 - @standardnotes/api-gateway@1.74.15
 - @standardnotes/auth-server@1.143.7
 - @standardnotes/domain-core@1.30.1
 - @standardnotes/event-store@1.11.45
 - @standardnotes/files-server@1.22.24
 - @standardnotes/home-server@1.15.68
 - @standardnotes/revisions-server@1.35.7
 - @standardnotes/scheduler-server@1.20.49
 - @standardnotes/settings@1.21.34
 - @standardnotes/syncing-server@1.98.6
 - @standardnotes/websockets-server@1.10.46
2023-09-19 13:25:30 +00:00
Karol Sójko
857c6af946 fix: skip removing already existing content in secondary to pick up where the transition left of 2023-09-19 14:55:40 +02:00
Karol Sójko
de081fe786 fix(domain-core): allow any version and variant of the UUID format 2023-09-19 14:42:19 +02:00
standardci
0aeeb2d1cf chore(release): publish new version
- @standardnotes/home-server@1.15.67
 - @standardnotes/revisions-server@1.35.6
 - @standardnotes/syncing-server@1.98.5
2023-09-19 11:23:30 +00:00
Karol Sójko
e589029722 fix: logs verbosity during transitions 2023-09-19 13:04:43 +02:00
Karol Sójko
b265a39b63 fix: increase timeout for secondary database to catch up for indexes to be rebuilt 2023-09-19 13:04:43 +02:00
standardci
ed5cfd86db chore(release): publish new version
- @standardnotes/home-server@1.15.66
 - @standardnotes/revisions-server@1.35.5
 - @standardnotes/syncing-server@1.98.4
2023-09-19 11:04:14 +00:00
Karol Sójko
a1a3e9f586 fix: add checking for secondary items logs 2023-09-19 12:45:08 +02:00
Karol Sójko
a40b17b141 fix: logs for removing already existing content and paging through diff of the content 2023-09-19 12:43:09 +02:00
standardci
18181ed9df chore(release): publish new version
- @standardnotes/home-server@1.15.65
 - @standardnotes/revisions-server@1.35.4
 - @standardnotes/syncing-server@1.98.3
2023-09-19 08:46:37 +00:00
Karol Sójko
0ae028db73 fix: logs formatting during transition for better readability 2023-09-19 10:27:21 +02:00
standardci
79971be672 chore(release): publish new version
- @standardnotes/home-server@1.15.64
 - @standardnotes/revisions-server@1.35.3
 - @standardnotes/syncing-server@1.98.2
2023-09-19 08:18:11 +00:00
Karol Sójko
e4fcd738c3 fix(syncing-server): paging through already existing items 2023-09-19 09:59:03 +02:00
standardci
6827e5e218 chore(release): publish new version
- @standardnotes/auth-server@1.143.6
 - @standardnotes/home-server@1.15.63
2023-09-19 06:54:31 +00:00
Karol Sójko
b91cd7e232 fix(auth): bump version 2023-09-19 08:36:33 +02:00
Karol Sójko
735d89cdaa fix: building docker image 2023-09-19 08:36:13 +02:00
standardci
e8db412bc2 chore(release): publish new version
- @standardnotes/auth-server@1.143.4
 - @standardnotes/home-server@1.15.62
2023-09-19 06:20:59 +00:00
Karol Sójko
bf855bb26e fix(auth): add debug logs to transition 2023-09-19 08:02:27 +02:00
Karol Sójko
41cd377145 fix: missing workspace name input param 2023-09-18 14:34:26 +02:00
Karol Sójko
d798864caf fix: strip workflows of bundling 2023-09-18 14:18:17 +02:00
standardci
cef1998f0e chore(release): publish new version
- @standardnotes/analytics@2.26.16
 - @standardnotes/api-gateway@1.74.14
 - @standardnotes/auth-server@1.143.3
 - @standardnotes/event-store@1.11.44
 - @standardnotes/files-server@1.22.23
 - @standardnotes/home-server@1.15.61
 - @standardnotes/revisions-server@1.35.2
 - @standardnotes/scheduler-server@1.20.48
 - @standardnotes/syncing-server@1.98.1
 - @standardnotes/websockets-server@1.10.45
2023-09-18 11:49:29 +00:00
Karol Sójko
c2cbf44594 chore: upgrade node version (#835)
* chore: upgrade node version

* chore: upgrade yarn

* fix: yarn setup:

* remove bundle plugin

* fix bundling

* fix env path for files
2023-09-18 13:32:49 +02:00
standardci
de2e167582 chore(release): publish new version
- @standardnotes/analytics@2.26.15
 - @standardnotes/api-gateway@1.74.13
 - @standardnotes/auth-server@1.143.2
 - @standardnotes/domain-core@1.30.0
 - @standardnotes/event-store@1.11.43
 - @standardnotes/files-server@1.22.22
 - @standardnotes/home-server@1.15.60
 - @standardnotes/revisions-server@1.35.1
 - @standardnotes/scheduler-server@1.20.47
 - @standardnotes/settings@1.21.33
 - @standardnotes/syncing-server@1.98.0
 - @standardnotes/websockets-server@1.10.44
2023-09-18 08:44:10 +00:00
Karol Sójko
547a79e231 feat: add publishing notifications for users when a user is added to vault (#834) 2023-09-18 10:27:24 +02:00
standardci
5a3afb3b17 chore(release): publish new version
- @standardnotes/auth-server@1.143.1
 - @standardnotes/home-server@1.15.59
2023-09-15 15:42:29 +00:00
Karol Sójko
66ef4be656 fix(auth): retrieving transition status 2023-09-15 17:23:49 +02:00
standardci
c5d0d63ddd chore(release): publish new version
- @standardnotes/analytics@2.26.14
 - @standardnotes/api-gateway@1.74.12
 - @standardnotes/auth-server@1.143.0
 - @standardnotes/domain-core@1.29.0
 - @standardnotes/domain-events-infra@1.12.30
 - @standardnotes/domain-events@2.127.0
 - @standardnotes/event-store@1.11.42
 - @standardnotes/files-server@1.22.21
 - @standardnotes/home-server@1.15.58
 - @standardnotes/revisions-server@1.35.0
 - @standardnotes/scheduler-server@1.20.46
 - @standardnotes/settings@1.21.32
 - @standardnotes/syncing-server@1.97.0
 - @standardnotes/websockets-server@1.10.43
2023-09-15 15:13:07 +00:00
Karol Sójko
36f07c691a feat: refactor transition to minimize status changes (#828) 2023-09-15 16:56:08 +02:00
standardci
ac0390e7c3 chore(release): publish new version
- @standardnotes/auth-server@1.142.1
 - @standardnotes/home-server@1.15.57
 - @standardnotes/revisions-server@1.34.1
 - @standardnotes/syncing-server@1.96.1
2023-09-15 11:15:32 +00:00
Karol Sójko
0477507a6a fix: add debug logs for updating transition status on auth 2023-09-15 12:57:43 +02:00
Karol Sójko
3e7856c895 fix: add debug logs for transition status updates 2023-09-15 12:55:04 +02:00
standardci
6778a80f21 chore(release): publish new version
- @standardnotes/analytics@2.26.13
 - @standardnotes/api-gateway@1.74.11
 - @standardnotes/auth-server@1.142.0
 - @standardnotes/domain-events-infra@1.12.29
 - @standardnotes/domain-events@2.126.0
 - @standardnotes/event-store@1.11.41
 - @standardnotes/files-server@1.22.20
 - @standardnotes/home-server@1.15.56
 - @standardnotes/revisions-server@1.34.0
 - @standardnotes/scheduler-server@1.20.45
 - @standardnotes/syncing-server@1.96.0
 - @standardnotes/websockets-server@1.10.42
2023-09-15 09:49:09 +00:00
Karol Sójko
d4d49454a6 feat: add skipping verified transitions (#827)
* fix(syncing-server): remove transitioning individual users

* feat: add skipping verified transitions

* fix(auth): remove unused use case
2023-09-15 11:31:52 +02:00
standardci
04b52e6773 chore(release): publish new version
- @standardnotes/auth-server@1.141.14
 - @standardnotes/home-server@1.15.55
 - @standardnotes/syncing-server@1.95.19
2023-09-15 08:53:53 +00:00
Karol Sójko
2a1859e4be fix(auth): remove extensive logs from updating transitions 2023-09-15 10:35:50 +02:00
Karol Sójko
dd9a9c68cb fix(auth): upgrade simplewebauthn dependency (#826) 2023-09-15 10:35:14 +02:00
Karol Sójko
9147ff5d49 fix(syncing-server): remove unused index in mongodb 2023-09-14 14:18:20 +02:00
standardci
503b84531b chore(release): publish new version
- @standardnotes/auth-server@1.141.13
 - @standardnotes/home-server@1.15.54
 - @standardnotes/revisions-server@1.33.21
 - @standardnotes/syncing-server@1.95.18
2023-09-14 10:16:54 +00:00
Karol Sójko
fe8ca828fb fix(auth): set ttl for started and not picked up transitions to 10h 2023-09-14 11:57:21 +02:00
Karol Sójko
03a4a3f2ab fix: skip already updated items and revisions in integrity check (#825) 2023-09-14 11:54:30 +02:00
Karol Sójko
3a8607d146 fix(syncing-server): updating with missing creation date (#824) 2023-09-14 11:45:24 +02:00
standardci
93b6e65554 chore(release): publish new version
- @standardnotes/auth-server@1.141.12
 - @standardnotes/home-server@1.15.53
2023-09-13 10:22:30 +00:00
Karol Sójko
5984e4c3e7 fix(auth): remove re-triggering revisions transition 2023-09-13 11:51:34 +02:00
standardci
b4257c10ea chore(release): publish new version
- @standardnotes/auth-server@1.141.11
 - @standardnotes/home-server@1.15.52
2023-09-13 09:41:28 +00:00
Karol Sójko
c164bde847 fix(auth): passing transition timestamp 2023-09-13 11:03:32 +02:00
standardci
883df939dd chore(release): publish new version
- @standardnotes/api-gateway@1.74.10
 - @standardnotes/auth-server@1.141.10
 - @standardnotes/home-server@1.15.51
 - @standardnotes/revisions-server@1.33.20
 - @standardnotes/syncing-server@1.95.17
2023-09-13 08:40:17 +00:00
Karol Sójko
c7807d0f9e fix: adjust transition timestamps to be universal 2023-09-13 10:25:02 +02:00
standardci
fc90343aaa chore(release): publish new version
- @standardnotes/home-server@1.15.50
 - @standardnotes/revisions-server@1.33.19
 - @standardnotes/syncing-server@1.95.16
2023-09-13 08:17:45 +00:00
Karol Sójko
fbcb45c3a2 fix: include handling updated items in revisions in secondary 2023-09-13 10:00:02 +02:00
standardci
179d8eaaa1 chore(release): publish new version
- @standardnotes/analytics@2.26.12
 - @standardnotes/api-gateway@1.74.9
 - @standardnotes/auth-server@1.141.9
 - @standardnotes/domain-events-infra@1.12.28
 - @standardnotes/domain-events@2.125.4
 - @standardnotes/event-store@1.11.40
 - @standardnotes/files-server@1.22.19
 - @standardnotes/home-server@1.15.49
 - @standardnotes/revisions-server@1.33.18
 - @standardnotes/scheduler-server@1.20.44
 - @standardnotes/syncing-server@1.95.15
 - @standardnotes/websockets-server@1.10.41
2023-09-13 07:47:36 +00:00
Karol Sójko
38685c1861 fix: display transition progress in logs 2023-09-13 09:31:07 +02:00
standardci
cdf42fbe2d chore(release): publish new version
- @standardnotes/home-server@1.15.48
 - @standardnotes/revisions-server@1.33.17
 - @standardnotes/syncing-server@1.95.14
2023-09-13 06:39:14 +00:00
Karol Sójko
9be4c002b7 fix: setting status for already migrated users 2023-09-13 08:21:21 +02:00
standardci
a16c5307a0 chore(release): publish new version
- @standardnotes/home-server@1.15.47
 - @standardnotes/revisions-server@1.33.16
 - @standardnotes/syncing-server@1.95.13
2023-09-13 04:50:15 +00:00
Karol Sójko
d5536f5430 fix(syncing-server): case insensitive integrity check 2023-09-13 06:33:31 +02:00
Karol Sójko
b1d88b15be fix: cleanup only for 0 new items 2023-09-12 22:51:39 +02:00
Karol Sójko
ff78285e43 fix(syncing-server): add catch up timeout for secondary db 2023-09-12 22:24:48 +02:00
standardci
1a26221385 chore(release): publish new version
- @standardnotes/auth-server@1.141.8
 - @standardnotes/home-server@1.15.46
 - @standardnotes/revisions-server@1.33.15
 - @standardnotes/syncing-server@1.95.12
2023-09-12 20:05:02 +00:00
Karol Sójko
54113abe2a fix: imports 2023-09-12 21:31:58 +02:00
Karol Sójko
afe385aed4 fix(auth): remove the transition role constraint 2023-09-12 21:28:48 +02:00
Karol Sójko
f055e52e06 fix(auth): add transition role only if the items transition has completed 2023-09-12 21:26:40 +02:00
Karol Sójko
fab5d18064 fix: sync between primary and secondary database with diff 2023-09-12 21:00:01 +02:00
standardci
a1e654a0d0 chore(release): publish new version
- @standardnotes/home-server@1.15.45
 - @standardnotes/revisions-server@1.33.14
2023-09-12 16:21:14 +00:00
Karol Sójko
aa835268ea fix(revisions): handle transitions with already existing data in secondary 2023-09-12 17:42:11 +02:00
standardci
74b4312928 chore(release): publish new version
- @standardnotes/home-server@1.15.44
 - @standardnotes/syncing-server@1.95.11
2023-09-12 15:17:12 +00:00
Karol Sójko
e91a832152 fix(syncing-server): binding 2023-09-12 16:41:39 +02:00
standardci
4f95bbee3f chore(release): publish new version
- @standardnotes/analytics@2.26.11
 - @standardnotes/api-gateway@1.74.8
 - @standardnotes/auth-server@1.141.7
 - @standardnotes/domain-events-infra@1.12.27
 - @standardnotes/domain-events@2.125.3
 - @standardnotes/event-store@1.11.39
 - @standardnotes/files-server@1.22.18
 - @standardnotes/home-server@1.15.43
 - @standardnotes/revisions-server@1.33.13
 - @standardnotes/scheduler-server@1.20.43
 - @standardnotes/syncing-server@1.95.10
 - @standardnotes/websockets-server@1.10.40
2023-09-12 13:37:37 +00:00
Karol Sójko
b9c9f74d0c fix(syncing-server): log syncing errors 2023-09-12 15:03:11 +02:00
Karol Sójko
e535cd504c fix: retry failed revision transitions 2023-09-12 14:45:17 +02:00
standardci
db0360860a chore(release): publish new version
- @standardnotes/home-server@1.15.42
 - @standardnotes/revisions-server@1.33.12
 - @standardnotes/syncing-server@1.95.9
2023-09-12 10:57:29 +00:00
Karol Sójko
aa2b5f3b74 chore: add logs for failed item dumps 2023-09-12 12:13:55 +02:00
standardci
6241661e27 chore(release): publish new version
- @standardnotes/home-server@1.15.41
 - @standardnotes/syncing-server@1.95.8
2023-09-12 09:38:19 +00:00
Karol Sójko
25047bf46d fix(syncing-server): allow fetching shared vault users for members (#821) 2023-09-12 11:00:55 +02:00
standardci
a1820ed212 chore(release): publish new version
- @standardnotes/analytics@2.26.10
 - @standardnotes/api-gateway@1.74.7
 - @standardnotes/auth-server@1.141.6
 - @standardnotes/domain-core@1.28.1
 - @standardnotes/event-store@1.11.38
 - @standardnotes/files-server@1.22.17
 - @standardnotes/home-server@1.15.40
 - @standardnotes/revisions-server@1.33.11
 - @standardnotes/scheduler-server@1.20.42
 - @standardnotes/settings@1.21.31
 - @standardnotes/syncing-server@1.95.7
 - @standardnotes/websockets-server@1.10.39
2023-09-12 08:55:11 +00:00
Karol Sójko
0a1d1624e8 fix: comparing uuids 2023-09-12 10:21:42 +02:00
standardci
7367de6832 chore(release): publish new version
- @standardnotes/analytics@2.26.9
 - @standardnotes/api-gateway@1.74.6
 - @standardnotes/auth-server@1.141.5
 - @standardnotes/domain-events-infra@1.12.26
 - @standardnotes/domain-events@2.125.2
 - @standardnotes/event-store@1.11.37
 - @standardnotes/files-server@1.22.16
 - @standardnotes/home-server@1.15.39
 - @standardnotes/revisions-server@1.33.10
 - @standardnotes/scheduler-server@1.20.41
 - @standardnotes/syncing-server@1.95.6
 - @standardnotes/websockets-server@1.10.38
2023-09-12 07:40:20 +00:00
Karol Sójko
f0abfe89fc fix: domain event values 2023-09-12 08:59:28 +02:00
standardci
d1244d165a chore(release): publish new version
- @standardnotes/analytics@2.26.8
 - @standardnotes/api-gateway@1.74.5
 - @standardnotes/auth-server@1.141.4
 - @standardnotes/domain-events-infra@1.12.25
 - @standardnotes/domain-events@2.125.1
 - @standardnotes/event-store@1.11.36
 - @standardnotes/files-server@1.22.15
 - @standardnotes/home-server@1.15.38
 - @standardnotes/revisions-server@1.33.9
 - @standardnotes/scheduler-server@1.20.40
 - @standardnotes/security@1.13.1
 - @standardnotes/syncing-server@1.95.5
 - @standardnotes/websockets-server@1.10.37
2023-09-12 06:58:11 +00:00
Karol Sójko
106d8f9192 fix: adjust transitions to not create revisions during ongoing revisions transition 2023-09-12 08:22:50 +02:00
standardci
1d86ba8fcb chore(release): publish new version
- @standardnotes/auth-server@1.141.3
 - @standardnotes/home-server@1.15.37
 - @standardnotes/revisions-server@1.33.8
 - @standardnotes/syncing-server@1.95.4
2023-09-12 05:31:57 +00:00
Karol Sójko
f20a947f8a fix: transition adjustments 2023-09-12 06:52:34 +02:00
standardci
19b9de05ae chore(release): publish new version
- @standardnotes/home-server@1.15.36
 - @standardnotes/syncing-server@1.95.3
2023-09-11 19:06:39 +00:00
Karol Sójko
1d751c0fbe fix: debug sync block 2023-09-11 19:23:09 +02:00
standardci
fa2564e164 chore(release): publish new version
- @standardnotes/auth-server@1.141.2
 - @standardnotes/home-server@1.15.35
 - @standardnotes/revisions-server@1.33.7
 - @standardnotes/syncing-server@1.95.2
2023-09-11 15:18:55 +00:00
Karol Sójko
330bff0124 fix(auth): remove transitioning upon sign out (#819) 2023-09-11 16:42:11 +02:00
standardci
ca57c8e7b5 chore(release): publish new version
- @standardnotes/auth-server@1.141.1
 - @standardnotes/home-server@1.15.34
 - @standardnotes/revisions-server@1.33.6
 - @standardnotes/syncing-server@1.95.1
2023-09-11 13:00:46 +00:00
Karol Sójko
a82b9a0c8a fix: disable running migrations in worker mode of a given service 2023-09-11 14:27:52 +02:00
standardci
ea7e9d73c4 chore(release): publish new version
- @standardnotes/api-gateway@1.74.4
 - @standardnotes/auth-server@1.141.0
 - @standardnotes/home-server@1.15.33
 - @standardnotes/revisions-server@1.33.5
2023-09-11 11:23:06 +00:00
Karol Sójko
117b7b4b99 fix(revisions): removing queries 2023-09-11 12:42:40 +02:00
Karol Sójko
b4bf11d9da fix(revisions): legacy table syncing and select for metadata 2023-09-11 12:23:11 +02:00
Karol Sójko
0306e10469 fix: db debug level on e2e 2023-09-11 12:03:15 +02:00
Karol Sójko
0ab47013f2 fix(api-gateway): awaiting for other services to start 2023-09-11 12:00:43 +02:00
Karol Sójko
836883b82d fix(revisions): rename table only if exists 2023-09-11 11:56:57 +02:00
Karol Sójko
ed671be9c5 fix(revisions): conflict with table naming 2023-09-11 11:52:39 +02:00
Karol Sójko
9676a2586c fix(revisions): add item_uuid to revisions metadata http representation 2023-09-11 11:39:42 +02:00
Karol Sójko
e95ba61c7f feat(auth): add procedure to transition users created between dates (#816) 2023-09-11 10:40:40 +02:00
standardci
a0718aea26 chore(release): publish new version
- @standardnotes/home-server@1.15.32
 - @standardnotes/revisions-server@1.33.4
2023-09-11 07:17:47 +00:00
Karol Sójko
156fa7a618 fix(revisions): add shared vault uuid to revision metadata http representation 2023-09-11 08:44:18 +02:00
standardci
8d006ece30 chore(release): publish new version
- @standardnotes/analytics@2.26.7
 - @standardnotes/api-gateway@1.74.3
 - @standardnotes/auth-server@1.140.0
 - @standardnotes/domain-events-infra@1.12.24
 - @standardnotes/domain-events@2.125.0
 - @standardnotes/event-store@1.11.35
 - @standardnotes/files-server@1.22.14
 - @standardnotes/home-server@1.15.31
 - @standardnotes/revisions-server@1.33.3
 - @standardnotes/scheduler-server@1.20.39
 - @standardnotes/syncing-server@1.95.0
 - @standardnotes/websockets-server@1.10.36
2023-09-08 14:54:00 +00:00
Karol Sójko
037c994040 chore: add run name for e2e test suite 2023-09-08 15:21:26 +02:00
Karol Sójko
a164ba291d fix(auth): specs 2023-09-08 13:41:37 +02:00
Karol Sójko
610fba2601 fix(auth): transition users only when transition mode enabled 2023-09-08 13:34:54 +02:00
Karol Sójko
398338c8f8 feat: transition users after sign out 2023-09-08 12:51:44 +02:00
standardci
34be157d8e chore(release): publish new version
- @standardnotes/home-server@1.15.30
 - @standardnotes/revisions-server@1.33.2
2023-09-08 10:08:48 +00:00
Karol Sójko
76372fe357 fix(revisions): persistence mapper (#814) 2023-09-08 11:29:03 +02:00
standardci
46879c336b chore(release): publish new version
- @standardnotes/auth-server@1.139.0
 - @standardnotes/home-server@1.15.29
 - @standardnotes/syncing-server@1.94.0
2023-09-08 07:53:10 +00:00
Karol Sójko
aef9e936bd feat(auth): add vaults user role into database 2023-09-08 09:19:52 +02:00
Karol Sójko
8cb92d9678 feat(syncing-server): add procedure to trigger transition for specific user 2023-09-08 09:14:07 +02:00
Karol Sójko
52db89de81 chore: disable fail fast on e2e 2023-09-07 19:03:38 +02:00
standardci
c5af8dfc05 chore(release): publish new version
- @standardnotes/home-server@1.15.28
 - @standardnotes/revisions-server@1.33.1
 - @standardnotes/syncing-server@1.93.1
2023-09-07 16:23:44 +00:00
Karol Sójko
27ad8e6959 fix(revisions): waiting for syncing-server on self-hosted setup 2023-09-07 17:44:53 +02:00
Karol Sójko
c4a1502f70 fix(syncing-server): invalidating cache for user removed from shared vault (#812) 2023-09-07 15:41:34 +02:00
standardci
d1d6c753c4 chore(release): publish new version
- @standardnotes/analytics@2.26.6
 - @standardnotes/api-gateway@1.74.2
 - @standardnotes/auth-server@1.138.2
 - @standardnotes/domain-events-infra@1.12.23
 - @standardnotes/domain-events@2.124.0
 - @standardnotes/event-store@1.11.34
 - @standardnotes/files-server@1.22.13
 - @standardnotes/home-server@1.15.27
 - @standardnotes/revisions-server@1.33.0
 - @standardnotes/scheduler-server@1.20.38
 - @standardnotes/syncing-server@1.93.0
 - @standardnotes/websockets-server@1.10.35
2023-09-07 10:46:30 +00:00
Karol Sójko
3bd63f7674 feat: add removing revisions from shared vaults (#811) 2023-09-07 12:02:38 +02:00
standardci
376466d9b2 chore(release): publish new version
- @standardnotes/analytics@2.26.5
 - @standardnotes/api-gateway@1.74.1
 - @standardnotes/auth-server@1.138.1
 - @standardnotes/domain-core@1.28.0
 - @standardnotes/event-store@1.11.33
 - @standardnotes/files-server@1.22.12
 - @standardnotes/home-server@1.15.26
 - @standardnotes/revisions-server@1.32.0
 - @standardnotes/scheduler-server@1.20.37
 - @standardnotes/settings@1.21.30
 - @standardnotes/syncing-server@1.92.1
 - @standardnotes/websockets-server@1.10.34
2023-09-07 09:00:39 +00:00
Karol Sójko
e100c52bbc feat(revisions): fetching single revision in shared vault (#810)
* feat(revisions): fetching single revision in shared vault

* fix(revisions): mapping to http representation
2023-09-07 10:23:03 +02:00
Aman Harwara
d4830dec01 feat: add VaultsUser role name (#809)
* feat: add VaultsUser role name

* fix: test coverage
2023-09-07 08:07:06 +02:00
Karol Sójko
7e11821021 fix(revisions): query for shared vault revisions 2023-09-07 08:05:47 +02:00
standardci
4715e019a2 chore(release): publish new version
- @standardnotes/analytics@2.26.4
 - @standardnotes/api-gateway@1.74.0
 - @standardnotes/auth-server@1.138.0
 - @standardnotes/domain-core@1.27.0
 - @standardnotes/domain-events-infra@1.12.22
 - @standardnotes/domain-events@2.123.0
 - @standardnotes/event-store@1.11.32
 - @standardnotes/files-server@1.22.11
 - @standardnotes/home-server@1.15.25
 - @standardnotes/revisions-server@1.31.0
 - @standardnotes/scheduler-server@1.20.36
 - @standardnotes/security@1.13.0
 - @standardnotes/settings@1.21.29
 - @standardnotes/syncing-server@1.92.0
 - @standardnotes/websockets-server@1.10.33
2023-09-06 14:12:13 +00:00
Karol Sójko
794cd8734a feat: should be able to access shared item revisions as third party user (#807) 2023-09-06 15:36:23 +02:00
standardci
14d42b26bb chore(release): publish new version
- @standardnotes/websockets-server@1.10.32
2023-09-05 12:29:23 +00:00
Karol Sójko
6bb44afd91 fix(websockets): add missing region parameter in api gateway client 2023-09-05 13:50:30 +02:00
standardci
c82345aeeb chore(release): publish new version
- @standardnotes/websockets-server@1.10.31
2023-09-05 06:49:48 +00:00
Karol Sójko
72ab08a0d0 fix(websockets): issue with sending messages to active websocket connections (#806) 2023-09-05 08:13:42 +02:00
standardci
f2d1b47e40 chore(release): publish new version
- @standardnotes/home-server@1.15.24
 - @standardnotes/revisions-server@1.30.14
 - @standardnotes/syncing-server@1.91.3
2023-09-04 12:48:16 +00:00
Karol Sójko
d9ee2c5be2 fix: prevent doubling transitions 2023-09-04 14:10:37 +02:00
standardci
eb59902cf7 chore(release): publish new version
- @standardnotes/home-server@1.15.23
 - @standardnotes/revisions-server@1.30.13
 - @standardnotes/websockets-server@1.10.30
2023-09-04 11:11:04 +00:00
Karol Sójko
002074e4d1 fix(websockets): stringify response from the AWS Api Gateway 2023-09-04 12:32:47 +02:00
Karol Sójko
45b55068f9 fix(revisions): change logs severity in the transition process 2023-09-04 12:19:03 +02:00
Karol Sójko
157eee5d93 chore: increase mocha headless chrome global timeout 2023-09-04 12:06:49 +02:00
standardci
d5f2b4f6eb chore(release): publish new version
- @standardnotes/home-server@1.15.22
 - @standardnotes/revisions-server@1.30.12
 - @standardnotes/websockets-server@1.10.29
2023-09-04 10:05:10 +00:00
Karol Sójko
a7a93497e8 fix(revisions): change order field for transition of revisions 2023-09-04 10:56:14 +02:00
Karol Sójko
8f96f0ed7a fix(websockets): add response debug on websockets sending 2023-09-04 10:43:58 +02:00
standardci
3f064176f2 chore(release): publish new version
- @standardnotes/analytics@2.26.3
 - @standardnotes/api-gateway@1.73.7
 - @standardnotes/auth-server@1.137.6
 - @standardnotes/common@1.50.4
 - @standardnotes/domain-core@1.26.3
 - @standardnotes/domain-events-infra@1.12.21
 - @standardnotes/domain-events@2.122.2
 - @standardnotes/event-store@1.11.31
 - @standardnotes/files-server@1.22.10
 - @standardnotes/home-server@1.15.21
 - @standardnotes/predicates@1.6.11
 - @standardnotes/revisions-server@1.30.11
 - @standardnotes/scheduler-server@1.20.35
 - @standardnotes/security@1.12.2
 - @standardnotes/settings@1.21.28
 - @standardnotes/sncrypto-node@1.15.6
 - @standardnotes/syncing-server@1.91.2
 - @standardnotes/time@1.15.3
 - @standardnotes/websockets-server@1.10.28
2023-09-04 08:26:34 +00:00
Karol Sójko
c7b0c7dfa8 fix(websockets): add debug logs 2023-09-04 09:47:20 +02:00
Karol Sójko
df20dd46db fix(revisions): add more verbose logs to the transition 2023-09-04 09:05:54 +02:00
Karol Sójko
6dfd09989e chore: remove unused nodemon 2023-09-04 08:28:02 +02:00
Karol Sójko
fc821709e2 chore: upgrade docker build push action: 2023-09-04 08:24:39 +02:00
Karol Sójko
e986abaab5 chore: upgrade @types/uuid 2023-09-04 08:23:46 +02:00
Karol Sójko
a006fb3119 chore: upgrade typescript eslint plugin 2023-09-04 08:22:42 +02:00
3239 changed files with 16026 additions and 10106 deletions

1
.github/ci.env vendored
View File

@@ -4,6 +4,7 @@ DB_USERNAME=std_notes_user
DB_PASSWORD=changeme123
DB_DATABASE=standard_notes_db
DB_PORT=3306
DB_DEBUG_LEVEL=all
DB_SQLITE_DATABASE_PATH=standard_notes_db
REDIS_PORT=6379
REDIS_HOST=cache

View File

@@ -33,17 +33,12 @@ jobs:
with:
python-version: '3.11'
- name: Create Bundle Dir
id: bundle-dir
run: echo "temp_dir=$(mktemp -d -t ${{ inputs.service_name }}-${{ github.sha }}-XXXXXXX)" >> $GITHUB_OUTPUT
- name: Cache build
id: cache-build
uses: actions/cache@v3
with:
path: |
packages/**/dist
${{ steps.bundle-dir.outputs.temp_dir }}
key: ${{ runner.os }}-${{ inputs.service_name }}-build-${{ github.sha }}
- name: Set up Node
@@ -57,11 +52,7 @@ jobs:
- name: Build
if: steps.cache-build.outputs.cache-hit != 'true'
run: yarn build ${{ inputs.package_path }}
- name: Bundle
if: steps.cache-build.outputs.cache-hit != 'true'
run: yarn workspace ${{ inputs.workspace_name }} bundle --no-compress --output-directory ${{ steps.bundle-dir.outputs.temp_dir }}
run: yarn build
- name: Login to Docker Hub
uses: docker/login-action@v2
@@ -90,11 +81,11 @@ jobs:
uses: docker/setup-buildx-action@master
- name: Publish Docker image
uses: docker/build-push-action@v3
uses: docker/build-push-action@v4
with:
builder: ${{ steps.buildx.outputs.name }}
context: ${{ steps.bundle-dir.outputs.temp_dir }}
file: ${{ steps.bundle-dir.outputs.temp_dir }}/${{ inputs.package_path }}/Dockerfile
context: .
file: ${{ inputs.package_path }}/Dockerfile
platforms: linux/amd64,linux/arm64
push: true
tags: |

View File

@@ -7,6 +7,10 @@ on:
type: string
default: latest
description: The Docker image tag used for SNJS container
suite:
type: string
default: all
description: The test suite to run
secrets:
DOCKER_USERNAME:
required: true
@@ -18,152 +22,16 @@ on:
required: true
jobs:
e2e:
name: (Self Hosting) E2E Test Suite
strategy:
fail-fast: true
matrix:
secondary_db_enabled: [true, false]
transition_mode_enabled: [true, false]
runs-on: ubuntu-latest
services:
snjs:
image: standardnotes/snjs:${{ inputs.snjs_image_tag }}
ports:
- 9001:9001
steps:
- uses: actions/checkout@v3
- name: Set up Node
uses: actions/setup-node@v3
with:
registry-url: 'https://registry.npmjs.org'
node-version-file: '.nvmrc'
- name: Install
run: yarn install --immutable
- name: Run Server
run: docker compose -f docker-compose.ci.yml up -d
env:
DB_TYPE: mysql
CACHE_TYPE: redis
SECONDARY_DB_ENABLED: ${{ matrix.secondary_db_enabled }}
TRANSITION_MODE_ENABLED: ${{ matrix.transition_mode_enabled }}
- name: Wait for server to start
run: docker/is-available.sh http://localhost:3123 $(pwd)/logs
- name: Run E2E Test Suite
run: yarn dlx mocha-headless-chrome --timeout 1800000 -f http://localhost:9001/mocha/test.html
- name: Show logs on failure
if: ${{ failure() }}
run: |
echo "# Errors:"
tail -n 100 logs/*.err
echo "# Logs:"
tail -n 100 logs/*.log
e2e-self-hosted:
uses: standardnotes/server/.github/workflows/e2e-self-hosted.yml@main
with:
snjs_image_tag: ${{ inputs.snjs_image_tag }}
suite: ${{ inputs.suite }}
secrets: inherit
e2e-home-server:
name: (Home Server) E2E Test Suite
strategy:
fail-fast: true
matrix:
db_type: [mysql, sqlite]
cache_type: [redis, memory]
secondary_db_enabled: [true, false]
transition_mode_enabled: [true, false]
runs-on: ubuntu-latest
services:
snjs:
image: standardnotes/snjs:${{ inputs.snjs_image_tag }}
ports:
- 9001:9001
cache:
image: redis
ports:
- 6379:6379
db:
image: mysql
ports:
- 3306:3306
env:
MYSQL_ROOT_PASSWORD: root
MYSQL_DATABASE: standardnotes
MYSQL_USER: standardnotes
MYSQL_PASSWORD: standardnotes
secondary_db:
image: mongo:5.0
ports:
- 27017:27017
env:
MONGO_INITDB_ROOT_USERNAME: standardnotes
MONGO_INITDB_ROOT_PASSWORD: standardnotes
MONGO_INITDB_DATABASE: standardnotes
steps:
- uses: actions/checkout@v3
- name: Set up Node
uses: actions/setup-node@v3
with:
registry-url: 'https://registry.npmjs.org'
node-version-file: '.nvmrc'
- name: Install Dependencies
run: yarn install --immutable
- name: Build
run: yarn build
- name: Copy dotenv file
run: cp packages/home-server/.env.sample packages/home-server/.env
- name: Fill in env variables
run: |
sed -i "s/JWT_SECRET=/JWT_SECRET=$(openssl rand -hex 32)/g" packages/home-server/.env
sed -i "s/AUTH_JWT_SECRET=/AUTH_JWT_SECRET=$(openssl rand -hex 32)/g" packages/home-server/.env
sed -i "s/ENCRYPTION_SERVER_KEY=/ENCRYPTION_SERVER_KEY=$(openssl rand -hex 32)/g" packages/home-server/.env
sed -i "s/PSEUDO_KEY_PARAMS_KEY=/PSEUDO_KEY_PARAMS_KEY=$(openssl rand -hex 32)/g" packages/home-server/.env
sed -i "s/VALET_TOKEN_SECRET=/VALET_TOKEN_SECRET=$(openssl rand -hex 32)/g" packages/home-server/.env
echo "ACCESS_TOKEN_AGE=4" >> packages/home-server/.env
echo "REFRESH_TOKEN_AGE=10" >> packages/home-server/.env
echo "REVISIONS_FREQUENCY=2" >> packages/home-server/.env
echo "DB_HOST=localhost" >> packages/home-server/.env
echo "DB_PORT=3306" >> packages/home-server/.env
echo "DB_DATABASE=standardnotes" >> packages/home-server/.env
echo "DB_SQLITE_DATABASE_PATH=homeserver.db" >> packages/home-server/.env
echo "DB_USERNAME=standardnotes" >> packages/home-server/.env
echo "DB_PASSWORD=standardnotes" >> packages/home-server/.env
echo "DB_TYPE=${{ matrix.db_type }}" >> packages/home-server/.env
echo "REDIS_URL=redis://localhost:6379" >> packages/home-server/.env
echo "CACHE_TYPE=${{ matrix.cache_type }}" >> packages/home-server/.env
echo "SECONDARY_DB_ENABLED=${{ matrix.secondary_db_enabled }}" >> packages/home-server/.env
echo "TRANSITION_MODE_ENABLED=${{ matrix.transition_mode_enabled }}" >> packages/home-server/.env
echo "MONGO_HOST=localhost" >> packages/home-server/.env
echo "MONGO_PORT=27017" >> packages/home-server/.env
echo "MONGO_DATABASE=standardnotes" >> packages/home-server/.env
echo "MONGO_USERNAME=standardnotes" >> packages/home-server/.env
echo "MONGO_PASSWORD=standardnotes" >> packages/home-server/.env
echo "FILES_SERVER_URL=http://localhost:3123" >> packages/home-server/.env
echo "E2E_TESTING=true" >> packages/home-server/.env
- name: Run Server
run: nohup yarn workspace @standardnotes/home-server start > logs/output.log 2>&1 &
env:
PORT: 3123
- name: Wait for server to start
run: for i in {1..30}; do curl -s http://localhost:3123/healthcheck && break || sleep 1; done
- name: Run E2E Test Suite
run: yarn dlx mocha-headless-chrome --timeout 1800000 -f http://localhost:9001/mocha/test.html
- name: Show logs on failure
if: ${{ failure() }}
run: tail -n 500 logs/output.log
uses: standardnotes/server/.github/workflows/e2e-home-server.yml@main
with:
snjs_image_tag: ${{ inputs.snjs_image_tag }}
suite: ${{ inputs.suite }}
secrets: inherit

View File

@@ -35,7 +35,7 @@ jobs:
uses: docker/setup-buildx-action@master
- name: Publish Docker image
uses: docker/build-push-action@v3
uses: docker/build-push-action@v4
with:
builder: ${{ steps.buildx.outputs.name }}
context: .

128
.github/workflows/e2e-home-server.yml vendored Normal file
View File

@@ -0,0 +1,128 @@
name: E2E Home Server Test Suite
on:
workflow_call:
inputs:
snjs_image_tag:
type: string
default: latest
description: The Docker image tag used for SNJS container
suite:
type: string
default: all
description: The test suite to run
secrets:
DOCKER_USERNAME:
required: true
DOCKER_PASSWORD:
required: true
AWS_ACCESS_KEY_ID:
required: true
AWS_SECRET_ACCESS_KEY:
required: true
jobs:
e2e-home-server:
name: (Home Server) E2E Test Suite
strategy:
fail-fast: false
matrix:
db_type: [mysql, sqlite]
cache_type: [redis, memory]
secondary_db_enabled: [true, false]
runs-on: ubuntu-latest
services:
snjs:
image: standardnotes/snjs:${{ inputs.snjs_image_tag }}
ports:
- 9001:9001
cache:
image: redis
ports:
- 6379:6379
db:
image: mysql
ports:
- 3306:3306
env:
MYSQL_ROOT_PASSWORD: root
MYSQL_DATABASE: standardnotes
MYSQL_USER: standardnotes
MYSQL_PASSWORD: standardnotes
secondary_db:
image: mongo:5.0
ports:
- 27017:27017
env:
MONGO_INITDB_ROOT_USERNAME: standardnotes
MONGO_INITDB_ROOT_PASSWORD: standardnotes
MONGO_INITDB_DATABASE: standardnotes
steps:
- uses: actions/checkout@v3
- name: Set up Node
uses: actions/setup-node@v3
with:
registry-url: 'https://registry.npmjs.org'
node-version-file: '.nvmrc'
- name: Install Dependencies
run: yarn install --immutable
- name: Build
run: yarn build
- name: Copy dotenv file
run: cp packages/home-server/.env.sample packages/home-server/.env
- name: Fill in env variables
run: |
sed -i "s/JWT_SECRET=/JWT_SECRET=$(openssl rand -hex 32)/g" packages/home-server/.env
sed -i "s/AUTH_JWT_SECRET=/AUTH_JWT_SECRET=$(openssl rand -hex 32)/g" packages/home-server/.env
sed -i "s/ENCRYPTION_SERVER_KEY=/ENCRYPTION_SERVER_KEY=$(openssl rand -hex 32)/g" packages/home-server/.env
sed -i "s/PSEUDO_KEY_PARAMS_KEY=/PSEUDO_KEY_PARAMS_KEY=$(openssl rand -hex 32)/g" packages/home-server/.env
sed -i "s/VALET_TOKEN_SECRET=/VALET_TOKEN_SECRET=$(openssl rand -hex 32)/g" packages/home-server/.env
echo "ACCESS_TOKEN_AGE=4" >> packages/home-server/.env
echo "REFRESH_TOKEN_AGE=10" >> packages/home-server/.env
echo "REVISIONS_FREQUENCY=2" >> packages/home-server/.env
echo "DB_HOST=localhost" >> packages/home-server/.env
echo "DB_PORT=3306" >> packages/home-server/.env
echo "DB_DATABASE=standardnotes" >> packages/home-server/.env
echo "DB_SQLITE_DATABASE_PATH=homeserver.db" >> packages/home-server/.env
echo "DB_USERNAME=standardnotes" >> packages/home-server/.env
echo "DB_PASSWORD=standardnotes" >> packages/home-server/.env
echo "DB_TYPE=${{ matrix.db_type }}" >> packages/home-server/.env
echo "DB_DEBUG_LEVEL=all" >> packages/home-server/.env
echo "REDIS_URL=redis://localhost:6379" >> packages/home-server/.env
echo "CACHE_TYPE=${{ matrix.cache_type }}" >> packages/home-server/.env
echo "SECONDARY_DB_ENABLED=${{ matrix.secondary_db_enabled }}" >> packages/home-server/.env
echo "MONGO_HOST=localhost" >> packages/home-server/.env
echo "MONGO_PORT=27017" >> packages/home-server/.env
echo "MONGO_DATABASE=standardnotes" >> packages/home-server/.env
echo "MONGO_USERNAME=standardnotes" >> packages/home-server/.env
echo "MONGO_PASSWORD=standardnotes" >> packages/home-server/.env
echo "FILES_SERVER_URL=http://localhost:3123" >> packages/home-server/.env
echo "E2E_TESTING=true" >> packages/home-server/.env
- name: Run Server
run: nohup yarn workspace @standardnotes/home-server start > logs/output.log 2>&1 &
env:
PORT: 3123
- name: Wait for server to start
run: for i in {1..30}; do curl -s http://localhost:3123/healthcheck && break || sleep 1; done
- name: Run E2E Test Suite
run: yarn dlx mocha-headless-chrome --timeout 3600000 -f http://localhost:9001/mocha/test.html?suite=${{ inputs.suite }}
- name: Archive failed run logs
if: ${{ failure() }}
uses: actions/upload-artifact@v3
with:
name: home-server-failure-logs-${{ inputs.suite }}-${{ matrix.db_type }}-${{ matrix.cache_type }}-${{ matrix.secondary_db_enabled }}
retention-days: 5
path: |
logs/output.log

72
.github/workflows/e2e-self-hosted.yml vendored Normal file
View File

@@ -0,0 +1,72 @@
name: E2E Self Hosted Test Suite
on:
workflow_call:
inputs:
snjs_image_tag:
type: string
default: latest
description: The Docker image tag used for SNJS container
suite:
type: string
default: all
description: The test suite to run
secrets:
DOCKER_USERNAME:
required: true
DOCKER_PASSWORD:
required: true
AWS_ACCESS_KEY_ID:
required: true
AWS_SECRET_ACCESS_KEY:
required: true
jobs:
e2e:
name: (Self Hosting) E2E Test Suite
strategy:
fail-fast: false
matrix:
secondary_db_enabled: [true, false]
runs-on: ubuntu-latest
services:
snjs:
image: standardnotes/snjs:${{ inputs.snjs_image_tag }}
ports:
- 9001:9001
steps:
- uses: actions/checkout@v3
- name: Set up Node
uses: actions/setup-node@v3
with:
registry-url: 'https://registry.npmjs.org'
node-version-file: '.nvmrc'
- name: Install
run: yarn install --immutable
- name: Run Server
run: docker compose -f docker-compose.ci.yml up -d
env:
DB_TYPE: mysql
CACHE_TYPE: redis
SECONDARY_DB_ENABLED: ${{ matrix.secondary_db_enabled }}
- name: Wait for server to start
run: docker/is-available.sh http://localhost:3123 $(pwd)/logs
- name: Run E2E Test Suite
run: yarn dlx mocha-headless-chrome --timeout 3600000 -f http://localhost:9001/mocha/test.html?suite=${{ inputs.suite }}
- name: Archive failed run logs
if: ${{ failure() }}
uses: actions/upload-artifact@v3
with:
name: self-hosted-failure-logs-${{ inputs.suite }}-${{ matrix.secondary_db_enabled }}
retention-days: 5
path: |
logs/*.err
logs/*.log

View File

@@ -1,4 +1,6 @@
name: E2E Test Suite On Self Hosted Server
name: E2E Test Suite
run-name: E2E ${{ inputs.suite }} Test Suite against ${{ inputs.ref_name }} by ${{ inputs.author }}
on:
schedule:
@@ -9,6 +11,18 @@ on:
type: string
default: latest
description: The Docker image tag used for SNJS container
suite:
type: string
default: all
description: The test suite to run
author:
type: string
default: unknown
description: The author that triggered the workflow
ref_name:
type: string
default: unknown
description: The ref name from which the workflow was triggered
jobs:
e2e:
@@ -16,4 +30,5 @@ jobs:
uses: standardnotes/server/.github/workflows/common-e2e.yml@main
with:
snjs_image_tag: ${{ inputs.snjs_image_tag || 'latest' }}
suite: ${{ inputs.suite || 'all' }}
secrets: inherit

View File

@@ -95,9 +95,20 @@ jobs:
- name: Test
run: yarn test
e2e:
e2e-base:
needs: build
name: E2E
name: E2E Base Suite
uses: standardnotes/server/.github/workflows/common-e2e.yml@main
with:
snjs_image_tag: 'latest'
suite: 'base'
secrets: inherit
e2e-vaults:
needs: build
name: E2E Vaults Suite
uses: standardnotes/server/.github/workflows/common-e2e.yml@main
with:
snjs_image_tag: 'latest'
suite: 'vaults'
secrets: inherit

View File

@@ -95,20 +95,32 @@ jobs:
- name: Test
run: yarn test
e2e:
e2e-base:
needs: build
name: E2E
name: E2E Base Suite
uses: standardnotes/server/.github/workflows/common-e2e.yml@main
with:
snjs_image_tag: 'latest'
suite: 'base'
secrets: inherit
e2e-vaults:
needs: build
name: E2E Vaults Suite
uses: standardnotes/server/.github/workflows/common-e2e.yml@main
with:
snjs_image_tag: 'latest'
suite: 'vaults'
secrets: inherit
publish-self-hosting:
needs: [ test, lint, e2e ]
needs: [ test, lint, e2e-base, e2e-vaults ]
name: Publish Self Hosting Docker Image
uses: standardnotes/server/.github/workflows/common-self-hosting.yml@main
secrets: inherit
publish-services:
needs: [ test, lint, e2e ]
needs: [ test, lint, e2e-base, e2e-vaults ]
runs-on: ubuntu-latest

2
.gitignore vendored
View File

@@ -14,6 +14,8 @@ newrelic_agent.log
!.yarn/sdks
!.yarn/versions
yarn.build-error.log
packages/files/uploads/*
!packages/files/uploads/.gitkeep

2
.nvmrc
View File

@@ -1 +1 @@
20.2.0
20.6.1

5121
.pnp.cjs generated

File diff suppressed because one or more lines are too long

98
.pnp.loader.mjs generated
View File

@@ -1,5 +1,5 @@
import { URL as URL$1, fileURLToPath, pathToFileURL } from 'url';
import fs from 'fs';
import { URL as URL$1, fileURLToPath, pathToFileURL } from 'url';
import path from 'path';
import moduleExports, { Module } from 'module';
import { createHash } from 'crypto';
@@ -89,7 +89,6 @@ async function copyPromise(destinationFs, destination, sourceFs, source, opts) {
}));
}
async function copyImpl(prelayout, postlayout, destinationFs, destination, sourceFs, source, opts) {
var _a, _b, _c;
const destinationStat = opts.didParentExist ? await maybeLStat(destinationFs, destination) : null;
const sourceStat = await sourceFs.lstatPromise(source);
const { atime, mtime } = opts.stableTime ? { atime: defaultTime, mtime: defaultTime } : sourceStat;
@@ -115,8 +114,8 @@ async function copyImpl(prelayout, postlayout, destinationFs, destination, sourc
throw new Error(`Unsupported file type (${sourceStat.mode})`);
}
}
if (((_a = opts.linkStrategy) == null ? void 0 : _a.type) !== `HardlinkFromIndex` || !sourceStat.isFile()) {
if (updated || ((_b = destinationStat == null ? void 0 : destinationStat.mtime) == null ? void 0 : _b.getTime()) !== mtime.getTime() || ((_c = destinationStat == null ? void 0 : destinationStat.atime) == null ? void 0 : _c.getTime()) !== atime.getTime()) {
if (opts.linkStrategy?.type !== `HardlinkFromIndex` || !sourceStat.isFile()) {
if (updated || destinationStat?.mtime?.getTime() !== mtime.getTime() || destinationStat?.atime?.getTime() !== atime.getTime()) {
postlayout.push(() => destinationFs.lutimesPromise(destination, atime, mtime));
updated = true;
}
@@ -186,7 +185,7 @@ async function copyFileViaIndex(prelayout, postlayout, destinationFs, destinatio
let indexStat = await maybeLStat(destinationFs, indexPath);
if (destinationStat) {
const isDestinationHardlinkedFromIndex = indexStat && destinationStat.dev === indexStat.dev && destinationStat.ino === indexStat.ino;
const isIndexModified = (indexStat == null ? void 0 : indexStat.mtimeMs) !== defaultTimeMs;
const isIndexModified = indexStat?.mtimeMs !== defaultTimeMs;
if (isDestinationHardlinkedFromIndex) {
if (isIndexModified && linkStrategy.autoRepair) {
atomicBehavior = 0 /* Lock */;
@@ -256,8 +255,7 @@ async function copyFileDirect(prelayout, postlayout, destinationFs, destination,
return true;
}
async function copyFile(prelayout, postlayout, destinationFs, destination, destinationStat, sourceFs, source, sourceStat, opts) {
var _a;
if (((_a = opts.linkStrategy) == null ? void 0 : _a.type) === `HardlinkFromIndex`) {
if (opts.linkStrategy?.type === `HardlinkFromIndex`) {
return copyFileViaIndex(prelayout, postlayout, destinationFs, destination, destinationStat, sourceFs, source, sourceStat, opts, opts.linkStrategy);
} else {
return copyFileDirect(prelayout, postlayout, destinationFs, destination, destinationStat, sourceFs, source, sourceStat, opts);
@@ -387,7 +385,7 @@ class FakeFS {
throw error;
}
}
createdDirectory ?? (createdDirectory = subPath);
createdDirectory ??= subPath;
if (chmod != null)
await this.chmodPromise(subPath, chmod);
if (utimes != null) {
@@ -418,7 +416,7 @@ class FakeFS {
throw error;
}
}
createdDirectory ?? (createdDirectory = subPath);
createdDirectory ??= subPath;
if (chmod != null)
this.chmodSync(subPath, chmod);
if (utimes != null) {
@@ -613,12 +611,14 @@ class FakeFS {
throw error;
}
}
async writeJsonPromise(p, data) {
return await this.writeFilePromise(p, `${JSON.stringify(data, null, 2)}
async writeJsonPromise(p, data, { compact = false } = {}) {
const space = compact ? 0 : 2;
return await this.writeFilePromise(p, `${JSON.stringify(data, null, space)}
`);
}
writeJsonSync(p, data) {
return this.writeFileSync(p, `${JSON.stringify(data, null, 2)}
writeJsonSync(p, data, { compact = false } = {}) {
const space = compact ? 0 : 2;
return this.writeFileSync(p, `${JSON.stringify(data, null, space)}
`);
}
async preserveTimePromise(p, cb) {
@@ -852,7 +852,7 @@ class ProxiedFS extends FakeFS {
readFileSync(p, encoding) {
return this.baseFs.readFileSync(this.fsMapToBase(p), encoding);
}
async readdirPromise(p, opts) {
readdirPromise(p, opts) {
return this.baseFs.readdirPromise(this.mapToBase(p), opts);
}
readdirSync(p, opts) {
@@ -932,12 +932,24 @@ class NodeFS extends BasePortableFakeFS {
this.realFs.opendir(npath.fromPortablePath(p), this.makeCallback(resolve, reject));
}
}).then((dir) => {
return Object.defineProperty(dir, `path`, { value: p, configurable: true, writable: true });
const dirWithFixedPath = dir;
Object.defineProperty(dirWithFixedPath, `path`, {
value: p,
configurable: true,
writable: true
});
return dirWithFixedPath;
});
}
opendirSync(p, opts) {
const dir = typeof opts !== `undefined` ? this.realFs.opendirSync(npath.fromPortablePath(p), opts) : this.realFs.opendirSync(npath.fromPortablePath(p));
return Object.defineProperty(dir, `path`, { value: p, configurable: true, writable: true });
const dirWithFixedPath = dir;
Object.defineProperty(dirWithFixedPath, `path`, {
value: p,
configurable: true,
writable: true
});
return dirWithFixedPath;
}
async readPromise(fd, buffer, offset = 0, length = 0, position = -1) {
return await new Promise((resolve, reject) => {
@@ -1215,16 +1227,16 @@ class NodeFS extends BasePortableFakeFS {
}
async readdirPromise(p, opts) {
return await new Promise((resolve, reject) => {
if (opts == null ? void 0 : opts.withFileTypes) {
this.realFs.readdir(npath.fromPortablePath(p), { withFileTypes: true }, this.makeCallback(resolve, reject));
if (opts) {
this.realFs.readdir(npath.fromPortablePath(p), opts, this.makeCallback(resolve, reject));
} else {
this.realFs.readdir(npath.fromPortablePath(p), this.makeCallback((value) => resolve(value), reject));
}
});
}
readdirSync(p, opts) {
if (opts == null ? void 0 : opts.withFileTypes) {
return this.realFs.readdirSync(npath.fromPortablePath(p), { withFileTypes: true });
if (opts) {
return this.realFs.readdirSync(npath.fromPortablePath(p), opts);
} else {
return this.realFs.readdirSync(npath.fromPortablePath(p));
}
@@ -1359,9 +1371,6 @@ class VirtualFS extends ProxiedFS {
}
const [major, minor] = process.versions.node.split(`.`).map((value) => parseInt(value, 10));
const HAS_CONSOLIDATED_HOOKS = major > 16 || major === 16 && minor >= 12;
const HAS_UNFLAGGED_JSON_MODULES = major > 17 || major === 17 && minor >= 5 || major === 16 && minor >= 15;
const HAS_JSON_IMPORT_ASSERTION_REQUIREMENT = major > 17 || major === 17 && minor >= 1 || major === 16 && minor > 14;
const WATCH_MODE_MESSAGE_USES_ARRAYS = major > 19 || major === 19 && minor >= 2 || major === 18 && minor >= 13;
const HAS_LAZY_LOADED_TRANSLATORS = major > 19 || major === 19 && minor >= 3;
@@ -1427,11 +1436,7 @@ function getFileFormat(filepath) {
);
}
case `.json`: {
if (HAS_UNFLAGGED_JSON_MODULES)
return `json`;
throw new Error(
`Unknown file extension ".json" for ${filepath}`
);
return `json`;
}
case `.js`: {
const pkg = readPackageScope(filepath);
@@ -1452,38 +1457,15 @@ function getFileFormat(filepath) {
}
}
async function getFormat$1(resolved, context, defaultGetFormat) {
const url = tryParseURL(resolved);
if ((url == null ? void 0 : url.protocol) !== `file:`)
return defaultGetFormat(resolved, context, defaultGetFormat);
const format = getFileFormat(fileURLToPath(url));
if (format) {
return {
format
};
}
return defaultGetFormat(resolved, context, defaultGetFormat);
}
async function getSource$1(urlString, context, defaultGetSource) {
const url = tryParseURL(urlString);
if ((url == null ? void 0 : url.protocol) !== `file:`)
return defaultGetSource(urlString, context, defaultGetSource);
return {
source: await fs.promises.readFile(fileURLToPath(url), `utf8`)
};
}
async function load$1(urlString, context, nextLoad) {
var _a;
const url = tryParseURL(urlString);
if ((url == null ? void 0 : url.protocol) !== `file:`)
if (url?.protocol !== `file:`)
return nextLoad(urlString, context, nextLoad);
const filePath = fileURLToPath(url);
const format = getFileFormat(filePath);
if (!format)
return nextLoad(urlString, context, nextLoad);
if (HAS_JSON_IMPORT_ASSERTION_REQUIREMENT && format === `json` && ((_a = context.importAssertions) == null ? void 0 : _a.type) !== `json`) {
if (format === `json` && context.importAssertions?.type !== `json`) {
const err = new TypeError(`[ERR_IMPORT_ASSERTION_TYPE_MISSING]: Module "${urlString}" needs an import assertion of type "json"`);
err.code = `ERR_IMPORT_ASSERTION_TYPE_MISSING`;
throw err;
@@ -1500,7 +1482,7 @@ async function load$1(urlString, context, nextLoad) {
}
return {
format,
source: await fs.promises.readFile(filePath, `utf8`),
source: format === `commonjs` ? void 0 : await fs.promises.readFile(filePath, `utf8`),
shortCircuit: true
};
}
@@ -1991,7 +1973,7 @@ async function resolve$1(originalSpecifier, context, nextResolve) {
specifier = fileURLToPath(url);
}
const { parentURL, conditions = [] } = context;
const issuer = parentURL ? fileURLToPath(parentURL) : process.cwd();
const issuer = parentURL && tryParseURL(parentURL)?.protocol === `file:` ? fileURLToPath(parentURL) : process.cwd();
const pnpapi = findPnpApi(issuer) ?? (url ? findPnpApi(specifier) : null);
if (!pnpapi)
return nextResolve(originalSpecifier, context, nextResolve);
@@ -2068,8 +2050,6 @@ if (!HAS_LAZY_LOADED_TRANSLATORS) {
}
const resolve = resolve$1;
const getFormat = HAS_CONSOLIDATED_HOOKS ? void 0 : getFormat$1;
const getSource = HAS_CONSOLIDATED_HOOKS ? void 0 : getSource$1;
const load = HAS_CONSOLIDATED_HOOKS ? load$1 : void 0;
const load = load$1;
export { getFormat, getSource, load, resolve };
export { load, resolve };

Binary file not shown.

Binary file not shown.

Binary file not shown.

Some files were not shown because too many files have changed in this diff Show More