From abcb036cf2a47c24e64f18acbb34b5e27a8b9535 Mon Sep 17 00:00:00 2001 From: Elizio Martins Cezarino <78484991+ElizioMartins@users.noreply.github.com> Date: Tue, 19 May 2026 22:04:00 -0300 Subject: [PATCH] docs: fix misleading import path in Getting Started guide The "Initializing ObjectBox" section used the internal example package path as an import in the code snippet: "github.com/objectbox/objectbox-go/examples/tasks/internal/model" Go enforces that internal packages can only be imported by code within the same module, so copying this snippet causes an immediate compile error: "use of internal package ... not allowed". Replace it with a generic placeholder that clearly shows users they must substitute their own module name, and add a hint block to make that requirement explicit. Fixes objectbox/objectbox-go#28 --- getting-started.md | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/getting-started.md b/getting-started.md index 7046ec6..1a10c9c 100644 --- a/getting-started.md +++ b/getting-started.md @@ -54,12 +54,16 @@ Additionally to the `task.obx.go` there's an `objectbox-model.json` which holds ## Initializing ObjectBox -To use ObjectBox in our main application code, we use `Builder` and give it model information and optionally some other settings. The code with the model information is generated by the ObjectBox and you just need to use in your code: +To use ObjectBox in our main application code, we use `Builder` and give it model information and optionally some other settings. The code with the model information is generated by ObjectBox and you just need to use it in your code: + +{% hint style="warning" %} +Replace `github.com/my-org/my-project` below with your own Go module name (as defined in your `go.mod` file). +{% endhint %} ```go import ( "github.com/objectbox/objectbox-go/objectbox" - "github.com/objectbox/objectbox-go/examples/tasks/internal/model" + "github.com/my-org/my-project/internal/model" ) func initObjectBox() *objectbox.ObjectBox {