Skip to content

Conversation

@ScriptedAlchemy
Copy link
Member

@ScriptedAlchemy ScriptedAlchemy commented Jul 9, 2024

Description

Provide error message if remoteEntry inner methods fail

Related Issue

#2737

Types of changes

  • Docs change / refactoring / dependency upgrade
  • Bug fix (non-breaking change which fixes an issue)
  • New feature (non-breaking change which adds functionality)

Checklist

  • I have added tests to cover my changes.
  • All new and existing tests passed.
  • I have updated the documentation.

@changeset-bot
Copy link

changeset-bot bot commented Jul 9, 2024

🦋 Changeset detected

Latest commit: dd758da

The changes in this PR will be included in the next version bump.

This PR includes changesets to release 35 packages
Name Type
@module-federation/runtime Patch
@module-federation/devtools Patch
@module-federation/dts-plugin Patch
@module-federation/nextjs-mf Patch
@module-federation/node Patch
@module-federation/runtime-tools Patch
@module-federation/webpack-bundler-runtime Patch
@module-federation/modern-js Patch
@module-federation/enhanced Patch
@module-federation/rspack Patch
modernjs-ssr-dynamic-nested-remote Patch
modernjs-ssr-dynamic-remote-new-version Patch
modernjs-ssr-dynamic-remote Patch
modernjs-ssr-host Patch
modernjs-ssr-nested-remote Patch
modernjs-ssr-remote-new-version Patch
modernjs-ssr-remote Patch
3008-runtime-remote Patch
host Patch
host-v5 Patch
host-vue3 Patch
remote1 Patch
remote2 Patch
remote3 Patch
@module-federation/modernjs Patch
@module-federation/sdk Patch
@module-federation/managers Patch
@module-federation/manifest Patch
@module-federation/third-party-dts-extractor Patch
@module-federation/bridge-react Patch
@module-federation/bridge-vue3 Patch
@module-federation/bridge-shared Patch
@module-federation/bridge-react-webpack-plugin Patch
@module-federation/esbuild Patch
@module-federation/utilities Patch

Not sure what this means? Click here to learn what changesets are.

Click here if you're a maintainer who wants to add another changeset to this PR

@netlify
Copy link

netlify bot commented Jul 9, 2024

Deploy Preview for module-federation-docs ready!

Name Link
🔨 Latest commit dd758da
🔍 Latest deploy log https://app.netlify.com/sites/module-federation-docs/deploys/66bbbbea8b459d0008d18f78
😎 Deploy Preview https://deploy-preview-2746--module-federation-docs.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.

To edit notification comments on pull requests, go to your Netlify site configuration.

Copy link

@markmssd markmssd left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can we get this through? I just lost 2 hours investigating why a remote couldn't load until I found the id clash 😄

@ScriptedAlchemy ScriptedAlchemy marked this pull request as ready for review August 13, 2024 20:02
Copy link
Contributor

@squadronai squadronai bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Summary

The pull request provides an error message when the remote entry initialization fails. The changes are made in the packages/runtime/src/module/index.ts file, which adds error handling for the remote entry initialization process. If the 'init' method is not found in the remoteEntryExports, it logs an error message with troubleshooting steps.

The changes aim to improve the overall reliability and user experience of the module federation runtime by providing more informative error messages when issues arise during the remote entry initialization process.

File Summaries
File Summary
packages/runtime/src/module/index.ts The code adds error handling for remote entry initialization. It checks if the 'init' method exists in remoteEntryExports and logs an error message with troubleshooting steps if it's undefined.

Commits reviewed:

624ad4bf04a17319f9449cdb86a2193cc522aab5...0a94deae7ee9bd0acdedfa227fd764f27300fce1

@ScriptedAlchemy ScriptedAlchemy merged commit 5c7ac8a into main Aug 14, 2024
@ScriptedAlchemy ScriptedAlchemy deleted the error-on-remote-init branch August 14, 2024 00:11
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants