Register npm packages with jdeploy.com during publish#456
Merged
Conversation
NPMPublishDriver.prepare() was not triggering the /register call on jdeploy.com, so an npm-only publish left the server with no bundles row for the package. Subsequent /download requests then failed with "No code found for package X" (PackageCodeService::fetchCode returns null and throws). The GitHub publish driver already had this call in its prepare(). This mirrors it in NPMPublishDriver so every publish path registers the package up front. Adds NPMPublishDriverRegisterTest verifying: - prepare() calls bundleCodeService.fetchJdeployBundleCode with the bare package name for npm targets - failures from the register call surface instead of being swallowed
shared/pom.xml used <version>LATEST</version> for com.theokanning.openai-gpt3-java:service. Resolution went through the sci-java repo, whose maven-metadata.xml still advertises 0.18.2 as the latest/release version but whose storage now returns 404 for the jar. The build fails even though Maven Central still serves the jar. Pin to 0.18.2. Maven goes directly to Central and the sci-java metadata lookup is bypassed. The LATEST metaversion is deprecated anyway.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Fixes a bug where npm-only publishes were not registering the package name with jdeploy.com, causing the download page to fail with "No code found for package" errors.
Changes
prepare()method that callsbundleCodeService.fetchJdeployBundleCode()with the package name to register it with jdeploy.comBundleCodeServiceandPackageNameServiceinto NPMPublishDriver constructorNPMPublishDriverRegisterTestwith two test cases:prepare()registers the package name for npm targetsMockNetworkPublishingTest,NPMPublishDriverPlatformBundlesTest) to provide the new dependenciesImplementation Details
maybePublishBundles()in theprepare()methodPackageNameService.getFullPackageName()to get the correct package name format expected by the server-side/registerendpointhttps://claude.ai/code/session_01NwazCR8XAUAgqTqF2ZemS9