From e19d35c457574569a289704bdf2f7df5a84798e3 Mon Sep 17 00:00:00 2001 From: Puskar Basu <45908484+pskrbasu@users.noreply.github.com> Date: Mon, 7 Jul 2025 16:03:56 +0530 Subject: [PATCH] chore: update module to v2 and bump Go version to 1.24 (#4597) --- .github/dependabot.yml | 23 +------------------ .github/workflows/01-steampipe-release.yaml | 2 +- .github/workflows/10-test-lint.yaml | 2 +- .github/workflows/11-test-acceptance.yaml | 4 ++-- cmd/completion.go | 2 +- cmd/login.go | 6 ++--- cmd/plugin.go | 18 +++++++-------- cmd/plugin_manager.go | 12 +++++----- cmd/query.go | 12 +++++----- cmd/root.go | 4 ++-- cmd/service.go | 16 ++++++------- go.mod | 6 ++--- go.sum | 4 ---- main.go | 10 ++++---- pkg/cmdconfig/app_specific.go | 2 +- pkg/cmdconfig/builder.go | 2 +- pkg/cmdconfig/cmd_flags.go | 2 +- pkg/cmdconfig/cmd_hooks.go | 12 +++++----- pkg/cmdconfig/diagnostics.go | 4 ++-- pkg/cmdconfig/validate.go | 2 +- pkg/cmdconfig/viper.go | 2 +- .../connection_state_table_updater.go | 10 ++++---- pkg/connection/connection_watcher.go | 6 ++--- pkg/connection/interface.go | 2 +- pkg/connection/refresh_connections.go | 2 +- pkg/connection/refresh_connections_state.go | 14 +++++------ pkg/connection_sync/wait_for_search_path.go | 4 ++-- pkg/constants/runtime/execution_id.go | 2 +- pkg/db/db_client/db_client.go | 8 +++---- pkg/db/db_client/db_client_connect.go | 6 ++--- pkg/db/db_client/db_client_execute.go | 10 ++++---- pkg/db/db_client/db_client_execute_retry.go | 8 +++---- pkg/db/db_client/db_client_search_path.go | 2 +- pkg/db/db_client/db_client_session.go | 2 +- pkg/db/db_common/appname.go | 2 +- pkg/db/db_common/cache_control.go | 2 +- pkg/db/db_common/client.go | 2 +- pkg/db/db_common/execute.go | 2 +- pkg/db/db_common/functions.go | 2 +- pkg/db/db_common/init_result.go | 4 ++-- pkg/db/db_common/max_connections.go | 2 +- pkg/db/db_common/notification_cache.go | 4 ++-- pkg/db/db_common/schema.go | 2 +- pkg/db/db_common/search_path.go | 2 +- pkg/db/db_common/session_system.go | 4 ++-- pkg/db/db_common/tls_config.go | 2 +- pkg/db/db_common/wait_connection.go | 6 ++--- pkg/db/db_local/backup.go | 6 ++--- pkg/db/db_local/backup_test.go | 4 ++-- pkg/db/db_local/create_connection.go | 10 ++++---- pkg/db/db_local/execute.go | 4 ++-- pkg/db/db_local/install.go | 10 ++++---- pkg/db/db_local/internal.go | 10 ++++---- pkg/db/db_local/local_db_client.go | 8 +++---- pkg/db/db_local/logs.go | 2 +- pkg/db/db_local/notify.go | 2 +- pkg/db/db_local/password.go | 2 +- pkg/db/db_local/refresh_functions_test.go | 2 +- pkg/db/db_local/running_info.go | 4 ++-- pkg/db/db_local/search_path.go | 6 ++--- pkg/db/db_local/server_settings.go | 6 ++--- pkg/db/db_local/service.go | 2 +- pkg/db/db_local/ssl.go | 4 ++-- pkg/db/db_local/start_services.go | 12 +++++----- pkg/db/db_local/stop_services.go | 16 ++++++------- pkg/display/timing.go | 2 +- pkg/error_helpers/postgres.go | 3 ++- pkg/error_helpers/utils.go | 6 ++--- pkg/export/manager.go | 4 ++-- pkg/export/manager_test.go | 2 +- pkg/export/snapshot_exporter.go | 2 +- pkg/filepaths/db_path.go | 6 ++--- pkg/filepaths/steampipe.go | 4 ++-- pkg/initialisation/cloud_metadata.go | 2 +- pkg/initialisation/init_data.go | 12 +++++----- pkg/installationstate/state.go | 2 +- pkg/interactive/interactive_client.go | 20 ++++++++-------- .../interactive_client_autocomplete.go | 6 ++--- pkg/interactive/interactive_client_init.go | 6 ++--- pkg/interactive/metaquery/definitions.go | 2 +- pkg/interactive/metaquery/handler_cache.go | 2 +- pkg/interactive/metaquery/handler_help.go | 2 +- pkg/interactive/metaquery/handler_input.go | 4 ++-- pkg/interactive/metaquery/handler_inspect.go | 6 ++--- .../metaquery/handler_search_path.go | 2 +- pkg/interactive/metaquery/handlers.go | 4 ++-- pkg/interactive/metaquery/validators.go | 2 +- pkg/interactive/run.go | 10 ++++---- pkg/introspection/connection_table_sql.go | 6 ++--- pkg/introspection/plugin_column_table_sql.go | 4 ++-- pkg/introspection/plugin_table_sql.go | 4 ++-- pkg/introspection/rate_limiters_table_sql.go | 4 ++-- pkg/ociinstaller/asset_downloader.go | 2 +- pkg/ociinstaller/db.go | 4 ++-- pkg/ociinstaller/db_downloader.go | 2 +- pkg/ociinstaller/fdw.go | 6 ++--- pkg/ociinstaller/fdw_downloader.go | 2 +- .../versionfile/db_version_file.go | 2 +- pkg/pluginmanager/lifecycle.go | 6 ++--- pkg/pluginmanager/plugin_manager_client.go | 4 ++-- pkg/pluginmanager/state.go | 4 ++-- pkg/pluginmanager_service/get_response.go | 3 ++- pkg/pluginmanager_service/grpc/shared/grpc.go | 3 ++- .../grpc/shared/interface.go | 3 ++- .../grpc/start_failure.go | 5 ++-- pkg/pluginmanager_service/plugin_manager.go | 18 +++++++-------- .../plugin_manager_notifications.go | 4 ++-- .../plugin_manager_plugin_columns.go | 19 +++++++-------- .../plugin_manager_plugin_instance.go | 4 ++-- .../plugin_manager_rate_limiters.go | 12 +++++----- pkg/pluginmanager_service/running_plugin.go | 2 +- pkg/query/init_data.go | 12 +++++----- pkg/query/queryexecute/execute.go | 16 ++++++------- pkg/query/queryhistory/history.go | 4 ++-- pkg/serversettings/load.go | 4 ++-- pkg/serversettings/setup.go | 4 ++-- pkg/steampipeconfig/connection_plugin.go | 8 +++---- pkg/steampipeconfig/connection_schemas.go | 3 ++- pkg/steampipeconfig/connection_state.go | 2 +- pkg/steampipeconfig/connection_state_map.go | 4 ++-- pkg/steampipeconfig/connection_updates.go | 6 ++--- pkg/steampipeconfig/load_config.go | 13 ++++++----- pkg/steampipeconfig/load_connection_state.go | 8 +++---- pkg/steampipeconfig/steampipeconfig.go | 2 +- pkg/steampipeconfig/validate.go | 2 +- pkg/task/display.go | 4 ++-- pkg/task/runner.go | 10 ++++---- 127 files changed, 343 insertions(+), 362 deletions(-) diff --git a/.github/dependabot.yml b/.github/dependabot.yml index 6206e46e3..77d32145a 100644 --- a/.github/dependabot.yml +++ b/.github/dependabot.yml @@ -22,29 +22,8 @@ updates: pull-request-branch-name: separator: "-" assignees: - - "binaek" + - "pskrbasu" - "kaidaguerre" labels: - "dependencies" - "house-keeping" - -# Commenting out since we don't want dependabot PRs for the ui package right now. -# We can add back when we need them. - - # - package-ecosystem: "npm" - # directory: "/ui/dashboard" - # schedule: - # interval: "daily" - # commit-message: - # prefix: "[dep][dash]" - # include: "scope" - # pull-request-branch-name: - # separator: "-" - # assignees: - # - "MichaelBurgess" - # - "binaek" - # - "kaidaguerre" - # labels: - # - "dependencies" - # - "dashboards" - # - "house-keeping" diff --git a/.github/workflows/01-steampipe-release.yaml b/.github/workflows/01-steampipe-release.yaml index e050a17a7..9bc68d9fd 100644 --- a/.github/workflows/01-steampipe-release.yaml +++ b/.github/workflows/01-steampipe-release.yaml @@ -111,7 +111,7 @@ jobs: - name: Set up Go uses: actions/setup-go@d35c59abb061a4a6fb18e82ac0862c26744d6ab5 # v5.5.0 with: - go-version: 1.23 + go-version: 1.24 - name: Install GoReleaser uses: goreleaser/goreleaser-action@9c156ee8a17a598857849441385a2041ef570552 # v6.3.0 diff --git a/.github/workflows/10-test-lint.yaml b/.github/workflows/10-test-lint.yaml index 9f24ef8b4..6c721cb82 100644 --- a/.github/workflows/10-test-lint.yaml +++ b/.github/workflows/10-test-lint.yaml @@ -29,7 +29,7 @@ jobs: - name: Set up Go uses: actions/setup-go@d35c59abb061a4a6fb18e82ac0862c26744d6ab5 # v5.5.0 with: - go-version: 1.22 + go-version: 1.24 - name: golangci-lint uses: golangci/golangci-lint-action@4afd733a84b1f43292c63897423277bb7f4313a9 # v8.0.0 diff --git a/.github/workflows/11-test-acceptance.yaml b/.github/workflows/11-test-acceptance.yaml index 4b7853d9a..2a04505ad 100644 --- a/.github/workflows/11-test-acceptance.yaml +++ b/.github/workflows/11-test-acceptance.yaml @@ -29,7 +29,7 @@ jobs: - name: Set up Go uses: actions/setup-go@d35c59abb061a4a6fb18e82ac0862c26744d6ab5 # v5.5.0 with: - go-version: 1.22 + go-version: 1.24 - name: Fetching Go Cache Paths id: go-cache-paths @@ -132,7 +132,7 @@ jobs: - name: Set up Go uses: actions/setup-go@d35c59abb061a4a6fb18e82ac0862c26744d6ab5 # v5.5.0 with: - go-version: 1.22 + go-version: 1.24 - name: Prepare for downloads id: prepare-for-downloads diff --git a/cmd/completion.go b/cmd/completion.go index 9e7311197..edaa9e9f1 100644 --- a/cmd/completion.go +++ b/cmd/completion.go @@ -7,7 +7,7 @@ import ( "github.com/spf13/cobra" "github.com/turbot/pipe-fittings/v2/constants" - "github.com/turbot/steampipe/pkg/cmdconfig" + "github.com/turbot/steampipe/v2/pkg/cmdconfig" ) func generateCompletionScriptsCmd() *cobra.Command { diff --git a/cmd/login.go b/cmd/login.go index 29feca9d6..cca8eb34d 100644 --- a/cmd/login.go +++ b/cmd/login.go @@ -12,9 +12,9 @@ import ( pconstants "github.com/turbot/pipe-fittings/v2/constants" "github.com/turbot/pipe-fittings/v2/pipes" "github.com/turbot/steampipe-plugin-sdk/v5/sperr" - "github.com/turbot/steampipe/pkg/cmdconfig" - "github.com/turbot/steampipe/pkg/constants" - "github.com/turbot/steampipe/pkg/error_helpers" + "github.com/turbot/steampipe/v2/pkg/cmdconfig" + "github.com/turbot/steampipe/v2/pkg/constants" + "github.com/turbot/steampipe/v2/pkg/error_helpers" ) func loginCmd() *cobra.Command { diff --git a/cmd/plugin.go b/cmd/plugin.go index 2681c9bc1..12ae83d75 100644 --- a/cmd/plugin.go +++ b/cmd/plugin.go @@ -22,15 +22,15 @@ import ( "github.com/turbot/pipe-fittings/v2/utils" "github.com/turbot/pipe-fittings/v2/versionfile" "github.com/turbot/steampipe-plugin-sdk/v5/sperr" - "github.com/turbot/steampipe/pkg/cmdconfig" - "github.com/turbot/steampipe/pkg/constants" - "github.com/turbot/steampipe/pkg/db/db_local" - "github.com/turbot/steampipe/pkg/error_helpers" - "github.com/turbot/steampipe/pkg/installationstate" - "github.com/turbot/steampipe/pkg/ociinstaller" - "github.com/turbot/steampipe/pkg/plugin" - "github.com/turbot/steampipe/pkg/statushooks" - "github.com/turbot/steampipe/pkg/steampipeconfig" + "github.com/turbot/steampipe/v2/pkg/cmdconfig" + "github.com/turbot/steampipe/v2/pkg/constants" + "github.com/turbot/steampipe/v2/pkg/db/db_local" + "github.com/turbot/steampipe/v2/pkg/error_helpers" + "github.com/turbot/steampipe/v2/pkg/installationstate" + "github.com/turbot/steampipe/v2/pkg/ociinstaller" + "github.com/turbot/steampipe/v2/pkg/plugin" + "github.com/turbot/steampipe/v2/pkg/statushooks" + "github.com/turbot/steampipe/v2/pkg/steampipeconfig" ) type installedPlugin struct { diff --git a/cmd/plugin_manager.go b/cmd/plugin_manager.go index e3aabef83..9920704d1 100644 --- a/cmd/plugin_manager.go +++ b/cmd/plugin_manager.go @@ -16,12 +16,12 @@ import ( "github.com/turbot/go-kit/types" sdklogging "github.com/turbot/steampipe-plugin-sdk/v5/logging" "github.com/turbot/steampipe-plugin-sdk/v5/plugin" - "github.com/turbot/steampipe/pkg/cmdconfig" - "github.com/turbot/steampipe/pkg/connection" - "github.com/turbot/steampipe/pkg/constants" - "github.com/turbot/steampipe/pkg/filepaths" - "github.com/turbot/steampipe/pkg/pluginmanager_service" - "github.com/turbot/steampipe/pkg/steampipeconfig" + "github.com/turbot/steampipe/v2/pkg/cmdconfig" + "github.com/turbot/steampipe/v2/pkg/connection" + "github.com/turbot/steampipe/v2/pkg/constants" + "github.com/turbot/steampipe/v2/pkg/filepaths" + "github.com/turbot/steampipe/v2/pkg/pluginmanager_service" + "github.com/turbot/steampipe/v2/pkg/steampipeconfig" ) func pluginManagerCmd() *cobra.Command { diff --git a/cmd/query.go b/cmd/query.go index 0e73305e5..81423a7cb 100644 --- a/cmd/query.go +++ b/cmd/query.go @@ -16,12 +16,12 @@ import ( "github.com/turbot/pipe-fittings/v2/contexthelpers" "github.com/turbot/pipe-fittings/v2/utils" "github.com/turbot/steampipe-plugin-sdk/v5/sperr" - "github.com/turbot/steampipe/pkg/cmdconfig" - "github.com/turbot/steampipe/pkg/constants" - "github.com/turbot/steampipe/pkg/error_helpers" - "github.com/turbot/steampipe/pkg/query" - "github.com/turbot/steampipe/pkg/query/queryexecute" - "github.com/turbot/steampipe/pkg/statushooks" + "github.com/turbot/steampipe/v2/pkg/cmdconfig" + "github.com/turbot/steampipe/v2/pkg/constants" + "github.com/turbot/steampipe/v2/pkg/error_helpers" + "github.com/turbot/steampipe/v2/pkg/query" + "github.com/turbot/steampipe/v2/pkg/query/queryexecute" + "github.com/turbot/steampipe/v2/pkg/statushooks" ) // variable used to assign the timing mode flag diff --git a/cmd/root.go b/cmd/root.go index e712c9a78..1770063b5 100644 --- a/cmd/root.go +++ b/cmd/root.go @@ -11,8 +11,8 @@ import ( "github.com/turbot/pipe-fittings/v2/app_specific" "github.com/turbot/pipe-fittings/v2/constants" "github.com/turbot/pipe-fittings/v2/utils" - "github.com/turbot/steampipe/pkg/error_helpers" - "github.com/turbot/steampipe/pkg/statushooks" + "github.com/turbot/steampipe/v2/pkg/error_helpers" + "github.com/turbot/steampipe/v2/pkg/statushooks" ) var exitCode int diff --git a/cmd/service.go b/cmd/service.go index f2c818ef2..04d174e38 100644 --- a/cmd/service.go +++ b/cmd/service.go @@ -18,14 +18,14 @@ import ( "github.com/turbot/pipe-fittings/v2/querydisplay" putils "github.com/turbot/pipe-fittings/v2/utils" "github.com/turbot/steampipe-plugin-sdk/v5/sperr" - "github.com/turbot/steampipe/pkg/cmdconfig" - "github.com/turbot/steampipe/pkg/constants" - "github.com/turbot/steampipe/pkg/db/db_local" - "github.com/turbot/steampipe/pkg/error_helpers" - "github.com/turbot/steampipe/pkg/filepaths" - "github.com/turbot/steampipe/pkg/pluginmanager" - pb "github.com/turbot/steampipe/pkg/pluginmanager_service/grpc/proto" - "github.com/turbot/steampipe/pkg/statushooks" + "github.com/turbot/steampipe/v2/pkg/cmdconfig" + "github.com/turbot/steampipe/v2/pkg/constants" + "github.com/turbot/steampipe/v2/pkg/db/db_local" + "github.com/turbot/steampipe/v2/pkg/error_helpers" + "github.com/turbot/steampipe/v2/pkg/filepaths" + "github.com/turbot/steampipe/v2/pkg/pluginmanager" + pb "github.com/turbot/steampipe/v2/pkg/pluginmanager_service/grpc/proto" + "github.com/turbot/steampipe/v2/pkg/statushooks" ) func serviceCmd() *cobra.Command { diff --git a/go.mod b/go.mod index 169c01801..593346a91 100644 --- a/go.mod +++ b/go.mod @@ -1,6 +1,6 @@ -module github.com/turbot/steampipe +module github.com/turbot/steampipe/v2 -go 1.23.2 +go 1.24 toolchain go1.24.0 @@ -33,7 +33,6 @@ require ( github.com/mitchellh/colorstring v0.0.0-20190213212951-d06e56a500db // indirect github.com/olekukonko/tablewriter v0.0.5 github.com/opencontainers/image-spec v1.1.1 - github.com/otiai10/copy v1.14.1 github.com/pkg/errors v0.9.1 github.com/sethvargo/go-retry v0.3.0 github.com/shiena/ansicolor v0.0.0-20230509054315-a9deabde6e02 @@ -212,7 +211,6 @@ require ( github.com/go-viper/mapstructure/v2 v2.2.1 // indirect github.com/logrusorgru/aurora v2.0.3+incompatible // indirect github.com/munnerz/goautoneg v0.0.0-20191010083416-a7dc8b61c822 // indirect - github.com/otiai10/mint v1.6.3 // indirect github.com/pkg/term v1.1.0 // indirect github.com/planetscale/vtprotobuf v0.6.1-0.20240319094008-0393e58bdf10 // indirect github.com/prometheus/client_golang v1.21.1 // indirect diff --git a/go.sum b/go.sum index 3597e912d..d1a74c263 100644 --- a/go.sum +++ b/go.sum @@ -1149,10 +1149,6 @@ github.com/opencontainers/go-digest v1.0.0 h1:apOUWs51W5PlhuyGyz9FCeeBIOUDA/6nW8 github.com/opencontainers/go-digest v1.0.0/go.mod h1:0JzlMkj0TRzQZfJkVvzbP0HBR3IKzErnv2BNG4W4MAM= github.com/opencontainers/image-spec v1.1.1 h1:y0fUlFfIZhPF1W537XOLg0/fcx6zcHCJwooC2xJA040= github.com/opencontainers/image-spec v1.1.1/go.mod h1:qpqAh3Dmcf36wStyyWU+kCeDgrGnAve2nCC8+7h8Q0M= -github.com/otiai10/copy v1.14.1 h1:5/7E6qsUMBaH5AnQ0sSLzzTg1oTECmcCmT6lvF45Na8= -github.com/otiai10/copy v1.14.1/go.mod h1:oQwrEDDOci3IM8dJF0d8+jnbfPDllW6vUjNc3DoZm9I= -github.com/otiai10/mint v1.6.3 h1:87qsV/aw1F5as1eH1zS/yqHY85ANKVMgkDrf9rcxbQs= -github.com/otiai10/mint v1.6.3/go.mod h1:MJm72SBthJjz8qhefc4z1PYEieWmy8Bku7CjcAqyUSM= github.com/pelletier/go-toml/v2 v2.2.3 h1:YmeHyLY8mFWbdkNWwpr+qIL2bEqT0o95WSdkNHvL12M= github.com/pelletier/go-toml/v2 v2.2.3/go.mod h1:MfCQTFTvCcUyyvvwm1+G6H/jORL20Xlb6rzQu9GuUkc= github.com/phpdave11/gofpdf v1.4.2/go.mod h1:zpO6xFn9yxo3YLyMvW8HcKWVdbNqgIfOOp2dXMnm1mY= diff --git a/main.go b/main.go index 37da44b87..6f38a3e18 100644 --- a/main.go +++ b/main.go @@ -14,11 +14,11 @@ import ( "github.com/spf13/viper" "github.com/turbot/go-kit/helpers" "github.com/turbot/pipe-fittings/v2/utils" - "github.com/turbot/steampipe/cmd" - "github.com/turbot/steampipe/pkg/cmdconfig" - "github.com/turbot/steampipe/pkg/constants" - localconstants "github.com/turbot/steampipe/pkg/constants" - "github.com/turbot/steampipe/pkg/error_helpers" + "github.com/turbot/steampipe/v2/cmd" + "github.com/turbot/steampipe/v2/pkg/cmdconfig" + "github.com/turbot/steampipe/v2/pkg/constants" + localconstants "github.com/turbot/steampipe/v2/pkg/constants" + "github.com/turbot/steampipe/v2/pkg/error_helpers" ) var exitCode int = constants.ExitCodeSuccessful diff --git a/pkg/cmdconfig/app_specific.go b/pkg/cmdconfig/app_specific.go index 4fbe806e7..a7dc503c3 100644 --- a/pkg/cmdconfig/app_specific.go +++ b/pkg/cmdconfig/app_specific.go @@ -10,7 +10,7 @@ import ( "github.com/turbot/go-kit/files" "github.com/turbot/pipe-fittings/v2/app_specific" "github.com/turbot/pipe-fittings/v2/error_helpers" - "github.com/turbot/steampipe/pkg/constants" + "github.com/turbot/steampipe/v2/pkg/constants" ) // SetAppSpecificConstants sets app specific constants defined in pipe-fittings diff --git a/pkg/cmdconfig/builder.go b/pkg/cmdconfig/builder.go index e362bb864..7da540d5b 100644 --- a/pkg/cmdconfig/builder.go +++ b/pkg/cmdconfig/builder.go @@ -8,7 +8,7 @@ import ( "github.com/spf13/viper" pconstants "github.com/turbot/pipe-fittings/v2/constants" "github.com/turbot/pipe-fittings/v2/utils" - "github.com/turbot/steampipe/pkg/constants" + "github.com/turbot/steampipe/v2/pkg/constants" ) type CmdBuilder struct { diff --git a/pkg/cmdconfig/cmd_flags.go b/pkg/cmdconfig/cmd_flags.go index 2c8397e8d..5acf32df2 100644 --- a/pkg/cmdconfig/cmd_flags.go +++ b/pkg/cmdconfig/cmd_flags.go @@ -6,7 +6,7 @@ import ( "github.com/fatih/color" "github.com/spf13/cobra" "github.com/spf13/viper" - "github.com/turbot/steampipe/pkg/error_helpers" + "github.com/turbot/steampipe/v2/pkg/error_helpers" ) var requiredColor = color.New(color.Bold).SprintfFunc() diff --git a/pkg/cmdconfig/cmd_hooks.go b/pkg/cmdconfig/cmd_hooks.go index e412471d6..9d1b6e4f5 100644 --- a/pkg/cmdconfig/cmd_hooks.go +++ b/pkg/cmdconfig/cmd_hooks.go @@ -32,12 +32,12 @@ import ( sdklogging "github.com/turbot/steampipe-plugin-sdk/v5/logging" "github.com/turbot/steampipe-plugin-sdk/v5/plugin" "github.com/turbot/steampipe-plugin-sdk/v5/sperr" - "github.com/turbot/steampipe/pkg/constants" - "github.com/turbot/steampipe/pkg/constants/runtime" - "github.com/turbot/steampipe/pkg/error_helpers" - "github.com/turbot/steampipe/pkg/filepaths" - "github.com/turbot/steampipe/pkg/steampipeconfig" - "github.com/turbot/steampipe/pkg/task" + "github.com/turbot/steampipe/v2/pkg/constants" + "github.com/turbot/steampipe/v2/pkg/constants/runtime" + "github.com/turbot/steampipe/v2/pkg/error_helpers" + "github.com/turbot/steampipe/v2/pkg/filepaths" + "github.com/turbot/steampipe/v2/pkg/steampipeconfig" + "github.com/turbot/steampipe/v2/pkg/task" ) var waitForTasksChannel chan struct{} diff --git a/pkg/cmdconfig/diagnostics.go b/pkg/cmdconfig/diagnostics.go index 315738d34..c68bc7f0b 100644 --- a/pkg/cmdconfig/diagnostics.go +++ b/pkg/cmdconfig/diagnostics.go @@ -9,8 +9,8 @@ import ( "strings" "github.com/spf13/viper" - "github.com/turbot/steampipe/pkg/constants" - "github.com/turbot/steampipe/pkg/error_helpers" + "github.com/turbot/steampipe/v2/pkg/constants" + "github.com/turbot/steampipe/v2/pkg/error_helpers" ) // DisplayConfig prints all config set via WorkspaceProfile or HCL options diff --git a/pkg/cmdconfig/validate.go b/pkg/cmdconfig/validate.go index 311cf4d07..d522febda 100644 --- a/pkg/cmdconfig/validate.go +++ b/pkg/cmdconfig/validate.go @@ -10,7 +10,7 @@ import ( pconstants "github.com/turbot/pipe-fittings/v2/constants" "github.com/turbot/pipe-fittings/v2/pipes" "github.com/turbot/pipe-fittings/v2/steampipeconfig" - "github.com/turbot/steampipe/pkg/error_helpers" + "github.com/turbot/steampipe/v2/pkg/error_helpers" ) func ValidateSnapshotArgs(ctx context.Context) error { diff --git a/pkg/cmdconfig/viper.go b/pkg/cmdconfig/viper.go index c99ac656a..3049395dc 100644 --- a/pkg/cmdconfig/viper.go +++ b/pkg/cmdconfig/viper.go @@ -14,7 +14,7 @@ import ( pconstants "github.com/turbot/pipe-fittings/v2/constants" "github.com/turbot/pipe-fittings/v2/parse" "github.com/turbot/pipe-fittings/v2/workspace_profile" - "github.com/turbot/steampipe/pkg/constants" + "github.com/turbot/steampipe/v2/pkg/constants" ) // Viper fetches the global viper instance diff --git a/pkg/connection/connection_state_table_updater.go b/pkg/connection/connection_state_table_updater.go index afa1bcd4c..1beec7769 100644 --- a/pkg/connection/connection_state_table_updater.go +++ b/pkg/connection/connection_state_table_updater.go @@ -6,11 +6,11 @@ import ( "github.com/jackc/pgx/v5" "github.com/jackc/pgx/v5/pgxpool" - "github.com/turbot/steampipe/pkg/constants" - "github.com/turbot/steampipe/pkg/db/db_common" - "github.com/turbot/steampipe/pkg/db/db_local" - "github.com/turbot/steampipe/pkg/introspection" - "github.com/turbot/steampipe/pkg/steampipeconfig" + "github.com/turbot/steampipe/v2/pkg/constants" + "github.com/turbot/steampipe/v2/pkg/db/db_common" + "github.com/turbot/steampipe/v2/pkg/db/db_local" + "github.com/turbot/steampipe/v2/pkg/introspection" + "github.com/turbot/steampipe/v2/pkg/steampipeconfig" ) type connectionStateTableUpdater struct { diff --git a/pkg/connection/connection_watcher.go b/pkg/connection/connection_watcher.go index f2384114a..158eeb0d6 100644 --- a/pkg/connection/connection_watcher.go +++ b/pkg/connection/connection_watcher.go @@ -9,9 +9,9 @@ import ( "github.com/turbot/go-kit/filewatcher" "github.com/turbot/go-kit/helpers" "github.com/turbot/pipe-fittings/v2/filepaths" - "github.com/turbot/steampipe/pkg/cmdconfig" - "github.com/turbot/steampipe/pkg/constants" - "github.com/turbot/steampipe/pkg/steampipeconfig" + "github.com/turbot/steampipe/v2/pkg/cmdconfig" + "github.com/turbot/steampipe/v2/pkg/constants" + "github.com/turbot/steampipe/v2/pkg/steampipeconfig" ) type ConnectionWatcher struct { diff --git a/pkg/connection/interface.go b/pkg/connection/interface.go index 03e4d247b..f688bd35f 100644 --- a/pkg/connection/interface.go +++ b/pkg/connection/interface.go @@ -7,7 +7,7 @@ import ( "github.com/turbot/pipe-fittings/v2/error_helpers" "github.com/turbot/pipe-fittings/v2/plugin" "github.com/turbot/steampipe-plugin-sdk/v5/grpc/proto" - "github.com/turbot/steampipe/pkg/pluginmanager_service/grpc/shared" + "github.com/turbot/steampipe/v2/pkg/pluginmanager_service/grpc/shared" ) type pluginManager interface { diff --git a/pkg/connection/refresh_connections.go b/pkg/connection/refresh_connections.go index 6807d268e..8458aaf85 100644 --- a/pkg/connection/refresh_connections.go +++ b/pkg/connection/refresh_connections.go @@ -7,7 +7,7 @@ import ( "time" "github.com/turbot/go-kit/helpers" - "github.com/turbot/steampipe/pkg/steampipeconfig" + "github.com/turbot/steampipe/v2/pkg/steampipeconfig" ) // only allow one execution of refresh connections diff --git a/pkg/connection/refresh_connections_state.go b/pkg/connection/refresh_connections_state.go index 4ea3f81c9..ba89efb4f 100644 --- a/pkg/connection/refresh_connections_state.go +++ b/pkg/connection/refresh_connections_state.go @@ -21,12 +21,12 @@ import ( "github.com/turbot/steampipe-plugin-sdk/v5/grpc/proto" "github.com/turbot/steampipe-plugin-sdk/v5/plugin" "github.com/turbot/steampipe-plugin-sdk/v5/sperr" - "github.com/turbot/steampipe/pkg/constants" - "github.com/turbot/steampipe/pkg/db/db_common" - "github.com/turbot/steampipe/pkg/db/db_local" - "github.com/turbot/steampipe/pkg/error_helpers" - "github.com/turbot/steampipe/pkg/introspection" - "github.com/turbot/steampipe/pkg/steampipeconfig" + "github.com/turbot/steampipe/v2/pkg/constants" + "github.com/turbot/steampipe/v2/pkg/db/db_common" + "github.com/turbot/steampipe/v2/pkg/db/db_local" + "github.com/turbot/steampipe/v2/pkg/error_helpers" + "github.com/turbot/steampipe/v2/pkg/introspection" + "github.com/turbot/steampipe/v2/pkg/steampipeconfig" "golang.org/x/exp/maps" "golang.org/x/sync/semaphore" ) @@ -204,7 +204,7 @@ func (s *refreshConnectionState) setFailedConnectionsToError(ctx context.Context for _, c := range s.connectionUpdates.FinalConnectionState { if c.State == constants.ConnectionStateError { - if err := s.tableUpdater.onConnectionError(ctx, conn.Conn(), c.ConnectionName, fmt.Errorf(c.Error())); err != nil { + if err := s.tableUpdater.onConnectionError(ctx, conn.Conn(), c.ConnectionName, fmt.Errorf("%s", c.Error())); err != nil { return sperr.WrapWithMessage(err, "failed to update connection state table") } } diff --git a/pkg/connection_sync/wait_for_search_path.go b/pkg/connection_sync/wait_for_search_path.go index 38d3cd52f..57a512663 100644 --- a/pkg/connection_sync/wait_for_search_path.go +++ b/pkg/connection_sync/wait_for_search_path.go @@ -3,8 +3,8 @@ package connection_sync import ( "context" - "github.com/turbot/steampipe/pkg/db/db_common" - "github.com/turbot/steampipe/pkg/steampipeconfig" + "github.com/turbot/steampipe/v2/pkg/db/db_common" + "github.com/turbot/steampipe/v2/pkg/steampipeconfig" ) // WaitForSearchPathSchemas identifies the first connection in the search path for each plugin, diff --git a/pkg/constants/runtime/execution_id.go b/pkg/constants/runtime/execution_id.go index 05eb6b9f1..57a406acd 100644 --- a/pkg/constants/runtime/execution_id.go +++ b/pkg/constants/runtime/execution_id.go @@ -5,7 +5,7 @@ import ( "time" "github.com/turbot/go-kit/helpers" - "github.com/turbot/steampipe/pkg/constants" + "github.com/turbot/steampipe/v2/pkg/constants" ) var ( diff --git a/pkg/db/db_client/db_client.go b/pkg/db/db_client/db_client.go index 841dd394a..c99abef2a 100644 --- a/pkg/db/db_client/db_client.go +++ b/pkg/db/db_client/db_client.go @@ -12,10 +12,10 @@ import ( "github.com/spf13/viper" pconstants "github.com/turbot/pipe-fittings/v2/constants" "github.com/turbot/pipe-fittings/v2/utils" - "github.com/turbot/steampipe/pkg/constants" - "github.com/turbot/steampipe/pkg/db/db_common" - "github.com/turbot/steampipe/pkg/serversettings" - "github.com/turbot/steampipe/pkg/steampipeconfig" + "github.com/turbot/steampipe/v2/pkg/constants" + "github.com/turbot/steampipe/v2/pkg/db/db_common" + "github.com/turbot/steampipe/v2/pkg/serversettings" + "github.com/turbot/steampipe/v2/pkg/steampipeconfig" "golang.org/x/exp/maps" "golang.org/x/sync/semaphore" ) diff --git a/pkg/db/db_client/db_client_connect.go b/pkg/db/db_client/db_client_connect.go index fb5f08779..e436016fb 100644 --- a/pkg/db/db_client/db_client_connect.go +++ b/pkg/db/db_client/db_client_connect.go @@ -10,9 +10,9 @@ import ( "github.com/spf13/viper" pconstants "github.com/turbot/pipe-fittings/v2/constants" "github.com/turbot/pipe-fittings/v2/utils" - "github.com/turbot/steampipe/pkg/constants" - "github.com/turbot/steampipe/pkg/constants/runtime" - "github.com/turbot/steampipe/pkg/db/db_common" + "github.com/turbot/steampipe/v2/pkg/constants" + "github.com/turbot/steampipe/v2/pkg/constants/runtime" + "github.com/turbot/steampipe/v2/pkg/db/db_common" ) const ( diff --git a/pkg/db/db_client/db_client_execute.go b/pkg/db/db_client/db_client_execute.go index b2c274060..bbd4455a5 100644 --- a/pkg/db/db_client/db_client_execute.go +++ b/pkg/db/db_client/db_client_execute.go @@ -17,11 +17,11 @@ import ( pconstants "github.com/turbot/pipe-fittings/v2/constants" pqueryresult "github.com/turbot/pipe-fittings/v2/queryresult" "github.com/turbot/pipe-fittings/v2/utils" - "github.com/turbot/steampipe/pkg/constants" - "github.com/turbot/steampipe/pkg/db/db_common" - "github.com/turbot/steampipe/pkg/error_helpers" - "github.com/turbot/steampipe/pkg/query/queryresult" - "github.com/turbot/steampipe/pkg/statushooks" + "github.com/turbot/steampipe/v2/pkg/constants" + "github.com/turbot/steampipe/v2/pkg/db/db_common" + "github.com/turbot/steampipe/v2/pkg/error_helpers" + "github.com/turbot/steampipe/v2/pkg/query/queryresult" + "github.com/turbot/steampipe/v2/pkg/statushooks" "golang.org/x/text/language" "golang.org/x/text/message" ) diff --git a/pkg/db/db_client/db_client_execute_retry.go b/pkg/db/db_client/db_client_execute_retry.go index b7a8be86a..d3ed15c3d 100644 --- a/pkg/db/db_client/db_client_execute_retry.go +++ b/pkg/db/db_client/db_client_execute_retry.go @@ -9,10 +9,10 @@ import ( "github.com/jackc/pgx/v5" "github.com/sethvargo/go-retry" typehelpers "github.com/turbot/go-kit/types" - "github.com/turbot/steampipe/pkg/constants" - "github.com/turbot/steampipe/pkg/db/db_common" - "github.com/turbot/steampipe/pkg/statushooks" - "github.com/turbot/steampipe/pkg/steampipeconfig" + "github.com/turbot/steampipe/v2/pkg/constants" + "github.com/turbot/steampipe/v2/pkg/db/db_common" + "github.com/turbot/steampipe/v2/pkg/statushooks" + "github.com/turbot/steampipe/v2/pkg/steampipeconfig" ) // execute query - if it fails with a "relation not found" error, determine whether this is because the required schema diff --git a/pkg/db/db_client/db_client_search_path.go b/pkg/db/db_client/db_client_search_path.go index c8828752e..95100360d 100644 --- a/pkg/db/db_client/db_client_search_path.go +++ b/pkg/db/db_client/db_client_search_path.go @@ -10,7 +10,7 @@ import ( "github.com/spf13/viper" "github.com/turbot/go-kit/helpers" "github.com/turbot/pipe-fittings/v2/constants" - "github.com/turbot/steampipe/pkg/db/db_common" + "github.com/turbot/steampipe/v2/pkg/db/db_common" ) // SetRequiredSessionSearchPath implements Client diff --git a/pkg/db/db_client/db_client_session.go b/pkg/db/db_client/db_client_session.go index f74466218..435e0073d 100644 --- a/pkg/db/db_client/db_client_session.go +++ b/pkg/db/db_client/db_client_session.go @@ -8,7 +8,7 @@ import ( "github.com/jackc/pgx/v5/pgxpool" "github.com/spf13/viper" "github.com/turbot/pipe-fittings/v2/constants" - "github.com/turbot/steampipe/pkg/db/db_common" + "github.com/turbot/steampipe/v2/pkg/db/db_common" ) func (c *DbClient) AcquireManagementConnection(ctx context.Context) (*pgxpool.Conn, error) { diff --git a/pkg/db/db_common/appname.go b/pkg/db/db_common/appname.go index 5ef23957b..17ad73093 100644 --- a/pkg/db/db_common/appname.go +++ b/pkg/db/db_common/appname.go @@ -3,7 +3,7 @@ package db_common import ( "strings" - "github.com/turbot/steampipe/pkg/constants" + "github.com/turbot/steampipe/v2/pkg/constants" ) func IsClientAppName(appName string) bool { diff --git a/pkg/db/db_common/cache_control.go b/pkg/db/db_common/cache_control.go index 0444ff85a..f639401f2 100644 --- a/pkg/db/db_common/cache_control.go +++ b/pkg/db/db_common/cache_control.go @@ -6,7 +6,7 @@ import ( "time" "github.com/jackc/pgx/v5" - "github.com/turbot/steampipe/pkg/constants" + "github.com/turbot/steampipe/v2/pkg/constants" ) // SetCacheTtl set the cache ttl on the client diff --git a/pkg/db/db_common/client.go b/pkg/db/db_common/client.go index 37d836cee..5da304540 100644 --- a/pkg/db/db_common/client.go +++ b/pkg/db/db_common/client.go @@ -6,7 +6,7 @@ import ( "github.com/jackc/pgx/v5/pgconn" "github.com/jackc/pgx/v5/pgxpool" pqueryresult "github.com/turbot/pipe-fittings/v2/queryresult" - "github.com/turbot/steampipe/pkg/query/queryresult" + "github.com/turbot/steampipe/v2/pkg/query/queryresult" ) type Client interface { diff --git a/pkg/db/db_common/execute.go b/pkg/db/db_common/execute.go index 767e4e82c..4a7b761f7 100644 --- a/pkg/db/db_common/execute.go +++ b/pkg/db/db_common/execute.go @@ -4,7 +4,7 @@ import ( "context" "github.com/turbot/pipe-fittings/v2/utils" - "github.com/turbot/steampipe/pkg/query/queryresult" + "github.com/turbot/steampipe/v2/pkg/query/queryresult" ) // ExecuteQuery executes a single query. If shutdownAfterCompletion is true, shutdown the client after completion diff --git a/pkg/db/db_common/functions.go b/pkg/db/db_common/functions.go index 212bc5468..f33590462 100644 --- a/pkg/db/db_common/functions.go +++ b/pkg/db/db_common/functions.go @@ -1,6 +1,6 @@ package db_common -import "github.com/turbot/steampipe/pkg/constants" +import "github.com/turbot/steampipe/v2/pkg/constants" // Functions is a list of SQLFunction objects that are installed in the db 'steampipe_internal' schema startup var Functions = []SQLFunction{ diff --git a/pkg/db/db_common/init_result.go b/pkg/db/db_common/init_result.go index a59da170f..2319aba48 100644 --- a/pkg/db/db_common/init_result.go +++ b/pkg/db/db_common/init_result.go @@ -6,8 +6,8 @@ import ( "github.com/spf13/viper" pconstants "github.com/turbot/pipe-fittings/v2/constants" - "github.com/turbot/steampipe/pkg/constants" - "github.com/turbot/steampipe/pkg/error_helpers" + "github.com/turbot/steampipe/v2/pkg/constants" + "github.com/turbot/steampipe/v2/pkg/error_helpers" ) type InitResult struct { diff --git a/pkg/db/db_common/max_connections.go b/pkg/db/db_common/max_connections.go index 709e493a9..faa389196 100644 --- a/pkg/db/db_common/max_connections.go +++ b/pkg/db/db_common/max_connections.go @@ -3,7 +3,7 @@ package db_common import ( "github.com/spf13/viper" pconstants "github.com/turbot/pipe-fittings/v2/constants" - "github.com/turbot/steampipe/pkg/constants" + "github.com/turbot/steampipe/v2/pkg/constants" ) func MaxDbConnections() int { diff --git a/pkg/db/db_common/notification_cache.go b/pkg/db/db_common/notification_cache.go index a21a70b4a..2bf9cb8d1 100644 --- a/pkg/db/db_common/notification_cache.go +++ b/pkg/db/db_common/notification_cache.go @@ -10,8 +10,8 @@ import ( "github.com/jackc/pgx/v5" "github.com/jackc/pgx/v5/pgconn" - "github.com/turbot/steampipe/pkg/constants" - "github.com/turbot/steampipe/pkg/error_helpers" + "github.com/turbot/steampipe/v2/pkg/constants" + "github.com/turbot/steampipe/v2/pkg/error_helpers" ) type NotificationListener struct { diff --git a/pkg/db/db_common/schema.go b/pkg/db/db_common/schema.go index 6321ff8d6..bead95e3d 100644 --- a/pkg/db/db_common/schema.go +++ b/pkg/db/db_common/schema.go @@ -9,7 +9,7 @@ import ( "github.com/jackc/pgx/v5" typeHelpers "github.com/turbot/go-kit/types" "github.com/turbot/pipe-fittings/v2/utils" - "github.com/turbot/steampipe/pkg/constants" + "github.com/turbot/steampipe/v2/pkg/constants" ) type schemaRecord struct { diff --git a/pkg/db/db_common/search_path.go b/pkg/db/db_common/search_path.go index e8fba607b..caae26518 100644 --- a/pkg/db/db_common/search_path.go +++ b/pkg/db/db_common/search_path.go @@ -8,7 +8,7 @@ import ( "github.com/jackc/pgx/v5" "github.com/turbot/go-kit/helpers" - "github.com/turbot/steampipe/pkg/constants" + "github.com/turbot/steampipe/v2/pkg/constants" ) func EnsureInternalSchemaSuffix(searchPath []string) []string { diff --git a/pkg/db/db_common/session_system.go b/pkg/db/db_common/session_system.go index 6b885c2e9..166801483 100644 --- a/pkg/db/db_common/session_system.go +++ b/pkg/db/db_common/session_system.go @@ -7,8 +7,8 @@ import ( "github.com/jackc/pgx/v5" "github.com/turbot/steampipe-plugin-sdk/v5/sperr" - "github.com/turbot/steampipe/pkg/constants" - "github.com/turbot/steampipe/pkg/constants/runtime" + "github.com/turbot/steampipe/v2/pkg/constants" + "github.com/turbot/steampipe/v2/pkg/constants/runtime" ) // SystemClientExecutor is the executor function that is called within a transaction diff --git a/pkg/db/db_common/tls_config.go b/pkg/db/db_common/tls_config.go index 3bd4372ae..5103e7767 100644 --- a/pkg/db/db_common/tls_config.go +++ b/pkg/db/db_common/tls_config.go @@ -2,7 +2,7 @@ package db_common import ( "github.com/jackc/pgx/v5/pgconn" - "github.com/turbot/steampipe/pkg/db/sslio" + "github.com/turbot/steampipe/v2/pkg/db/sslio" ) func AddRootCertToConfig(config *pgconn.Config, certLocation string) error { diff --git a/pkg/db/db_common/wait_connection.go b/pkg/db/db_common/wait_connection.go index 3ad2ca0f6..f0d6f936b 100644 --- a/pkg/db/db_common/wait_connection.go +++ b/pkg/db/db_common/wait_connection.go @@ -11,9 +11,9 @@ import ( "github.com/pkg/errors" "github.com/sethvargo/go-retry" "github.com/turbot/pipe-fittings/v2/utils" - "github.com/turbot/steampipe/pkg/constants" - "github.com/turbot/steampipe/pkg/error_helpers" - "github.com/turbot/steampipe/pkg/statushooks" + "github.com/turbot/steampipe/v2/pkg/constants" + "github.com/turbot/steampipe/v2/pkg/error_helpers" + "github.com/turbot/steampipe/v2/pkg/statushooks" ) var ErrServiceInRecoveryMode = errors.New("service is in recovery mode") diff --git a/pkg/db/db_local/backup.go b/pkg/db/db_local/backup.go index 3c1755f35..bd5704241 100644 --- a/pkg/db/db_local/backup.go +++ b/pkg/db/db_local/backup.go @@ -17,9 +17,9 @@ import ( "github.com/turbot/go-kit/files" "github.com/turbot/pipe-fittings/v2/app_specific" putils "github.com/turbot/pipe-fittings/v2/utils" - "github.com/turbot/steampipe/pkg/constants" - "github.com/turbot/steampipe/pkg/error_helpers" - "github.com/turbot/steampipe/pkg/filepaths" + "github.com/turbot/steampipe/v2/pkg/constants" + "github.com/turbot/steampipe/v2/pkg/error_helpers" + "github.com/turbot/steampipe/v2/pkg/filepaths" ) var ( diff --git a/pkg/db/db_local/backup_test.go b/pkg/db/db_local/backup_test.go index 0e190d1c7..799816ebb 100644 --- a/pkg/db/db_local/backup_test.go +++ b/pkg/db/db_local/backup_test.go @@ -9,8 +9,8 @@ import ( filehelpers "github.com/turbot/go-kit/files" "github.com/turbot/pipe-fittings/v2/app_specific" - "github.com/turbot/steampipe/pkg/constants" - "github.com/turbot/steampipe/pkg/filepaths" + "github.com/turbot/steampipe/v2/pkg/constants" + "github.com/turbot/steampipe/v2/pkg/filepaths" ) func TestTrimBackups(t *testing.T) { diff --git a/pkg/db/db_local/create_connection.go b/pkg/db/db_local/create_connection.go index c2bbab21d..8826bfb11 100644 --- a/pkg/db/db_local/create_connection.go +++ b/pkg/db/db_local/create_connection.go @@ -13,11 +13,11 @@ import ( pconstants "github.com/turbot/pipe-fittings/v2/constants" putils "github.com/turbot/pipe-fittings/v2/utils" "github.com/turbot/steampipe-plugin-sdk/v5/sperr" - "github.com/turbot/steampipe/pkg/constants" - "github.com/turbot/steampipe/pkg/constants/runtime" - "github.com/turbot/steampipe/pkg/db/db_common" - "github.com/turbot/steampipe/pkg/filepaths" - "github.com/turbot/steampipe/pkg/statushooks" + "github.com/turbot/steampipe/v2/pkg/constants" + "github.com/turbot/steampipe/v2/pkg/constants/runtime" + "github.com/turbot/steampipe/v2/pkg/db/db_common" + "github.com/turbot/steampipe/v2/pkg/filepaths" + "github.com/turbot/steampipe/v2/pkg/statushooks" ) func getLocalSteampipeConnectionString(opts *CreateDbOptions) (string, error) { diff --git a/pkg/db/db_local/execute.go b/pkg/db/db_local/execute.go index 28612862d..13ed92960 100644 --- a/pkg/db/db_local/execute.go +++ b/pkg/db/db_local/execute.go @@ -6,8 +6,8 @@ import ( "github.com/jackc/pgx/v5" "github.com/jackc/pgx/v5/pgconn" - "github.com/turbot/steampipe/pkg/constants" - "github.com/turbot/steampipe/pkg/db/db_common" + "github.com/turbot/steampipe/v2/pkg/constants" + "github.com/turbot/steampipe/v2/pkg/db/db_common" ) func executeSqlAsRoot(ctx context.Context, statements ...string) ([]pgconn.CommandTag, error) { diff --git a/pkg/db/db_local/install.go b/pkg/db/db_local/install.go index 88a12dbb2..40f1fb477 100644 --- a/pkg/db/db_local/install.go +++ b/pkg/db/db_local/install.go @@ -17,11 +17,11 @@ import ( "github.com/turbot/pipe-fittings/v2/app_specific" pconstants "github.com/turbot/pipe-fittings/v2/constants" putils "github.com/turbot/pipe-fittings/v2/utils" - "github.com/turbot/steampipe/pkg/constants" - "github.com/turbot/steampipe/pkg/filepaths" - "github.com/turbot/steampipe/pkg/ociinstaller" - "github.com/turbot/steampipe/pkg/ociinstaller/versionfile" - "github.com/turbot/steampipe/pkg/statushooks" + "github.com/turbot/steampipe/v2/pkg/constants" + "github.com/turbot/steampipe/v2/pkg/filepaths" + "github.com/turbot/steampipe/v2/pkg/ociinstaller" + "github.com/turbot/steampipe/v2/pkg/ociinstaller/versionfile" + "github.com/turbot/steampipe/v2/pkg/statushooks" ) var ensureMux sync.Mutex diff --git a/pkg/db/db_local/internal.go b/pkg/db/db_local/internal.go index 560c42ea9..9ac490d66 100644 --- a/pkg/db/db_local/internal.go +++ b/pkg/db/db_local/internal.go @@ -9,11 +9,11 @@ import ( "github.com/jackc/pgx/v5" "github.com/turbot/pipe-fittings/v2/utils" "github.com/turbot/steampipe-plugin-sdk/v5/sperr" - "github.com/turbot/steampipe/pkg/constants" - "github.com/turbot/steampipe/pkg/db/db_common" - "github.com/turbot/steampipe/pkg/introspection" - "github.com/turbot/steampipe/pkg/statushooks" - "github.com/turbot/steampipe/pkg/steampipeconfig" + "github.com/turbot/steampipe/v2/pkg/constants" + "github.com/turbot/steampipe/v2/pkg/db/db_common" + "github.com/turbot/steampipe/v2/pkg/introspection" + "github.com/turbot/steampipe/v2/pkg/statushooks" + "github.com/turbot/steampipe/v2/pkg/steampipeconfig" ) // dropLegacyInternalSchema looks for a schema named 'internal' diff --git a/pkg/db/db_local/local_db_client.go b/pkg/db/db_local/local_db_client.go index 7fefaa574..d8e4a2012 100644 --- a/pkg/db/db_local/local_db_client.go +++ b/pkg/db/db_local/local_db_client.go @@ -10,10 +10,10 @@ import ( pconstants "github.com/turbot/pipe-fittings/v2/constants" "github.com/turbot/pipe-fittings/v2/error_helpers" "github.com/turbot/pipe-fittings/v2/utils" - "github.com/turbot/steampipe/pkg/constants" - "github.com/turbot/steampipe/pkg/db/db_client" - "github.com/turbot/steampipe/pkg/db/db_common" - pb "github.com/turbot/steampipe/pkg/pluginmanager_service/grpc/proto" + "github.com/turbot/steampipe/v2/pkg/constants" + "github.com/turbot/steampipe/v2/pkg/db/db_client" + "github.com/turbot/steampipe/v2/pkg/db/db_common" + pb "github.com/turbot/steampipe/v2/pkg/pluginmanager_service/grpc/proto" ) // LocalDbClient wraps over DbClient diff --git a/pkg/db/db_local/logs.go b/pkg/db/db_local/logs.go index 464306d3d..7aa358b8c 100644 --- a/pkg/db/db_local/logs.go +++ b/pkg/db/db_local/logs.go @@ -6,7 +6,7 @@ import ( "path/filepath" "time" - "github.com/turbot/steampipe/pkg/filepaths" + "github.com/turbot/steampipe/v2/pkg/filepaths" ) const logRetentionDays = 7 diff --git a/pkg/db/db_local/notify.go b/pkg/db/db_local/notify.go index 39d3afdc6..592c74b25 100644 --- a/pkg/db/db_local/notify.go +++ b/pkg/db/db_local/notify.go @@ -8,7 +8,7 @@ import ( "github.com/jackc/pgx/v5" "github.com/turbot/steampipe-plugin-sdk/v5/sperr" - "github.com/turbot/steampipe/pkg/constants" + "github.com/turbot/steampipe/v2/pkg/constants" ) // SendPostgresNotification send a postgres notification that the schema has chganged diff --git a/pkg/db/db_local/password.go b/pkg/db/db_local/password.go index b471cd3df..686693cb9 100644 --- a/pkg/db/db_local/password.go +++ b/pkg/db/db_local/password.go @@ -8,7 +8,7 @@ import ( "github.com/google/uuid" filehelpers "github.com/turbot/go-kit/files" "github.com/turbot/pipe-fittings/v2/utils" - "github.com/turbot/steampipe/pkg/filepaths" + "github.com/turbot/steampipe/v2/pkg/filepaths" ) // Passwords :: structure for working with DB passwords diff --git a/pkg/db/db_local/refresh_functions_test.go b/pkg/db/db_local/refresh_functions_test.go index 761caf6ad..4187c1f66 100644 --- a/pkg/db/db_local/refresh_functions_test.go +++ b/pkg/db/db_local/refresh_functions_test.go @@ -7,7 +7,7 @@ import ( "testing" "github.com/turbot/pipe-fittings/v2/app_specific" - "github.com/turbot/steampipe/pkg/constants" + "github.com/turbot/steampipe/v2/pkg/constants" ) // test used for debug purposes to replicate `tuple concurrently updated` DB error diff --git a/pkg/db/db_local/running_info.go b/pkg/db/db_local/running_info.go index df67662d1..2d512ae13 100644 --- a/pkg/db/db_local/running_info.go +++ b/pkg/db/db_local/running_info.go @@ -12,8 +12,8 @@ import ( filehelpers "github.com/turbot/go-kit/files" "github.com/turbot/go-kit/helpers" putils "github.com/turbot/pipe-fittings/v2/utils" - "github.com/turbot/steampipe/pkg/constants" - "github.com/turbot/steampipe/pkg/filepaths" + "github.com/turbot/steampipe/v2/pkg/constants" + "github.com/turbot/steampipe/v2/pkg/filepaths" ) const RunningDBStructVersion = 20220411 diff --git a/pkg/db/db_local/search_path.go b/pkg/db/db_local/search_path.go index f39576026..276037fbe 100644 --- a/pkg/db/db_local/search_path.go +++ b/pkg/db/db_local/search_path.go @@ -10,9 +10,9 @@ import ( "github.com/jackc/pgx/v5/pgxpool" "github.com/spf13/viper" "github.com/turbot/pipe-fittings/v2/modconfig" - "github.com/turbot/steampipe/pkg/constants" - "github.com/turbot/steampipe/pkg/db/db_common" - "github.com/turbot/steampipe/pkg/steampipeconfig" + "github.com/turbot/steampipe/v2/pkg/constants" + "github.com/turbot/steampipe/v2/pkg/db/db_common" + "github.com/turbot/steampipe/v2/pkg/steampipeconfig" ) func SetUserSearchPath(ctx context.Context, pool *pgxpool.Pool) ([]string, error) { diff --git a/pkg/db/db_local/server_settings.go b/pkg/db/db_local/server_settings.go index 46a58db54..138a78cf3 100644 --- a/pkg/db/db_local/server_settings.go +++ b/pkg/db/db_local/server_settings.go @@ -8,9 +8,9 @@ import ( "github.com/jackc/pgx/v5" "github.com/spf13/viper" pconstants "github.com/turbot/pipe-fittings/v2/constants" - "github.com/turbot/steampipe/pkg/constants" - "github.com/turbot/steampipe/pkg/db/db_common" - "github.com/turbot/steampipe/pkg/serversettings" + "github.com/turbot/steampipe/v2/pkg/constants" + "github.com/turbot/steampipe/v2/pkg/db/db_common" + "github.com/turbot/steampipe/v2/pkg/serversettings" ) // setupServerSettingsTable creates a new read-only table with information in the current diff --git a/pkg/db/db_local/service.go b/pkg/db/db_local/service.go index 65c539fb3..e260c078d 100644 --- a/pkg/db/db_local/service.go +++ b/pkg/db/db_local/service.go @@ -10,7 +10,7 @@ import ( filehelpers "github.com/turbot/go-kit/files" "github.com/turbot/pipe-fittings/v2/constants" "github.com/turbot/pipe-fittings/v2/utils" - "github.com/turbot/steampipe/pkg/filepaths" + "github.com/turbot/steampipe/v2/pkg/filepaths" ) // GetState checks that the database instance is running and returns its details diff --git a/pkg/db/db_local/ssl.go b/pkg/db/db_local/ssl.go index dc6b7f799..3ddd688a6 100644 --- a/pkg/db/db_local/ssl.go +++ b/pkg/db/db_local/ssl.go @@ -19,8 +19,8 @@ import ( "github.com/turbot/pipe-fittings/v2/constants" "github.com/turbot/pipe-fittings/v2/utils" "github.com/turbot/steampipe-plugin-sdk/v5/sperr" - "github.com/turbot/steampipe/pkg/db/sslio" - "github.com/turbot/steampipe/pkg/filepaths" + "github.com/turbot/steampipe/v2/pkg/db/sslio" + "github.com/turbot/steampipe/v2/pkg/filepaths" ) const ( diff --git a/pkg/db/db_local/start_services.go b/pkg/db/db_local/start_services.go index 955a6228e..6d9beb511 100644 --- a/pkg/db/db_local/start_services.go +++ b/pkg/db/db_local/start_services.go @@ -21,12 +21,12 @@ import ( perror_helpers "github.com/turbot/pipe-fittings/v2/error_helpers" putils "github.com/turbot/pipe-fittings/v2/utils" "github.com/turbot/steampipe-plugin-sdk/v5/sperr" - "github.com/turbot/steampipe/pkg/constants" - "github.com/turbot/steampipe/pkg/db/db_common" - "github.com/turbot/steampipe/pkg/error_helpers" - "github.com/turbot/steampipe/pkg/filepaths" - "github.com/turbot/steampipe/pkg/pluginmanager" - "github.com/turbot/steampipe/pkg/statushooks" + "github.com/turbot/steampipe/v2/pkg/constants" + "github.com/turbot/steampipe/v2/pkg/db/db_common" + "github.com/turbot/steampipe/v2/pkg/error_helpers" + "github.com/turbot/steampipe/v2/pkg/filepaths" + "github.com/turbot/steampipe/v2/pkg/pluginmanager" + "github.com/turbot/steampipe/v2/pkg/statushooks" ) // StartResult is a pseudoEnum for outcomes of StartNewInstance diff --git a/pkg/db/db_local/stop_services.go b/pkg/db/db_local/stop_services.go index 3afc51cd7..e02adc2ef 100644 --- a/pkg/db/db_local/stop_services.go +++ b/pkg/db/db_local/stop_services.go @@ -11,14 +11,14 @@ import ( psutils "github.com/shirou/gopsutil/process" putils "github.com/turbot/pipe-fittings/v2/utils" - "github.com/turbot/steampipe/pkg/constants" - "github.com/turbot/steampipe/pkg/constants/runtime" - "github.com/turbot/steampipe/pkg/db/db_common" - "github.com/turbot/steampipe/pkg/error_helpers" - "github.com/turbot/steampipe/pkg/filepaths" - "github.com/turbot/steampipe/pkg/pluginmanager" - "github.com/turbot/steampipe/pkg/statushooks" - "github.com/turbot/steampipe/pkg/utils" + "github.com/turbot/steampipe/v2/pkg/constants" + "github.com/turbot/steampipe/v2/pkg/constants/runtime" + "github.com/turbot/steampipe/v2/pkg/db/db_common" + "github.com/turbot/steampipe/v2/pkg/error_helpers" + "github.com/turbot/steampipe/v2/pkg/filepaths" + "github.com/turbot/steampipe/v2/pkg/pluginmanager" + "github.com/turbot/steampipe/v2/pkg/statushooks" + "github.com/turbot/steampipe/v2/pkg/utils" ) // StopStatus is a pseudoEnum for service stop result diff --git a/pkg/display/timing.go b/pkg/display/timing.go index 5869d2f33..5c55214e6 100644 --- a/pkg/display/timing.go +++ b/pkg/display/timing.go @@ -9,7 +9,7 @@ import ( "github.com/spf13/viper" pconstants "github.com/turbot/pipe-fittings/v2/constants" - "github.com/turbot/steampipe/pkg/query/queryresult" + "github.com/turbot/steampipe/v2/pkg/query/queryresult" "golang.org/x/text/language" "golang.org/x/text/message" ) diff --git a/pkg/error_helpers/postgres.go b/pkg/error_helpers/postgres.go index 563aebb97..16f85fc10 100644 --- a/pkg/error_helpers/postgres.go +++ b/pkg/error_helpers/postgres.go @@ -3,13 +3,14 @@ package error_helpers import ( "errors" "fmt" + "github.com/jackc/pgconn" ) func DecodePgError(err error) error { var pgError *pgconn.PgError if errors.As(err, &pgError) { - return fmt.Errorf(pgError.Message) + return fmt.Errorf("%s", pgError.Message) } return err } diff --git a/pkg/error_helpers/utils.go b/pkg/error_helpers/utils.go index a0f28f890..77135d885 100644 --- a/pkg/error_helpers/utils.go +++ b/pkg/error_helpers/utils.go @@ -13,7 +13,7 @@ import ( "github.com/shiena/ansicolor" "github.com/spf13/viper" pconstants "github.com/turbot/pipe-fittings/v2/constants" - "github.com/turbot/steampipe/pkg/statushooks" + "github.com/turbot/steampipe/v2/pkg/statushooks" ) func init() { @@ -82,7 +82,7 @@ func TransformErrorToSteampipe(err error) error { errString = strings.TrimPrefix(errString, "rpc error: code = Unknown desc =") } } - return fmt.Errorf(strings.TrimSpace(errString)) + return fmt.Errorf("%s", strings.TrimSpace(errString)) } // HandleCancelError modifies a context.Canceled error into a readable error that can @@ -138,7 +138,7 @@ func CombineErrorsWithPrefix(prefix string, errors ...error) error { combinedErrorString[e.Error()] = struct{}{} } - return fmt.Errorf(strings.Join(maps.Keys(combinedErrorString), "\n\t")) + return fmt.Errorf("%s", strings.Join(maps.Keys(combinedErrorString), "\n\t")) } func allErrorsNil(errors ...error) bool { diff --git a/pkg/export/manager.go b/pkg/export/manager.go index 6626304fa..0dae1d0d2 100644 --- a/pkg/export/manager.go +++ b/pkg/export/manager.go @@ -8,8 +8,8 @@ import ( "github.com/turbot/pipe-fittings/v2/utils" "github.com/turbot/steampipe-plugin-sdk/v5/sperr" - "github.com/turbot/steampipe/pkg/error_helpers" - "github.com/turbot/steampipe/pkg/statushooks" + "github.com/turbot/steampipe/v2/pkg/error_helpers" + "github.com/turbot/steampipe/v2/pkg/statushooks" "golang.org/x/exp/maps" "golang.org/x/exp/slices" ) diff --git a/pkg/export/manager_test.go b/pkg/export/manager_test.go index 385d1c2f7..f921756ba 100644 --- a/pkg/export/manager_test.go +++ b/pkg/export/manager_test.go @@ -4,7 +4,7 @@ import ( "context" "testing" - "github.com/turbot/steampipe/pkg/constants" + "github.com/turbot/steampipe/v2/pkg/constants" ) type testExporter struct { diff --git a/pkg/export/snapshot_exporter.go b/pkg/export/snapshot_exporter.go index 2375849a2..ab0147838 100644 --- a/pkg/export/snapshot_exporter.go +++ b/pkg/export/snapshot_exporter.go @@ -6,7 +6,7 @@ import ( "strings" "github.com/turbot/pipe-fittings/v2/steampipeconfig" - "github.com/turbot/steampipe/pkg/constants" + "github.com/turbot/steampipe/v2/pkg/constants" ) type SnapshotExporter struct { diff --git a/pkg/filepaths/db_path.go b/pkg/filepaths/db_path.go index 65e358296..288f8e845 100644 --- a/pkg/filepaths/db_path.go +++ b/pkg/filepaths/db_path.go @@ -4,9 +4,9 @@ import ( "os" "path/filepath" - "github.com/turbot/steampipe/pkg/constants" - "github.com/turbot/steampipe/pkg/db/platform" - "github.com/turbot/steampipe/pkg/error_helpers" + "github.com/turbot/steampipe/v2/pkg/constants" + "github.com/turbot/steampipe/v2/pkg/db/platform" + "github.com/turbot/steampipe/v2/pkg/error_helpers" ) func ServiceExecutableRelativeLocation() string { diff --git a/pkg/filepaths/steampipe.go b/pkg/filepaths/steampipe.go index bf6b7414a..4add8fce1 100644 --- a/pkg/filepaths/steampipe.go +++ b/pkg/filepaths/steampipe.go @@ -7,8 +7,8 @@ import ( filehelpers "github.com/turbot/go-kit/files" "github.com/turbot/pipe-fittings/v2/app_specific" - "github.com/turbot/steampipe/pkg/constants" - "github.com/turbot/steampipe/pkg/error_helpers" + "github.com/turbot/steampipe/v2/pkg/constants" + "github.com/turbot/steampipe/v2/pkg/error_helpers" ) // Constants for Config diff --git a/pkg/initialisation/cloud_metadata.go b/pkg/initialisation/cloud_metadata.go index b31babba9..df34019de 100644 --- a/pkg/initialisation/cloud_metadata.go +++ b/pkg/initialisation/cloud_metadata.go @@ -8,7 +8,7 @@ import ( "github.com/turbot/pipe-fittings/v2/constants" "github.com/turbot/pipe-fittings/v2/pipes" "github.com/turbot/pipe-fittings/v2/steampipeconfig" - "github.com/turbot/steampipe/pkg/error_helpers" + "github.com/turbot/steampipe/v2/pkg/error_helpers" ) func getPipesMetadata(ctx context.Context) (*steampipeconfig.PipesMetadata, error) { diff --git a/pkg/initialisation/init_data.go b/pkg/initialisation/init_data.go index d97c88451..139b049a3 100644 --- a/pkg/initialisation/init_data.go +++ b/pkg/initialisation/init_data.go @@ -12,12 +12,12 @@ import ( "github.com/turbot/pipe-fittings/v2/error_helpers" "github.com/turbot/pipe-fittings/v2/steampipeconfig" "github.com/turbot/steampipe-plugin-sdk/v5/telemetry" - "github.com/turbot/steampipe/pkg/constants" - "github.com/turbot/steampipe/pkg/db/db_client" - "github.com/turbot/steampipe/pkg/db/db_common" - "github.com/turbot/steampipe/pkg/db/db_local" - "github.com/turbot/steampipe/pkg/export" - "github.com/turbot/steampipe/pkg/statushooks" + "github.com/turbot/steampipe/v2/pkg/constants" + "github.com/turbot/steampipe/v2/pkg/db/db_client" + "github.com/turbot/steampipe/v2/pkg/db/db_common" + "github.com/turbot/steampipe/v2/pkg/db/db_local" + "github.com/turbot/steampipe/v2/pkg/export" + "github.com/turbot/steampipe/v2/pkg/statushooks" ) type InitData struct { diff --git a/pkg/installationstate/state.go b/pkg/installationstate/state.go index cd292c5e9..7b4a69bf8 100644 --- a/pkg/installationstate/state.go +++ b/pkg/installationstate/state.go @@ -9,7 +9,7 @@ import ( "github.com/google/uuid" "github.com/turbot/go-kit/files" - "github.com/turbot/steampipe/pkg/filepaths" + "github.com/turbot/steampipe/v2/pkg/filepaths" ) const StateStructVersion = 20220411 diff --git a/pkg/interactive/interactive_client.go b/pkg/interactive/interactive_client.go index 97a7f1349..b13d3ab97 100644 --- a/pkg/interactive/interactive_client.go +++ b/pkg/interactive/interactive_client.go @@ -23,16 +23,16 @@ import ( "github.com/turbot/pipe-fittings/v2/modconfig" "github.com/turbot/pipe-fittings/v2/querydisplay" "github.com/turbot/pipe-fittings/v2/utils" - "github.com/turbot/steampipe/pkg/cmdconfig" - "github.com/turbot/steampipe/pkg/connection_sync" - "github.com/turbot/steampipe/pkg/constants" - "github.com/turbot/steampipe/pkg/db/db_common" - "github.com/turbot/steampipe/pkg/error_helpers" - "github.com/turbot/steampipe/pkg/interactive/metaquery" - "github.com/turbot/steampipe/pkg/query" - "github.com/turbot/steampipe/pkg/query/queryhistory" - "github.com/turbot/steampipe/pkg/statushooks" - "github.com/turbot/steampipe/pkg/steampipeconfig" + "github.com/turbot/steampipe/v2/pkg/cmdconfig" + "github.com/turbot/steampipe/v2/pkg/connection_sync" + "github.com/turbot/steampipe/v2/pkg/constants" + "github.com/turbot/steampipe/v2/pkg/db/db_common" + "github.com/turbot/steampipe/v2/pkg/error_helpers" + "github.com/turbot/steampipe/v2/pkg/interactive/metaquery" + "github.com/turbot/steampipe/v2/pkg/query" + "github.com/turbot/steampipe/v2/pkg/query/queryhistory" + "github.com/turbot/steampipe/v2/pkg/statushooks" + "github.com/turbot/steampipe/v2/pkg/steampipeconfig" ) type AfterPromptCloseAction int diff --git a/pkg/interactive/interactive_client_autocomplete.go b/pkg/interactive/interactive_client_autocomplete.go index 0044bbdbd..62d0f5aad 100644 --- a/pkg/interactive/interactive_client_autocomplete.go +++ b/pkg/interactive/interactive_client_autocomplete.go @@ -9,9 +9,9 @@ import ( "github.com/c-bata/go-prompt" "github.com/turbot/go-kit/helpers" "github.com/turbot/pipe-fittings/v2/utils" - "github.com/turbot/steampipe/pkg/constants" - "github.com/turbot/steampipe/pkg/db/db_common" - "github.com/turbot/steampipe/pkg/steampipeconfig" + "github.com/turbot/steampipe/v2/pkg/constants" + "github.com/turbot/steampipe/v2/pkg/db/db_common" + "github.com/turbot/steampipe/v2/pkg/steampipeconfig" ) func (c *InteractiveClient) initialiseSuggestions(ctx context.Context) error { diff --git a/pkg/interactive/interactive_client_init.go b/pkg/interactive/interactive_client_init.go index 06128b9b3..4e830c182 100644 --- a/pkg/interactive/interactive_client_init.go +++ b/pkg/interactive/interactive_client_init.go @@ -7,9 +7,9 @@ import ( "time" "github.com/turbot/go-kit/helpers" - "github.com/turbot/steampipe/pkg/db/db_common" - "github.com/turbot/steampipe/pkg/error_helpers" - "github.com/turbot/steampipe/pkg/statushooks" + "github.com/turbot/steampipe/v2/pkg/db/db_common" + "github.com/turbot/steampipe/v2/pkg/error_helpers" + "github.com/turbot/steampipe/v2/pkg/statushooks" ) // init data has arrived, handle any errors/warnings/messages diff --git a/pkg/interactive/metaquery/definitions.go b/pkg/interactive/metaquery/definitions.go index 16438a262..d49f22a4d 100644 --- a/pkg/interactive/metaquery/definitions.go +++ b/pkg/interactive/metaquery/definitions.go @@ -2,7 +2,7 @@ package metaquery import ( pconstants "github.com/turbot/pipe-fittings/v2/constants" - "github.com/turbot/steampipe/pkg/constants" + "github.com/turbot/steampipe/v2/pkg/constants" ) type metaQueryArg struct { diff --git a/pkg/interactive/metaquery/handler_cache.go b/pkg/interactive/metaquery/handler_cache.go index 8ca40860f..8959dc894 100644 --- a/pkg/interactive/metaquery/handler_cache.go +++ b/pkg/interactive/metaquery/handler_cache.go @@ -11,7 +11,7 @@ import ( "github.com/spf13/viper" pconstants "github.com/turbot/pipe-fittings/v2/constants" "github.com/turbot/steampipe-plugin-sdk/v5/sperr" - "github.com/turbot/steampipe/pkg/db/db_common" + "github.com/turbot/steampipe/v2/pkg/db/db_common" ) // controls the cache in the connected FDW diff --git a/pkg/interactive/metaquery/handler_help.go b/pkg/interactive/metaquery/handler_help.go index 896f861ae..69ebec567 100644 --- a/pkg/interactive/metaquery/handler_help.go +++ b/pkg/interactive/metaquery/handler_help.go @@ -8,7 +8,7 @@ import ( "strings" pconstants "github.com/turbot/pipe-fittings/v2/constants" - "github.com/turbot/steampipe/pkg/constants" + "github.com/turbot/steampipe/v2/pkg/constants" ) // .help diff --git a/pkg/interactive/metaquery/handler_input.go b/pkg/interactive/metaquery/handler_input.go index 2395cf7be..02ad5bb8a 100644 --- a/pkg/interactive/metaquery/handler_input.go +++ b/pkg/interactive/metaquery/handler_input.go @@ -4,8 +4,8 @@ import ( "context" "github.com/c-bata/go-prompt" - "github.com/turbot/steampipe/pkg/db/db_common" - "github.com/turbot/steampipe/pkg/steampipeconfig" + "github.com/turbot/steampipe/v2/pkg/db/db_common" + "github.com/turbot/steampipe/v2/pkg/steampipeconfig" ) type ConnectionStateGetter func(context.Context) (steampipeconfig.ConnectionStateMap, error) diff --git a/pkg/interactive/metaquery/handler_inspect.go b/pkg/interactive/metaquery/handler_inspect.go index b03770b25..68470499c 100644 --- a/pkg/interactive/metaquery/handler_inspect.go +++ b/pkg/interactive/metaquery/handler_inspect.go @@ -12,9 +12,9 @@ import ( pconstants "github.com/turbot/pipe-fittings/v2/constants" "github.com/turbot/pipe-fittings/v2/querydisplay" "github.com/turbot/steampipe-plugin-sdk/v5/sperr" - "github.com/turbot/steampipe/pkg/constants" - "github.com/turbot/steampipe/pkg/error_helpers" - "github.com/turbot/steampipe/pkg/steampipeconfig" + "github.com/turbot/steampipe/v2/pkg/constants" + "github.com/turbot/steampipe/v2/pkg/error_helpers" + "github.com/turbot/steampipe/v2/pkg/steampipeconfig" ) // inspect diff --git a/pkg/interactive/metaquery/handler_search_path.go b/pkg/interactive/metaquery/handler_search_path.go index 486bfcb83..74bb958f3 100644 --- a/pkg/interactive/metaquery/handler_search_path.go +++ b/pkg/interactive/metaquery/handler_search_path.go @@ -8,7 +8,7 @@ import ( "github.com/turbot/go-kit/helpers" pconstants "github.com/turbot/pipe-fittings/v2/constants" "github.com/turbot/pipe-fittings/v2/querydisplay" - "github.com/turbot/steampipe/pkg/constants" + "github.com/turbot/steampipe/v2/pkg/constants" ) func setOrGetSearchPath(ctx context.Context, input *HandlerInput) error { diff --git a/pkg/interactive/metaquery/handlers.go b/pkg/interactive/metaquery/handlers.go index 035394cee..200ca83e0 100644 --- a/pkg/interactive/metaquery/handlers.go +++ b/pkg/interactive/metaquery/handlers.go @@ -7,8 +7,8 @@ import ( typeHelpers "github.com/turbot/go-kit/types" pconstants "github.com/turbot/pipe-fittings/v2/constants" - "github.com/turbot/steampipe/pkg/cmdconfig" - "github.com/turbot/steampipe/pkg/constants" + "github.com/turbot/steampipe/v2/pkg/cmdconfig" + "github.com/turbot/steampipe/v2/pkg/constants" "golang.org/x/exp/maps" ) diff --git a/pkg/interactive/metaquery/validators.go b/pkg/interactive/metaquery/validators.go index 579cc3c8d..50d84a9eb 100644 --- a/pkg/interactive/metaquery/validators.go +++ b/pkg/interactive/metaquery/validators.go @@ -7,7 +7,7 @@ import ( pconstants "github.com/turbot/pipe-fittings/v2/constants" "github.com/turbot/pipe-fittings/v2/utils" - "github.com/turbot/steampipe/pkg/cmdconfig" + "github.com/turbot/steampipe/v2/pkg/cmdconfig" "golang.org/x/text/cases" "golang.org/x/text/language" ) diff --git a/pkg/interactive/run.go b/pkg/interactive/run.go index db8c44d61..9e0e1ed1d 100644 --- a/pkg/interactive/run.go +++ b/pkg/interactive/run.go @@ -3,11 +3,11 @@ package interactive import ( "context" - "github.com/turbot/steampipe/pkg/constants" - "github.com/turbot/steampipe/pkg/db/db_local" - "github.com/turbot/steampipe/pkg/error_helpers" - "github.com/turbot/steampipe/pkg/query" - "github.com/turbot/steampipe/pkg/query/queryresult" + "github.com/turbot/steampipe/v2/pkg/constants" + "github.com/turbot/steampipe/v2/pkg/db/db_local" + "github.com/turbot/steampipe/v2/pkg/error_helpers" + "github.com/turbot/steampipe/v2/pkg/query" + "github.com/turbot/steampipe/v2/pkg/query/queryresult" ) type RunInteractivePromptResult struct { diff --git a/pkg/introspection/connection_table_sql.go b/pkg/introspection/connection_table_sql.go index 664cb42fc..ea28f2ecc 100644 --- a/pkg/introspection/connection_table_sql.go +++ b/pkg/introspection/connection_table_sql.go @@ -4,9 +4,9 @@ import ( "fmt" "github.com/turbot/pipe-fittings/v2/modconfig" - "github.com/turbot/steampipe/pkg/constants" - "github.com/turbot/steampipe/pkg/db/db_common" - "github.com/turbot/steampipe/pkg/steampipeconfig" + "github.com/turbot/steampipe/v2/pkg/constants" + "github.com/turbot/steampipe/v2/pkg/db/db_common" + "github.com/turbot/steampipe/v2/pkg/steampipeconfig" "golang.org/x/exp/maps" ) diff --git a/pkg/introspection/plugin_column_table_sql.go b/pkg/introspection/plugin_column_table_sql.go index d06c154c8..7f74301f8 100644 --- a/pkg/introspection/plugin_column_table_sql.go +++ b/pkg/introspection/plugin_column_table_sql.go @@ -6,8 +6,8 @@ import ( "strings" "github.com/turbot/steampipe-plugin-sdk/v5/grpc/proto" - "github.com/turbot/steampipe/pkg/constants" - "github.com/turbot/steampipe/pkg/db/db_common" + "github.com/turbot/steampipe/v2/pkg/constants" + "github.com/turbot/steampipe/v2/pkg/db/db_common" ) func GetPluginColumnTableCreateSql() db_common.QueryWithArgs { diff --git a/pkg/introspection/plugin_table_sql.go b/pkg/introspection/plugin_table_sql.go index af16503c4..0f1f64777 100644 --- a/pkg/introspection/plugin_table_sql.go +++ b/pkg/introspection/plugin_table_sql.go @@ -4,8 +4,8 @@ import ( "fmt" "github.com/turbot/pipe-fittings/v2/plugin" - "github.com/turbot/steampipe/pkg/constants" - "github.com/turbot/steampipe/pkg/db/db_common" + "github.com/turbot/steampipe/v2/pkg/constants" + "github.com/turbot/steampipe/v2/pkg/db/db_common" ) func GetPluginTableCreateSql() db_common.QueryWithArgs { diff --git a/pkg/introspection/rate_limiters_table_sql.go b/pkg/introspection/rate_limiters_table_sql.go index 291f65b6d..ba7570854 100644 --- a/pkg/introspection/rate_limiters_table_sql.go +++ b/pkg/introspection/rate_limiters_table_sql.go @@ -4,8 +4,8 @@ import ( "fmt" "github.com/turbot/pipe-fittings/v2/plugin" - "github.com/turbot/steampipe/pkg/constants" - "github.com/turbot/steampipe/pkg/db/db_common" + "github.com/turbot/steampipe/v2/pkg/constants" + "github.com/turbot/steampipe/v2/pkg/db/db_common" ) func GetRateLimiterTableCreateSql() db_common.QueryWithArgs { diff --git a/pkg/ociinstaller/asset_downloader.go b/pkg/ociinstaller/asset_downloader.go index 48865a4fb..a913ce9ad 100644 --- a/pkg/ociinstaller/asset_downloader.go +++ b/pkg/ociinstaller/asset_downloader.go @@ -3,7 +3,7 @@ package ociinstaller import ( ocispec "github.com/opencontainers/image-spec/specs-go/v1" "github.com/turbot/pipe-fittings/v2/ociinstaller" - "github.com/turbot/steampipe/pkg/constants" + "github.com/turbot/steampipe/v2/pkg/constants" ) type assetsDownloader struct { diff --git a/pkg/ociinstaller/db.go b/pkg/ociinstaller/db.go index 889a02565..5391d12da 100644 --- a/pkg/ociinstaller/db.go +++ b/pkg/ociinstaller/db.go @@ -8,8 +8,8 @@ import ( "github.com/turbot/pipe-fittings/v2/ociinstaller" "github.com/turbot/pipe-fittings/v2/utils" - "github.com/turbot/steampipe/pkg/constants" - versionfile "github.com/turbot/steampipe/pkg/ociinstaller/versionfile" + "github.com/turbot/steampipe/v2/pkg/constants" + versionfile "github.com/turbot/steampipe/v2/pkg/ociinstaller/versionfile" ) // InstallDB :: Install Postgres files fom OCI image diff --git a/pkg/ociinstaller/db_downloader.go b/pkg/ociinstaller/db_downloader.go index ca2da9130..8d63500bf 100644 --- a/pkg/ociinstaller/db_downloader.go +++ b/pkg/ociinstaller/db_downloader.go @@ -5,7 +5,7 @@ import ( ocispec "github.com/opencontainers/image-spec/specs-go/v1" "github.com/turbot/pipe-fittings/v2/ociinstaller" - "github.com/turbot/steampipe/pkg/constants" + "github.com/turbot/steampipe/v2/pkg/constants" ) type dbDownloader struct { diff --git a/pkg/ociinstaller/fdw.go b/pkg/ociinstaller/fdw.go index 3d9631a18..37d501fef 100644 --- a/pkg/ociinstaller/fdw.go +++ b/pkg/ociinstaller/fdw.go @@ -10,9 +10,9 @@ import ( "github.com/turbot/pipe-fittings/v2/ociinstaller" putils "github.com/turbot/pipe-fittings/v2/utils" - "github.com/turbot/steampipe/pkg/constants" - "github.com/turbot/steampipe/pkg/filepaths" - "github.com/turbot/steampipe/pkg/ociinstaller/versionfile" + "github.com/turbot/steampipe/v2/pkg/constants" + "github.com/turbot/steampipe/v2/pkg/filepaths" + "github.com/turbot/steampipe/v2/pkg/ociinstaller/versionfile" ) // InstallFdw installs the Steampipe Postgres foreign data wrapper from an OCI image diff --git a/pkg/ociinstaller/fdw_downloader.go b/pkg/ociinstaller/fdw_downloader.go index 2bd5d6e41..84eb103e6 100644 --- a/pkg/ociinstaller/fdw_downloader.go +++ b/pkg/ociinstaller/fdw_downloader.go @@ -5,7 +5,7 @@ import ( ocispec "github.com/opencontainers/image-spec/specs-go/v1" "github.com/turbot/pipe-fittings/v2/ociinstaller" - "github.com/turbot/steampipe/pkg/constants" + "github.com/turbot/steampipe/v2/pkg/constants" ) type fdwDownloader struct { diff --git a/pkg/ociinstaller/versionfile/db_version_file.go b/pkg/ociinstaller/versionfile/db_version_file.go index 1e03773cb..d0ec49090 100644 --- a/pkg/ociinstaller/versionfile/db_version_file.go +++ b/pkg/ociinstaller/versionfile/db_version_file.go @@ -7,7 +7,7 @@ import ( filehelpers "github.com/turbot/go-kit/files" "github.com/turbot/pipe-fittings/v2/versionfile" - "github.com/turbot/steampipe/pkg/filepaths" + "github.com/turbot/steampipe/v2/pkg/filepaths" ) const DatabaseStructVersion = 20220411 diff --git a/pkg/pluginmanager/lifecycle.go b/pkg/pluginmanager/lifecycle.go index 1e82466a5..25f82db31 100644 --- a/pkg/pluginmanager/lifecycle.go +++ b/pkg/pluginmanager/lifecycle.go @@ -16,9 +16,9 @@ import ( "github.com/turbot/pipe-fittings/v2/constants" "github.com/turbot/steampipe-plugin-sdk/v5/logging" "github.com/turbot/steampipe-plugin-sdk/v5/sperr" - "github.com/turbot/steampipe/pkg/pluginmanager_service/grpc" - pb "github.com/turbot/steampipe/pkg/pluginmanager_service/grpc/proto" - pluginshared "github.com/turbot/steampipe/pkg/pluginmanager_service/grpc/shared" + "github.com/turbot/steampipe/v2/pkg/pluginmanager_service/grpc" + pb "github.com/turbot/steampipe/v2/pkg/pluginmanager_service/grpc/proto" + pluginshared "github.com/turbot/steampipe/v2/pkg/pluginmanager_service/grpc/shared" ) // StartNewInstance loads the plugin manager state, stops any previous instance and instantiates a new plugin manager diff --git a/pkg/pluginmanager/plugin_manager_client.go b/pkg/pluginmanager/plugin_manager_client.go index 887b02785..f3bb4696a 100644 --- a/pkg/pluginmanager/plugin_manager_client.go +++ b/pkg/pluginmanager/plugin_manager_client.go @@ -8,8 +8,8 @@ import ( "github.com/hashicorp/go-plugin" "github.com/turbot/steampipe-plugin-sdk/v5/grpc" "github.com/turbot/steampipe-plugin-sdk/v5/logging" - pb "github.com/turbot/steampipe/pkg/pluginmanager_service/grpc/proto" - pluginshared "github.com/turbot/steampipe/pkg/pluginmanager_service/grpc/shared" + pb "github.com/turbot/steampipe/v2/pkg/pluginmanager_service/grpc/proto" + pluginshared "github.com/turbot/steampipe/v2/pkg/pluginmanager_service/grpc/shared" ) // PluginManagerClient is the client used by steampipe to access the plugin manager diff --git a/pkg/pluginmanager/state.go b/pkg/pluginmanager/state.go index 8c78972d9..7b05742de 100644 --- a/pkg/pluginmanager/state.go +++ b/pkg/pluginmanager/state.go @@ -10,8 +10,8 @@ import ( "github.com/hashicorp/go-plugin" filehelpers "github.com/turbot/go-kit/files" "github.com/turbot/pipe-fittings/v2/utils" - "github.com/turbot/steampipe/pkg/filepaths" - pb "github.com/turbot/steampipe/pkg/pluginmanager_service/grpc/proto" + "github.com/turbot/steampipe/v2/pkg/filepaths" + pb "github.com/turbot/steampipe/v2/pkg/pluginmanager_service/grpc/proto" ) const PluginManagerStructVersion = 20220411 diff --git a/pkg/pluginmanager_service/get_response.go b/pkg/pluginmanager_service/get_response.go index 8c3dc29c1..9be27a41b 100644 --- a/pkg/pluginmanager_service/get_response.go +++ b/pkg/pluginmanager_service/get_response.go @@ -1,8 +1,9 @@ package pluginmanager_service import ( - pb "github.com/turbot/steampipe/pkg/pluginmanager_service/grpc/proto" "sync" + + pb "github.com/turbot/steampipe/v2/pkg/pluginmanager_service/grpc/proto" ) // getResponse wraps pb.GetResponse, implementing locking or map access to allow concurrent usage diff --git a/pkg/pluginmanager_service/grpc/shared/grpc.go b/pkg/pluginmanager_service/grpc/shared/grpc.go index 0cc1b331a..91c715069 100644 --- a/pkg/pluginmanager_service/grpc/shared/grpc.go +++ b/pkg/pluginmanager_service/grpc/shared/grpc.go @@ -2,7 +2,8 @@ package shared import ( "context" - "github.com/turbot/steampipe/pkg/pluginmanager_service/grpc/proto" + + "github.com/turbot/steampipe/v2/pkg/pluginmanager_service/grpc/proto" ) // GRPCClient is an implementation of PluginManager service that talks over GRPC. diff --git a/pkg/pluginmanager_service/grpc/shared/interface.go b/pkg/pluginmanager_service/grpc/shared/interface.go index a4127d069..16c61f29f 100644 --- a/pkg/pluginmanager_service/grpc/shared/interface.go +++ b/pkg/pluginmanager_service/grpc/shared/interface.go @@ -3,7 +3,8 @@ package shared import ( "context" - "github.com/turbot/steampipe/pkg/pluginmanager_service/grpc/proto" + + "github.com/turbot/steampipe/v2/pkg/pluginmanager_service/grpc/proto" "github.com/hashicorp/go-plugin" "google.golang.org/grpc" diff --git a/pkg/pluginmanager_service/grpc/start_failure.go b/pkg/pluginmanager_service/grpc/start_failure.go index c91f2bb85..6b623fed2 100644 --- a/pkg/pluginmanager_service/grpc/start_failure.go +++ b/pkg/pluginmanager_service/grpc/start_failure.go @@ -1,9 +1,10 @@ package grpc import ( + "strings" + sdkplugin "github.com/turbot/steampipe-plugin-sdk/v5/plugin" "github.com/turbot/steampipe-plugin-sdk/v5/sperr" - "strings" ) // HandleStartFailure is used to handle errors when starting both Steampipe plugins an dthe plugin manage @@ -38,7 +39,7 @@ func HandleStartFailure(err error) error { } if strings.Contains(pluginMessage, sdkplugin.PluginStartupFailureMessage) { - return sperr.New(pluginError) + return sperr.New("%s", pluginError) } return err } diff --git a/pkg/pluginmanager_service/plugin_manager.go b/pkg/pluginmanager_service/plugin_manager.go index 7a080df1b..d28744325 100644 --- a/pkg/pluginmanager_service/plugin_manager.go +++ b/pkg/pluginmanager_service/plugin_manager.go @@ -26,14 +26,14 @@ import ( sdkshared "github.com/turbot/steampipe-plugin-sdk/v5/grpc/shared" sdkplugin "github.com/turbot/steampipe-plugin-sdk/v5/plugin" "github.com/turbot/steampipe-plugin-sdk/v5/sperr" - "github.com/turbot/steampipe/pkg/connection" - "github.com/turbot/steampipe/pkg/constants" - "github.com/turbot/steampipe/pkg/db/db_local" - "github.com/turbot/steampipe/pkg/error_helpers" - "github.com/turbot/steampipe/pkg/pluginmanager_service/grpc" - pb "github.com/turbot/steampipe/pkg/pluginmanager_service/grpc/proto" - pluginshared "github.com/turbot/steampipe/pkg/pluginmanager_service/grpc/shared" - "github.com/turbot/steampipe/pkg/steampipeconfig" + "github.com/turbot/steampipe/v2/pkg/connection" + "github.com/turbot/steampipe/v2/pkg/constants" + "github.com/turbot/steampipe/v2/pkg/db/db_local" + "github.com/turbot/steampipe/v2/pkg/error_helpers" + "github.com/turbot/steampipe/v2/pkg/pluginmanager_service/grpc" + pb "github.com/turbot/steampipe/v2/pkg/pluginmanager_service/grpc/proto" + pluginshared "github.com/turbot/steampipe/v2/pkg/pluginmanager_service/grpc/shared" + "github.com/turbot/steampipe/v2/pkg/steampipeconfig" ) // PluginManager is the implementation of grpc.PluginManager @@ -568,7 +568,7 @@ func (m *PluginManager) initializePlugin(connectionConfigs []*sdkproto.Connectio } // if this plugin does not support multiple connections, we no longer support it if !supportedOperations.MultipleConnections { - return nil, fmt.Errorf(error_helpers.PluginSdkCompatibilityError) + return nil, fmt.Errorf("%s", error_helpers.PluginSdkCompatibilityError) } // provide opportunity to avoid setting connection configs if we are shutting down diff --git a/pkg/pluginmanager_service/plugin_manager_notifications.go b/pkg/pluginmanager_service/plugin_manager_notifications.go index 3ad5d4064..887922788 100644 --- a/pkg/pluginmanager_service/plugin_manager_notifications.go +++ b/pkg/pluginmanager_service/plugin_manager_notifications.go @@ -5,8 +5,8 @@ import ( "log" "github.com/turbot/pipe-fittings/v2/error_helpers" - "github.com/turbot/steampipe/pkg/db/db_local" - "github.com/turbot/steampipe/pkg/steampipeconfig" + "github.com/turbot/steampipe/v2/pkg/db/db_local" + "github.com/turbot/steampipe/v2/pkg/steampipeconfig" ) func (m *PluginManager) SendPostgresSchemaNotification(ctx context.Context) error { diff --git a/pkg/pluginmanager_service/plugin_manager_plugin_columns.go b/pkg/pluginmanager_service/plugin_manager_plugin_columns.go index 833968a0b..0feb7fcb9 100644 --- a/pkg/pluginmanager_service/plugin_manager_plugin_columns.go +++ b/pkg/pluginmanager_service/plugin_manager_plugin_columns.go @@ -3,18 +3,19 @@ package pluginmanager_service import ( "context" "fmt" - sdkgrpc "github.com/turbot/steampipe-plugin-sdk/v5/grpc" - "github.com/turbot/steampipe-plugin-sdk/v5/grpc/proto" - sdkplugin "github.com/turbot/steampipe-plugin-sdk/v5/plugin" - "github.com/turbot/steampipe/pkg/constants" - "github.com/turbot/steampipe/pkg/db/db_common" - "github.com/turbot/steampipe/pkg/db/db_local" - "github.com/turbot/steampipe/pkg/introspection" - pb "github.com/turbot/steampipe/pkg/pluginmanager_service/grpc/proto" - "golang.org/x/exp/maps" "log" "slices" "strings" + + sdkgrpc "github.com/turbot/steampipe-plugin-sdk/v5/grpc" + "github.com/turbot/steampipe-plugin-sdk/v5/grpc/proto" + sdkplugin "github.com/turbot/steampipe-plugin-sdk/v5/plugin" + "github.com/turbot/steampipe/v2/pkg/constants" + "github.com/turbot/steampipe/v2/pkg/db/db_common" + "github.com/turbot/steampipe/v2/pkg/db/db_local" + "github.com/turbot/steampipe/v2/pkg/introspection" + pb "github.com/turbot/steampipe/v2/pkg/pluginmanager_service/grpc/proto" + "golang.org/x/exp/maps" ) func (m *PluginManager) initialisePluginColumns(ctx context.Context) error { diff --git a/pkg/pluginmanager_service/plugin_manager_plugin_instance.go b/pkg/pluginmanager_service/plugin_manager_plugin_instance.go index 5f42af0a5..4df1972a4 100644 --- a/pkg/pluginmanager_service/plugin_manager_plugin_instance.go +++ b/pkg/pluginmanager_service/plugin_manager_plugin_instance.go @@ -4,8 +4,8 @@ import ( "context" "github.com/turbot/pipe-fittings/v2/plugin" - "github.com/turbot/steampipe/pkg/connection" - "github.com/turbot/steampipe/pkg/db/db_local" + "github.com/turbot/steampipe/v2/pkg/connection" + "github.com/turbot/steampipe/v2/pkg/db/db_local" "golang.org/x/exp/maps" ) diff --git a/pkg/pluginmanager_service/plugin_manager_rate_limiters.go b/pkg/pluginmanager_service/plugin_manager_rate_limiters.go index afd4a1095..366f36d5f 100644 --- a/pkg/pluginmanager_service/plugin_manager_rate_limiters.go +++ b/pkg/pluginmanager_service/plugin_manager_rate_limiters.go @@ -12,12 +12,12 @@ import ( sdkgrpc "github.com/turbot/steampipe-plugin-sdk/v5/grpc" "github.com/turbot/steampipe-plugin-sdk/v5/grpc/proto" "github.com/turbot/steampipe-plugin-sdk/v5/sperr" - "github.com/turbot/steampipe/pkg/connection" - "github.com/turbot/steampipe/pkg/constants" - "github.com/turbot/steampipe/pkg/db/db_common" - "github.com/turbot/steampipe/pkg/db/db_local" - "github.com/turbot/steampipe/pkg/introspection" - pb "github.com/turbot/steampipe/pkg/pluginmanager_service/grpc/proto" + "github.com/turbot/steampipe/v2/pkg/connection" + "github.com/turbot/steampipe/v2/pkg/constants" + "github.com/turbot/steampipe/v2/pkg/db/db_common" + "github.com/turbot/steampipe/v2/pkg/db/db_local" + "github.com/turbot/steampipe/v2/pkg/introspection" + pb "github.com/turbot/steampipe/v2/pkg/pluginmanager_service/grpc/proto" "golang.org/x/exp/maps" ) diff --git a/pkg/pluginmanager_service/running_plugin.go b/pkg/pluginmanager_service/running_plugin.go index 2e61d04a0..60fd55475 100644 --- a/pkg/pluginmanager_service/running_plugin.go +++ b/pkg/pluginmanager_service/running_plugin.go @@ -2,7 +2,7 @@ package pluginmanager_service import ( "github.com/hashicorp/go-plugin" - pb "github.com/turbot/steampipe/pkg/pluginmanager_service/grpc/proto" + pb "github.com/turbot/steampipe/v2/pkg/pluginmanager_service/grpc/proto" ) type runningPlugin struct { diff --git a/pkg/query/init_data.go b/pkg/query/init_data.go index bff22900e..8ab025a6e 100644 --- a/pkg/query/init_data.go +++ b/pkg/query/init_data.go @@ -11,12 +11,12 @@ import ( "github.com/spf13/viper" pconstants "github.com/turbot/pipe-fittings/v2/constants" "github.com/turbot/pipe-fittings/v2/modconfig" - "github.com/turbot/steampipe/pkg/constants" - "github.com/turbot/steampipe/pkg/db/db_client" - "github.com/turbot/steampipe/pkg/error_helpers" - "github.com/turbot/steampipe/pkg/export" - "github.com/turbot/steampipe/pkg/initialisation" - "github.com/turbot/steampipe/pkg/statushooks" + "github.com/turbot/steampipe/v2/pkg/constants" + "github.com/turbot/steampipe/v2/pkg/db/db_client" + "github.com/turbot/steampipe/v2/pkg/error_helpers" + "github.com/turbot/steampipe/v2/pkg/export" + "github.com/turbot/steampipe/v2/pkg/initialisation" + "github.com/turbot/steampipe/v2/pkg/statushooks" ) type InitData struct { diff --git a/pkg/query/queryexecute/execute.go b/pkg/query/queryexecute/execute.go index dca896da7..247eac736 100644 --- a/pkg/query/queryexecute/execute.go +++ b/pkg/query/queryexecute/execute.go @@ -18,14 +18,14 @@ import ( "github.com/turbot/pipe-fittings/v2/queryresult" "github.com/turbot/pipe-fittings/v2/steampipeconfig" "github.com/turbot/pipe-fittings/v2/utils" - "github.com/turbot/steampipe/pkg/cmdconfig" - "github.com/turbot/steampipe/pkg/connection_sync" - "github.com/turbot/steampipe/pkg/db/db_common" - "github.com/turbot/steampipe/pkg/display" - "github.com/turbot/steampipe/pkg/error_helpers" - "github.com/turbot/steampipe/pkg/interactive" - "github.com/turbot/steampipe/pkg/query" - "github.com/turbot/steampipe/pkg/snapshot" + "github.com/turbot/steampipe/v2/pkg/cmdconfig" + "github.com/turbot/steampipe/v2/pkg/connection_sync" + "github.com/turbot/steampipe/v2/pkg/db/db_common" + "github.com/turbot/steampipe/v2/pkg/display" + "github.com/turbot/steampipe/v2/pkg/error_helpers" + "github.com/turbot/steampipe/v2/pkg/interactive" + "github.com/turbot/steampipe/v2/pkg/query" + "github.com/turbot/steampipe/v2/pkg/snapshot" ) func RunInteractiveSession(ctx context.Context, initData *query.InitData) error { diff --git a/pkg/query/queryhistory/history.go b/pkg/query/queryhistory/history.go index 1df8dcaa5..874850d9a 100644 --- a/pkg/query/queryhistory/history.go +++ b/pkg/query/queryhistory/history.go @@ -7,8 +7,8 @@ import ( "path/filepath" "strings" - "github.com/turbot/steampipe/pkg/constants" - "github.com/turbot/steampipe/pkg/filepaths" + "github.com/turbot/steampipe/v2/pkg/constants" + "github.com/turbot/steampipe/v2/pkg/filepaths" ) // QueryHistory :: struct for working with history in the interactive mode diff --git a/pkg/serversettings/load.go b/pkg/serversettings/load.go index f8f24dbfb..ad5202c03 100644 --- a/pkg/serversettings/load.go +++ b/pkg/serversettings/load.go @@ -7,8 +7,8 @@ import ( "github.com/jackc/pgx/v5" "github.com/jackc/pgx/v5/pgxpool" "github.com/turbot/steampipe-plugin-sdk/v5/sperr" - "github.com/turbot/steampipe/pkg/constants" - "github.com/turbot/steampipe/pkg/db/db_common" + "github.com/turbot/steampipe/v2/pkg/constants" + "github.com/turbot/steampipe/v2/pkg/db/db_common" ) func Load(ctx context.Context, pool *pgxpool.Pool) (serverSettings *db_common.ServerSettings, e error) { diff --git a/pkg/serversettings/setup.go b/pkg/serversettings/setup.go index cf7cce706..aea80c8ab 100644 --- a/pkg/serversettings/setup.go +++ b/pkg/serversettings/setup.go @@ -4,8 +4,8 @@ import ( "context" "fmt" - "github.com/turbot/steampipe/pkg/constants" - "github.com/turbot/steampipe/pkg/db/db_common" + "github.com/turbot/steampipe/v2/pkg/constants" + "github.com/turbot/steampipe/v2/pkg/db/db_common" ) func GetPopulateServerSettingsSql(ctx context.Context, settings db_common.ServerSettings) db_common.QueryWithArgs { diff --git a/pkg/steampipeconfig/connection_plugin.go b/pkg/steampipeconfig/connection_plugin.go index b551c7d9b..e25fe0bb0 100644 --- a/pkg/steampipeconfig/connection_plugin.go +++ b/pkg/steampipeconfig/connection_plugin.go @@ -13,9 +13,9 @@ import ( sdkgrpc "github.com/turbot/steampipe-plugin-sdk/v5/grpc" sdkproto "github.com/turbot/steampipe-plugin-sdk/v5/grpc/proto" sdkplugin "github.com/turbot/steampipe-plugin-sdk/v5/plugin" - "github.com/turbot/steampipe/pkg/error_helpers" - "github.com/turbot/steampipe/pkg/pluginmanager_service/grpc/proto" - pluginshared "github.com/turbot/steampipe/pkg/pluginmanager_service/grpc/shared" + "github.com/turbot/steampipe/v2/pkg/error_helpers" + "github.com/turbot/steampipe/v2/pkg/pluginmanager_service/grpc/proto" + pluginshared "github.com/turbot/steampipe/v2/pkg/pluginmanager_service/grpc/shared" "golang.org/x/exp/maps" ) @@ -286,7 +286,7 @@ func createConnectionPlugin(connection *modconfig.SteampipeConnection, reattach // we must have a plugin instance if connection.PluginInstance == nil { // unexpected - return nil, fmt.Errorf(fmt.Sprintf("connection '%s' has no plugin instance", connection.Name)) + return nil, fmt.Errorf("%s", fmt.Sprintf("connection '%s' has no plugin instance", connection.Name)) } log.Printf("[TRACE] createConnectionPlugin for connection %s", connection.Name) diff --git a/pkg/steampipeconfig/connection_schemas.go b/pkg/steampipeconfig/connection_schemas.go index 04aa30a9d..b5ced9c3b 100644 --- a/pkg/steampipeconfig/connection_schemas.go +++ b/pkg/steampipeconfig/connection_schemas.go @@ -2,8 +2,9 @@ package steampipeconfig import ( "context" + "github.com/turbot/steampipe-plugin-sdk/v5/plugin" - "github.com/turbot/steampipe/pkg/statushooks" + "github.com/turbot/steampipe/v2/pkg/statushooks" ) // ConnectionSchemaMap is a map of connection to all connections with the same schema diff --git a/pkg/steampipeconfig/connection_state.go b/pkg/steampipeconfig/connection_state.go index 24aaf9c93..9db15681d 100644 --- a/pkg/steampipeconfig/connection_state.go +++ b/pkg/steampipeconfig/connection_state.go @@ -8,7 +8,7 @@ import ( typehelpers "github.com/turbot/go-kit/types" "github.com/turbot/pipe-fittings/v2/modconfig" "github.com/turbot/steampipe-plugin-sdk/v5/plugin" - "github.com/turbot/steampipe/pkg/constants" + "github.com/turbot/steampipe/v2/pkg/constants" ) // ConnectionState is a struct containing all details for a connection diff --git a/pkg/steampipeconfig/connection_state_map.go b/pkg/steampipeconfig/connection_state_map.go index db6123bcd..53e5b7593 100644 --- a/pkg/steampipeconfig/connection_state_map.go +++ b/pkg/steampipeconfig/connection_state_map.go @@ -11,8 +11,8 @@ import ( "github.com/turbot/pipe-fittings/v2/modconfig" "github.com/turbot/pipe-fittings/v2/utils" sdkplugin "github.com/turbot/steampipe-plugin-sdk/v5/plugin" - "github.com/turbot/steampipe/pkg/constants" - "github.com/turbot/steampipe/pkg/filepaths" + "github.com/turbot/steampipe/v2/pkg/constants" + "github.com/turbot/steampipe/v2/pkg/filepaths" "golang.org/x/exp/maps" ) diff --git a/pkg/steampipeconfig/connection_updates.go b/pkg/steampipeconfig/connection_updates.go index a32d632c8..309ff4159 100644 --- a/pkg/steampipeconfig/connection_updates.go +++ b/pkg/steampipeconfig/connection_updates.go @@ -15,9 +15,9 @@ import ( "github.com/turbot/pipe-fittings/v2/utils" "github.com/turbot/steampipe-plugin-sdk/v5/grpc/proto" "github.com/turbot/steampipe-plugin-sdk/v5/plugin" - "github.com/turbot/steampipe/pkg/constants" - "github.com/turbot/steampipe/pkg/db/db_common" - pluginshared "github.com/turbot/steampipe/pkg/pluginmanager_service/grpc/shared" + "github.com/turbot/steampipe/v2/pkg/constants" + "github.com/turbot/steampipe/v2/pkg/db/db_common" + pluginshared "github.com/turbot/steampipe/v2/pkg/pluginmanager_service/grpc/shared" "golang.org/x/exp/maps" ) diff --git a/pkg/steampipeconfig/load_config.go b/pkg/steampipeconfig/load_config.go index bdd2a5e21..9d36d36a6 100644 --- a/pkg/steampipeconfig/load_config.go +++ b/pkg/steampipeconfig/load_config.go @@ -4,7 +4,6 @@ import ( "bytes" "context" "fmt" - "github.com/turbot/steampipe/pkg/parse" "log" "os" "path/filepath" @@ -12,6 +11,8 @@ import ( "strings" "time" + "github.com/turbot/steampipe/v2/pkg/parse" + "github.com/gertd/go-pluralize" "github.com/hashicorp/hcl/v2" filehelpers "github.com/turbot/go-kit/files" @@ -28,11 +29,11 @@ import ( "github.com/turbot/pipe-fittings/v2/versionfile" "github.com/turbot/pipe-fittings/v2/workspace_profile" "github.com/turbot/steampipe-plugin-sdk/v5/sperr" - "github.com/turbot/steampipe/pkg/constants" - "github.com/turbot/steampipe/pkg/db/db_common" - "github.com/turbot/steampipe/pkg/error_helpers" - "github.com/turbot/steampipe/pkg/filepaths" - "github.com/turbot/steampipe/pkg/options" + "github.com/turbot/steampipe/v2/pkg/constants" + "github.com/turbot/steampipe/v2/pkg/db/db_common" + "github.com/turbot/steampipe/v2/pkg/error_helpers" + "github.com/turbot/steampipe/v2/pkg/filepaths" + "github.com/turbot/steampipe/v2/pkg/options" ) var GlobalWorkspaceProfile *workspace_profile.SteampipeWorkspaceProfile diff --git a/pkg/steampipeconfig/load_connection_state.go b/pkg/steampipeconfig/load_connection_state.go index 5e83286f6..78c9974cc 100644 --- a/pkg/steampipeconfig/load_connection_state.go +++ b/pkg/steampipeconfig/load_connection_state.go @@ -10,10 +10,10 @@ import ( "github.com/jackc/pgx/v5" "github.com/sethvargo/go-retry" "github.com/turbot/pipe-fittings/v2/utils" - "github.com/turbot/steampipe/pkg/constants" - "github.com/turbot/steampipe/pkg/db/db_common" - "github.com/turbot/steampipe/pkg/filepaths" - "github.com/turbot/steampipe/pkg/statushooks" + "github.com/turbot/steampipe/v2/pkg/constants" + "github.com/turbot/steampipe/v2/pkg/db/db_common" + "github.com/turbot/steampipe/v2/pkg/filepaths" + "github.com/turbot/steampipe/v2/pkg/statushooks" ) // LoadConnectionState populates a ConnectionStateMap from the connection_state table diff --git a/pkg/steampipeconfig/steampipeconfig.go b/pkg/steampipeconfig/steampipeconfig.go index 47dcedc45..e9cab6faa 100644 --- a/pkg/steampipeconfig/steampipeconfig.go +++ b/pkg/steampipeconfig/steampipeconfig.go @@ -19,7 +19,7 @@ import ( "github.com/turbot/pipe-fittings/v2/versionfile" "github.com/turbot/pipe-fittings/v2/workspace_profile" "github.com/turbot/steampipe-plugin-sdk/v5/sperr" - "github.com/turbot/steampipe/pkg/options" + "github.com/turbot/steampipe/v2/pkg/options" ) // SteampipeConfig is a struct to hold Connection map and Steampipe options diff --git a/pkg/steampipeconfig/validate.go b/pkg/steampipeconfig/validate.go index 3a2ec2e23..597fb9da6 100644 --- a/pkg/steampipeconfig/validate.go +++ b/pkg/steampipeconfig/validate.go @@ -5,7 +5,7 @@ import ( "slices" "strings" - "github.com/turbot/steampipe/pkg/constants" + "github.com/turbot/steampipe/v2/pkg/constants" ) func ValidateConnectionName(connectionName string) error { diff --git a/pkg/task/display.go b/pkg/task/display.go index 23c5e2cfb..9b6d52eab 100644 --- a/pkg/task/display.go +++ b/pkg/task/display.go @@ -10,8 +10,8 @@ import ( "github.com/turbot/go-kit/files" "github.com/turbot/pipe-fittings/v2/plugin" "github.com/turbot/pipe-fittings/v2/utils" - "github.com/turbot/steampipe/pkg/error_helpers" - "github.com/turbot/steampipe/pkg/filepaths" + "github.com/turbot/steampipe/v2/pkg/error_helpers" + "github.com/turbot/steampipe/v2/pkg/filepaths" ) const ( diff --git a/pkg/task/runner.go b/pkg/task/runner.go index 7e4bd584f..172fba773 100644 --- a/pkg/task/runner.go +++ b/pkg/task/runner.go @@ -12,11 +12,11 @@ import ( "github.com/turbot/go-kit/files" "github.com/turbot/pipe-fittings/v2/plugin" "github.com/turbot/pipe-fittings/v2/utils" - "github.com/turbot/steampipe/pkg/db/db_local" - "github.com/turbot/steampipe/pkg/error_helpers" - "github.com/turbot/steampipe/pkg/filepaths" - "github.com/turbot/steampipe/pkg/installationstate" - "github.com/turbot/steampipe/pkg/steampipeconfig" + "github.com/turbot/steampipe/v2/pkg/db/db_local" + "github.com/turbot/steampipe/v2/pkg/error_helpers" + "github.com/turbot/steampipe/v2/pkg/filepaths" + "github.com/turbot/steampipe/v2/pkg/installationstate" + "github.com/turbot/steampipe/v2/pkg/steampipeconfig" ) const minimumDurationBetweenChecks = 24 * time.Hour