Skip to content

Specification conformance, 51degrees-java, examples that build from a fresh clone - #192

Draft
jwrosewell wants to merge 1 commit into
rcfrom
remote/java-fresh-clone
Draft

jwrosewell wants to merge 1 commit into
rcfrom
remote/java-fresh-clone

Conversation

@jwrosewell

@jwrosewell jwrosewell commented Nov 16, 2026 •

Copy link
Copy Markdown
Contributor

The problem

Since #175, the tests in examples/device-detection imported TestFileUtils and TestKeyUtils from device-detection.shared's src/test. A fresh clone builds the examples against the published packages, whose 4.5.130 tests jar has neither class, so mvn -pl console -am package -DskipTests in examples/device-detection failed at GettingStartedOnPremTest.java:[26,51]. #187 (343baac) fixed that build, and rc passes from a fresh clone. Nothing stops the same failure coming back.

The change

f17fd53 adds a step to the Examples from a fresh clone workflow (.github/workflows/examples-fresh-clone.yml). On Ubuntu it builds every example module, the web examples too, with its tests compiled, against only the published packages, so a test that uses a class the published packages lack fails there. It runs after the asset cache is saved, so the other systems still get the data file, and it does not run the tests, which the pull request build runs. AGENTS.md describes the new step.

The step that runs ci/run-fresh-clone-example.ps1 is a pwsh step, so -ExpectDownload $true arrives as a boolean. Calling the script by hand with pwsh -File passes every value as a string, which the script rejects, so call it with pwsh -Command when running it locally.

The runs

  • Red: run 43897661762, this workflow at 20f9089 (Specification conformance, 51degrees-java, section 15 #175, the parent of Build the Device Detection example tests from a fresh clone #187): the device-detection job on Ubuntu fails at its console build step, "Build the console examples against the published packages", with the first error GettingStartedOnPremTest.java:[26,51] cannot find symbol, so the new step does not run there. The new step widens what the workflow builds, to every example module with its tests.
  • Green: run 43887891837, the pull request run at f17fd53: the new step passes for device-detection and ip-intelligence on Ubuntu, and the console builds pass on Ubuntu and Windows.
  • A fresh clone on macOS (Intel) with an empty local Maven repository, so only the published packages were used: the build and ci/run-fresh-clone-example.ps1 pass for both products at f17fd53 and at rc 81e3d4a, and every com.51degrees artifact resolved at 4.5.130. At 20f9089 the device-detection build fails at GettingStartedOnPremTest.java:[26,51], and ManualDataUpdateTest, MetadataOnPremTest and OfflineProcessingTest fail the same way.
  • Full build: to follow.

What remains

The full build above.

Before you upgrade

Nothing changes in the packages. This adds a CI step only.

The fresh-clone workflow built only the console examples, with their
tests compiled. A web example test that used a class the published
packages lack would not have failed it. The Ubuntu job now builds every
example module with its tests compiled, after it has saved the data file
for the other systems.
@jwrosewell jwrosewell added the remote-conformance Specification conformance work from the remote packs label Nov 16, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

remote-conformance Specification conformance work from the remote packs

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant