1
0
mirror of https://github.com/lensapp/lens.git synced 2025-05-20 05:10:56 +00:00
lens/src/common/fs
Sebastian Malton 5a5eda935b
Add better type safety around Channels (#6133)
* Add better type safety around Channels

- Reallow non-JSON serializable complex types

- Remove unnecessary JSON serialization step to IPC

- Remove unnecesary injectable-ization of MessageChannel and
  RequestChannel declarations

- Add channel listener injectable getter function to remove general need
  for type casting and improve type safety

Signed-off-by: Sebastian Malton <sebastian@malton.name>

* Add check to verify data in IPC related tests

Signed-off-by: Sebastian Malton <sebastian@malton.name>

* Fix implementation in light of new safety check in tests

Signed-off-by: Sebastian Malton <sebastian@malton.name>

* Fix listener ID clash potential

Signed-off-by: Sebastian Malton <sebastian@malton.name>

* Switch to not forcing split of request channel handlers being seperate from the listener decl

Signed-off-by: Sebastian Malton <sebastian@malton.name>

* Move message channels to changed signature too

Signed-off-by: Sebastian Malton <sebastian@malton.name>

* Fix not registering listener

Signed-off-by: Sebastian Malton <sebastian@malton.name>

* Fix test imports

Signed-off-by: Sebastian Malton <sebastian@malton.name>

* Fix type errors

Signed-off-by: Sebastian Malton <sebastian@malton.name>

* Refactor listening of different channel kinds

Signed-off-by: Sebastian Malton <sebastian@malton.name>

* Add test covering new checking code for request channel handlers

Signed-off-by: Sebastian Malton <sebastian@malton.name>

Signed-off-by: Sebastian Malton <sebastian@malton.name>
2022-10-13 07:50:19 -04:00
..
stat Fix kubeconfig-sync sometimes producing multiple identical entities (#5855) 2022-10-03 10:38:41 -04:00
watch Fix kubeconfig-sync sometimes producing multiple identical entities (#5855) 2022-10-03 10:38:41 -04:00
access-path.global-override-for-injectable.ts Making apiBase injectable (#6022) 2022-10-05 08:10:36 -04:00
access-path.injectable.ts Making apiBase injectable (#6022) 2022-10-05 08:10:36 -04:00
copy.global-override-for-injectable.ts Making apiBase injectable (#6022) 2022-10-05 08:10:36 -04:00
copy.injectable.ts Making apiBase injectable (#6022) 2022-10-05 08:10:36 -04:00
create-read-file-stream.injectable.ts Fix kubeconfig-sync sometimes producing multiple identical entities (#5855) 2022-10-03 10:38:41 -04:00
delete-file.global-override-for-injectable.ts Making apiBase injectable (#6022) 2022-10-05 08:10:36 -04:00
delete-file.injectable.ts Making apiBase injectable (#6022) 2022-10-05 08:10:36 -04:00
ensure-dir.global-override-for-injectable.ts Making apiBase injectable (#6022) 2022-10-05 08:10:36 -04:00
ensure-dir.injectable.ts Making apiBase injectable (#6022) 2022-10-05 08:10:36 -04:00
exec-file.injectable.ts Add better type safety around Channels (#6133) 2022-10-13 07:50:19 -04:00
extract-tar.global-override-for-injectable.ts Making apiBase injectable (#6022) 2022-10-05 08:10:36 -04:00
extract-tar.injectable.ts Making apiBase injectable (#6022) 2022-10-05 08:10:36 -04:00
fs.injectable.ts Update injectable library (#4842) 2022-02-25 11:10:13 -05:00
lstat.global-override-for-injectable.ts Making apiBase injectable (#6022) 2022-10-05 08:10:36 -04:00
lstat.injectable.ts Making apiBase injectable (#6022) 2022-10-05 08:10:36 -04:00
move.global-override-for-injectable.ts Making apiBase injectable (#6022) 2022-10-05 08:10:36 -04:00
move.injectable.ts Making apiBase injectable (#6022) 2022-10-05 08:10:36 -04:00
path-exists.global-override-for-injectable.ts Making apiBase injectable (#6022) 2022-10-05 08:10:36 -04:00
path-exists.injectable.ts Technical requirements for behavioural unit tests (#5084) 2022-03-31 16:57:05 +03:00
read-directory.global-override-for-injectable.ts Making apiBase injectable (#6022) 2022-10-05 08:10:36 -04:00
read-directory.injectable.ts Making apiBase injectable (#6022) 2022-10-05 08:10:36 -04:00
read-file-buffer.injectable.ts Technical requirements for behavioural unit tests (#5084) 2022-03-31 16:57:05 +03:00
read-file-sync.injectable.ts Fix cluster frame display issue (#5518) 2022-06-20 22:23:15 -04:00
read-file.injectable.ts Making apiBase injectable (#6022) 2022-10-05 08:10:36 -04:00
read-json-file.injectable.ts Technical requirements for behavioural unit tests (#5084) 2022-03-31 16:57:05 +03:00
read-yaml-file.injectable.ts Stop using HelmCli from Renderer (#4861) 2022-06-13 11:42:53 +03:00
remove-path.global-override-for-injectable.ts Making apiBase injectable (#6022) 2022-10-05 08:10:36 -04:00
remove-path.injectable.ts Making apiBase injectable (#6022) 2022-10-05 08:10:36 -04:00
validate-directory.injectable.ts Replace jest.mock's with overriding dependencies (#6014) 2022-08-23 13:04:00 +03:00
write-file.global-override-for-injectable.ts Making apiBase injectable (#6022) 2022-10-05 08:10:36 -04:00
write-file.injectable.ts Making apiBase injectable (#6022) 2022-10-05 08:10:36 -04:00
write-json-file.injectable.ts Making apiBase injectable (#6022) 2022-10-05 08:10:36 -04:00