elide-dev / elide

fast polyglot runtime
https://elide.dev
MIT License
100 stars 16 forks source link

feat(fs): support for `copyFile` methods #1066

Closed sgammon closed 2 months ago

sgammon commented 2 months ago

Draft Powered by Pull Request Badge

Summary

Adds initial support for copyFile methods in node:fs and node:fs/promises.

codecov[bot] commented 2 months ago

Codecov Report

Attention: Patch coverage is 48.32215% with 154 lines in your changes missing coverage. Please review.

Project coverage is 55.15%. Comparing base (5174091) to head (6f1868a).

Additional details and impacted files [![Impacted file tree graph](https://app.codecov.io/gh/elide-dev/elide/pull/1066/graphs/tree.svg?width=650&height=150&src=pr&token=FXxhJlpKG3&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=elide-dev)](https://app.codecov.io/gh/elide-dev/elide/pull/1066?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=elide-dev) ```diff @@ Coverage Diff @@ ## main #1066 +/- ## ========================================== + Coverage 54.88% 55.15% +0.27% ========================================== Files 327 329 +2 Lines 10469 10613 +144 Branches 1736 1775 +39 ========================================== + Hits 5746 5854 +108 - Misses 4141 4158 +17 - Partials 582 601 +19 ``` | [Flag](https://app.codecov.io/gh/elide-dev/elide/pull/1066/flags?src=pr&el=flags&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=elide-dev) | Coverage Δ | | |---|---|---| | [gradle](https://app.codecov.io/gh/elide-dev/elide/pull/1066/flags?src=pr&el=flag&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=elide-dev) | `55.15% <48.32%> (+0.27%)` | :arrow_up: | | [jvm](https://app.codecov.io/gh/elide-dev/elide/pull/1066/flags?src=pr&el=flag&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=elide-dev) | `55.15% <48.32%> (+0.27%)` | :arrow_up: | | [lib](https://app.codecov.io/gh/elide-dev/elide/pull/1066/flags?src=pr&el=flag&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=elide-dev) | `55.15% <48.32%> (+0.27%)` | :arrow_up: | | [plugin](https://app.codecov.io/gh/elide-dev/elide/pull/1066/flags?src=pr&el=flag&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=elide-dev) | `55.15% <48.32%> (+0.27%)` | :arrow_up: | Flags with carried forward coverage won't be shown. [Click here](https://docs.codecov.io/docs/carryforward-flags?utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=elide-dev#carryforward-flags-in-the-pull-request-comment) to find out more. | [Files](https://app.codecov.io/gh/elide-dev/elide/pull/1066?dropdown=coverage&src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=elide-dev) | Coverage Δ | | |---|---|---| | [...lin/elide/runtime/gvm/internals/node/NodeStdlib.kt](https://app.codecov.io/gh/elide-dev/elide/pull/1066?src=pr&el=tree&filepath=packages%2Fgraalvm%2Fsrc%2Fmain%2Fkotlin%2Felide%2Fruntime%2Fgvm%2Finternals%2Fnode%2FNodeStdlib.kt&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=elide-dev#diff-cGFja2FnZXMvZ3JhYWx2bS9zcmMvbWFpbi9rb3RsaW4vZWxpZGUvcnVudGltZS9ndm0vaW50ZXJuYWxzL25vZGUvTm9kZVN0ZGxpYi5rdA==) | `97.14% <ø> (-0.16%)` | :arrow_down: | | [...src/main/kotlin/elide/runtime/gvm/js/JavaScript.kt](https://app.codecov.io/gh/elide-dev/elide/pull/1066?src=pr&el=tree&filepath=packages%2Fgraalvm%2Fsrc%2Fmain%2Fkotlin%2Felide%2Fruntime%2Fgvm%2Fjs%2FJavaScript.kt&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=elide-dev#diff-cGFja2FnZXMvZ3JhYWx2bS9zcmMvbWFpbi9rb3RsaW4vZWxpZGUvcnVudGltZS9ndm0vanMvSmF2YVNjcmlwdC5rdA==) | `0.00% <ø> (ø)` | | | [...src/main/kotlin/elide/runtime/gvm/GuestExecutor.kt](https://app.codecov.io/gh/elide-dev/elide/pull/1066?src=pr&el=tree&filepath=packages%2Fgraalvm%2Fsrc%2Fmain%2Fkotlin%2Felide%2Fruntime%2Fgvm%2FGuestExecutor.kt&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=elide-dev#diff-cGFja2FnZXMvZ3JhYWx2bS9zcmMvbWFpbi9rb3RsaW4vZWxpZGUvcnVudGltZS9ndm0vR3Vlc3RFeGVjdXRvci5rdA==) | `0.00% <0.00%> (ø)` | | | [.../elide/runtime/intrinsics/js/node/FilesystemAPI.kt](https://app.codecov.io/gh/elide-dev/elide/pull/1066?src=pr&el=tree&filepath=packages%2Fgraalvm%2Fsrc%2Fmain%2Fkotlin%2Felide%2Fruntime%2Fintrinsics%2Fjs%2Fnode%2FFilesystemAPI.kt&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=elide-dev#diff-cGFja2FnZXMvZ3JhYWx2bS9zcmMvbWFpbi9rb3RsaW4vZWxpZGUvcnVudGltZS9pbnRyaW5zaWNzL2pzL25vZGUvRmlsZXN5c3RlbUFQSS5rdA==) | `85.71% <66.66%> (+7.93%)` | :arrow_up: | | [...runtime/intrinsics/js/node/FilesystemPromiseAPI.kt](https://app.codecov.io/gh/elide-dev/elide/pull/1066?src=pr&el=tree&filepath=packages%2Fgraalvm%2Fsrc%2Fmain%2Fkotlin%2Felide%2Fruntime%2Fintrinsics%2Fjs%2Fnode%2FFilesystemPromiseAPI.kt&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=elide-dev#diff-cGFja2FnZXMvZ3JhYWx2bS9zcmMvbWFpbi9rb3RsaW4vZWxpZGUvcnVudGltZS9pbnRyaW5zaWNzL2pzL25vZGUvRmlsZXN5c3RlbVByb21pc2VBUEkua3Q=) | `25.00% <50.00%> (+25.00%)` | :arrow_up: | | [...in/kotlin/elide/runtime/intrinsics/js/JsPromise.kt](https://app.codecov.io/gh/elide-dev/elide/pull/1066?src=pr&el=tree&filepath=packages%2Fgraalvm%2Fsrc%2Fmain%2Fkotlin%2Felide%2Fruntime%2Fintrinsics%2Fjs%2FJsPromise.kt&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=elide-dev#diff-cGFja2FnZXMvZ3JhYWx2bS9zcmMvbWFpbi9rb3RsaW4vZWxpZGUvcnVudGltZS9pbnRyaW5zaWNzL2pzL0pzUHJvbWlzZS5rdA==) | `36.36% <16.66%> (-0.48%)` | :arrow_down: | | [...rc/main/kotlin/elide/runtime/gvm/GuestExecution.kt](https://app.codecov.io/gh/elide-dev/elide/pull/1066?src=pr&el=tree&filepath=packages%2Fgraalvm%2Fsrc%2Fmain%2Fkotlin%2Felide%2Fruntime%2Fgvm%2FGuestExecution.kt&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=elide-dev#diff-cGFja2FnZXMvZ3JhYWx2bS9zcmMvbWFpbi9rb3RsaW4vZWxpZGUvcnVudGltZS9ndm0vR3Vlc3RFeGVjdXRpb24ua3Q=) | `46.66% <46.66%> (ø)` | | | [...ntime/gvm/internals/intrinsics/js/JsPromiseImpl.kt](https://app.codecov.io/gh/elide-dev/elide/pull/1066?src=pr&el=tree&filepath=packages%2Fgraalvm%2Fsrc%2Fmain%2Fkotlin%2Felide%2Fruntime%2Fgvm%2Finternals%2Fintrinsics%2Fjs%2FJsPromiseImpl.kt&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=elide-dev#diff-cGFja2FnZXMvZ3JhYWx2bS9zcmMvbWFpbi9rb3RsaW4vZWxpZGUvcnVudGltZS9ndm0vaW50ZXJuYWxzL2ludHJpbnNpY3MvanMvSnNQcm9taXNlSW1wbC5rdA==) | `49.25% <26.31%> (+6.94%)` | :arrow_up: | | [...ide/runtime/gvm/internals/intrinsics/js/JsError.kt](https://app.codecov.io/gh/elide-dev/elide/pull/1066?src=pr&el=tree&filepath=packages%2Fgraalvm%2Fsrc%2Fmain%2Fkotlin%2Felide%2Fruntime%2Fgvm%2Finternals%2Fintrinsics%2Fjs%2FJsError.kt&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=elide-dev#diff-cGFja2FnZXMvZ3JhYWx2bS9zcmMvbWFpbi9rb3RsaW4vZWxpZGUvcnVudGltZS9ndm0vaW50ZXJuYWxzL2ludHJpbnNpY3MvanMvSnNFcnJvci5rdA==) | `30.43% <11.76%> (-5.93%)` | :arrow_down: | | [...in/kotlin/elide/runtime/intrinsics/js/err/Error.kt](https://app.codecov.io/gh/elide-dev/elide/pull/1066?src=pr&el=tree&filepath=packages%2Fgraalvm%2Fsrc%2Fmain%2Fkotlin%2Felide%2Fruntime%2Fintrinsics%2Fjs%2Ferr%2FError.kt&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=elide-dev#diff-cGFja2FnZXMvZ3JhYWx2bS9zcmMvbWFpbi9rb3RsaW4vZWxpZGUvcnVudGltZS9pbnRyaW5zaWNzL2pzL2Vyci9FcnJvci5rdA==) | `9.67% <11.53%> (-6.99%)` | :arrow_down: | | ... and [1 more](https://app.codecov.io/gh/elide-dev/elide/pull/1066?src=pr&el=tree-more&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=elide-dev) | | ... and [1 file with indirect coverage changes](https://app.codecov.io/gh/elide-dev/elide/pull/1066/indirect-changes?src=pr&el=tree-more&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=elide-dev) ------ [Continue to review full report in Codecov by Sentry](https://app.codecov.io/gh/elide-dev/elide/pull/1066?dropdown=coverage&src=pr&el=continue&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=elide-dev). > **Legend** - [Click here to learn more](https://docs.codecov.io/docs/codecov-delta?utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=elide-dev) > `Δ = absolute (impact)`, `ø = not affected`, `? = missing data` > Powered by [Codecov](https://app.codecov.io/gh/elide-dev/elide/pull/1066?dropdown=coverage&src=pr&el=footer&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=elide-dev). Last update [5174091...6f1868a](https://app.codecov.io/gh/elide-dev/elide/pull/1066?dropdown=coverage&src=pr&el=lastupdated&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=elide-dev). Read the [comment docs](https://docs.codecov.io/docs/pull-request-comments?utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=elide-dev).