Title: [Plugins] Should the `plugin` package be moved out of `internal`? · sqlc-dev/sqlc · Discussion #1703 · GitHub
Open Graph Title: [Plugins] Should the `plugin` package be moved out of `internal`? · sqlc-dev/sqlc · Discussion #1703
X Title: [Plugins] Should the `plugin` package be moved out of `internal`? · sqlc-dev/sqlc · Discussion #1703
Description: [Plugins] Should the `plugin` package be moved out of `internal`?
Open Graph Description: Version 1.14.0 What happened? I wanted to play around with authoring a plugin, but after reading the documentation and looking at the example code, I realized that the plugin package, which contain...
X Description: Version 1.14.0 What happened? I wanted to play around with authoring a plugin, but after reading the documentation and looking at the example code, I realized that the plugin package, which contain...
Opengraph URL: https://github.com/sqlc-dev/sqlc/discussions/1703
X: @github
Domain: github.com
{"@context":"https://schema.org","@type":"QAPage","mainEntity":{"@type":"Question","name":"[Plugins] Should the `plugin` package be moved out of `internal`?","text":"\u003ch3 dir=\"auto\"\u003eVersion\u003c/h3\u003e\n\u003cp dir=\"auto\"\u003e1.14.0\u003c/p\u003e\n\u003ch3 dir=\"auto\"\u003eWhat happened?\u003c/h3\u003e\n\u003cp dir=\"auto\"\u003eI wanted to play around with authoring a plugin, but after reading the documentation and looking at the example code, I realized that the \u003ccode class=\"notranslate\"\u003eplugin\u003c/code\u003e package, which contains the protobuf-emitted code, lives under \u003ccode class=\"notranslate\"\u003einternal\u003c/code\u003e. By definition this means that no Go code outside of sqlc can import it. I saw that the ultimate goal is to have WASM-based plugins, but \u003ca class=\"issue-link js-issue-link\" data-error-text=\"Failed to load title\" data-id=\"1221731399\" data-permission-text=\"Title is private\" data-url=\"https://github.com/sqlc-dev/sqlc/issues/1578\" data-hovercard-type=\"pull_request\" data-hovercard-url=\"/sqlc-dev/sqlc/pull/1578/hovercard\" href=\"https://github.com/sqlc-dev/sqlc/pull/1578\"\u003e#1578\u003c/a\u003e indicates that development on that has been stalled, opting for process-based plugins for the time being.\u003c/p\u003e\n\u003cp dir=\"auto\"\u003eAm I missing something obvious that makes it possible to write a process-based plugin? Or does the \u003ccode class=\"notranslate\"\u003eplugin\u003c/code\u003e package need to be moved out of \u003ccode class=\"notranslate\"\u003einternal\u003c/code\u003e?\u003c/p\u003e\n\u003ch3 dir=\"auto\"\u003eRelevant log output\u003c/h3\u003e\n\u003cp dir=\"auto\"\u003e\u003cem\u003eNo response\u003c/em\u003e\u003c/p\u003e\n\u003ch3 dir=\"auto\"\u003eDatabase schema\u003c/h3\u003e\n\u003cp dir=\"auto\"\u003e\u003cem\u003eNo response\u003c/em\u003e\u003c/p\u003e\n\u003ch3 dir=\"auto\"\u003eSQL queries\u003c/h3\u003e\n\u003cp dir=\"auto\"\u003e\u003cem\u003eNo response\u003c/em\u003e\u003c/p\u003e\n\u003ch3 dir=\"auto\"\u003eConfiguration\u003c/h3\u003e\n\u003cp dir=\"auto\"\u003e\u003cem\u003eNo response\u003c/em\u003e\u003c/p\u003e\n\u003ch3 dir=\"auto\"\u003ePlayground URL\u003c/h3\u003e\n\u003cp dir=\"auto\"\u003e\u003cem\u003eNo response\u003c/em\u003e\u003c/p\u003e\n\u003ch3 dir=\"auto\"\u003eWhat operating system are you using?\u003c/h3\u003e\n\u003cp dir=\"auto\"\u003e\u003cem\u003eNo response\u003c/em\u003e\u003c/p\u003e\n\u003ch3 dir=\"auto\"\u003eWhat database engines are you using?\u003c/h3\u003e\n\u003cp dir=\"auto\"\u003e\u003cem\u003eNo response\u003c/em\u003e\u003c/p\u003e\n\u003ch3 dir=\"auto\"\u003eWhat type of code are you generating?\u003c/h3\u003e\n\u003cp dir=\"auto\"\u003e\u003cem\u003eNo response\u003c/em\u003e\u003c/p\u003e","upvoteCount":1,"answerCount":3,"acceptedAnswer":{"@type":"Answer","text":"\u003cp dir=\"auto\"\u003eThis has been fixed as of 1.16.0. The Python and Kotlin plugins are now separate and take advantage of the \u003ca href=\"https://github.com/tabbed/sqlc-go\"\u003ehttps://github.com/tabbed/sqlc-go\u003c/a\u003e repository.\u003c/p\u003e\n\u003cp dir=\"auto\"\u003eYou can see how a plugin works here: \u003ca href=\"https://github.com/tabbed/sqlc-gen-python\"\u003ehttps://github.com/tabbed/sqlc-gen-python\u003c/a\u003e\u003c/p\u003e","upvoteCount":1,"url":"https://github.com/sqlc-dev/sqlc/discussions/1703#discussioncomment-5084499"}}}
| react-profiling | 0 |
| react-import-map | react,react-dom,react-dom/client,react-dom/profiling,react-is,react/compiler-runtime,react/jsx-dev-runtime,react/jsx-runtime,scheduler@b8488ee2c322 |
| route-pattern | /_view_fragments/Voltron::DiscussionsFragmentsController/show/:user_id/:repository/:discussion_number/discussion_layout(.:format) |
| route-controller | voltron_discussions_fragments |
| route-action | discussion_layout |
| fetch-nonce | v2:f3f1267e-1bcb-dc72-1189-7642311e6ccc |
| current-catalog-service-hash | 9f0abe34da433c9b6db74bffa2466494a717b579a96b30a5d252e5090baea7be |
| request-id | B252:31E99C:2CCF9A2:3BD4C8C:6B01D0B7 |
| html-safe-nonce | 4363ea2d44952b876f1b4fc74134428e886e3dab4d6b467d12249de77d0abd78 |
| visitor-payload | eyJyZWZlcnJlciI6IiIsInJlcXVlc3RfaWQiOiJCMjUyOjMxRTk5QzoyQ0NGOUEyOjNCRDRDOEM6NkIwMUQwQjciLCJ2aXNpdG9yX2lkIjoiNjU3MzEyMDA1MTU1NjI0MTU5MSIsInJlZ2lvbl9lZGdlIjoiaWFkIiwicmVnaW9uX3JlbmRlciI6ImlhZCJ9 |
| visitor-hmac | 2ae3afc5935b822dd07baf53f39b705840b37f118aaf0eb124fc331c76d1ea77 |
| hovercard-subject-tag | discussion:4172108 |
| github-keyboard-shortcuts | repository,copilot |
| google-site-verification | Apib7-x98H0j5cPqHWwSMm6dNU4GmODRoqxLiDzdx9I |
| octolytics-url | https://collector.github.com/github/collect |
| analytics-location | / |
| fb:app_id | 1401488693436528 |
| apple-itunes-app | app-id=1477376905, app-argument=https://github.com/_view_fragments/Voltron::DiscussionsFragmentsController/show/sqlc-dev/sqlc/1703/discussion_layout |
| twitter:image | https://opengraph.githubassets.com/2cc4867de8da64d21900bdfde6ce35fb0c5b2ce77005ea90fe3d1a56cbe4894b/sqlc-dev/sqlc/discussions/1703 |
| twitter:card | summary_large_image |
| og:image | https://opengraph.githubassets.com/2cc4867de8da64d21900bdfde6ce35fb0c5b2ce77005ea90fe3d1a56cbe4894b/sqlc-dev/sqlc/discussions/1703 |
| og:image:alt | Version 1.14.0 What happened? I wanted to play around with authoring a plugin, but after reading the documentation and looking at the example code, I realized that the plugin package, which contain... |
| og:image:width | 1200 |
| og:image:height | 600 |
| og:site_name | GitHub |
| og:type | object |
| hostname | github.com |
| expected-hostname | github.com |
| None | cc5dfdd32f62ebd3223cab3af3aa2b268d3605218237326a48a99d1efd89495c |
| turbo-cache-control | no-preview |
| go-import | github.com/sqlc-dev/sqlc git https://github.com/sqlc-dev/sqlc.git |
| octolytics-dimension-user_id | 136738596 |
| octolytics-dimension-user_login | sqlc-dev |
| octolytics-dimension-repository_id | 193160679 |
| octolytics-dimension-repository_nwo | sqlc-dev/sqlc |
| octolytics-dimension-repository_public | true |
| octolytics-dimension-repository_is_fork | false |
| octolytics-dimension-repository_network_root_id | 193160679 |
| octolytics-dimension-repository_network_root_nwo | sqlc-dev/sqlc |
| turbo-body-classes | logged-out env-production page-responsive |
| disable-turbo | false |
| browser-stats-url | https://api.github.com/_private/browser/stats |
| browser-errors-url | https://api.github.com/_private/browser/errors |
| release | 8c77c9e8439031ad54c75a250694842892f693e1 |
| ui-target | full |
| theme-color | #1e2327 |
| color-scheme | light dark |
Links:
Viewport: width=device-width