{"id":374702,"date":"2023-07-21T18:34:17","date_gmt":"2023-07-21T17:34:17","guid":{"rendered":"https:\/\/blog.jetbrains.com\/?post_type=go&#038;p=374702"},"modified":"2023-07-21T18:43:53","modified_gmt":"2023-07-21T17:43:53","slug":"goland-2023-2-release-candidate","status":"publish","type":"go","link":"https:\/\/blog.jetbrains.com\/zh-hans\/go\/2023\/07\/21\/goland-2023-2-release-candidate","title":{"rendered":"GoLand 2023.2 Release Candidate Is Available!\u00a0"},"content":{"rendered":"\n<p>GoLand 2023.2 Release Candidate is out now!<\/p>\n\n\n\n<p>You can get this build via the <a href=\"https:\/\/www.jetbrains.com\/toolbox\/app\/\" target=\"_blank\" rel=\"noopener\">Toolbox App<\/a>, download it from our website, or use a snap package (for Ubuntu). You can also download the build from inside GoLand by selecting <em>Check IDE updates for: Early Access Program<\/em> in <em>Settings<\/em> | <em>Appearance &amp; Behavior<\/em> | <em>System Settings<\/em> | <em>Updates.<\/em><\/p>\n\n\n\n<p align=\"center\">\n    <a class=\"jb-download-button\" href=\"https:\/\/www.jetbrains.com\/go\/nextversion\/\" target=\"_blank\" rel=\"noopener\">      \n        Download GoLand Release Candidate\n    <\/a>\n<\/p>\n\n\n\n<p>Please note that to use GoLand 2023.2 RC, you need to have an active subscription or start a 30-day trial.<\/p>\n\n\n\n<p>The Release Candidate provides all of the new features and improvements already announced during our current EAP cycle and expected in the major 2023.2 release.<\/p>\n\n\n\n<p>Our <a href=\"https:\/\/blog.jetbrains.com\/go\/category\/eap\/\">recent EAP blog posts<\/a> have more details about these updates, but here are some of the highlights:<\/p>\n\n\n\n<ul>\n<li><strong>Improved integration with Go modules.<\/strong> You can now <a href=\"https:\/\/blog.jetbrains.com\/zh-hans\/go\/2023\/05\/12\/the-goland-2023-2-early-access-program-has-started#Optionalabilitytodownloadmodulesautomatically\">download all dependencies automatically<\/a> on project open and after each change of the go.mod file. There is also a new quick-fix to <a href=\"https:\/\/blog.jetbrains.com\/zh-hans\/go\/2023\/06\/16\/goland-2023-2-eap-5#Intentionactionstoupdatedependenciesingo.mod\">update dependencies<\/a> in go.mod to their recent versions. In addition, you can now <a href=\"https:\/\/blog.jetbrains.com\/zh-hans\/go\/2023\/05\/12\/the-goland-2023-2-early-access-program-has-started#Optiontodisablevendoring\">disable vendoring<\/a> on a per-project basis, for example, when you have a monorepo containing the vendor folder used by another language.<\/li>\n\n\n\n<li><strong>The <\/strong><strong><em>Migrate function parameter to method receiver<\/em><\/strong><strong> refactoring. <\/strong>We have a new <a href=\"https:\/\/blog.jetbrains.com\/zh-hans\/go\/2023\/05\/12\/the-goland-2023-2-early-access-program-has-started#Migratefunctionparametertomethodreceiver\">refactoring<\/a> that can be used when you need to convert separate functions to methods of a type. There is also the <em>Migrate method receiver to function parameter <\/em>refactoring, which does the opposite and turns methods of a type to separate functions.<\/li>\n\n\n\n<li>We\u2019ve implemented <a href=\"https:\/\/blog.jetbrains.com\/zh-hans\/go\/2023\/05\/12\/the-goland-2023-2-early-access-program-has-started#Completionfor%E2%80%98make%E2%80%99functionarguments\">completion<\/a> and <a href=\"https:\/\/blog.jetbrains.com\/zh-hans\/go\/2023\/05\/12\/the-goland-2023-2-early-access-program-has-started#Checksfor%E2%80%98make%E2%80%99functionarguments\">checks<\/a> for make function arguments.<\/li>\n\n\n\n<li>Other Go-related features include:\n<ul>\n<li>The receiver type <a href=\"https:\/\/blog.jetbrains.com\/zh-hans\/go\/2023\/05\/12\/the-goland-2023-2-early-access-program-has-started#Thereceivertypeisshownincompletionformethodexpressions\">is shown<\/a> in completion for method expressions.<\/li>\n\n\n\n<li>The <a href=\"https:\/\/blog.jetbrains.com\/zh-hans\/go\/2023\/05\/12\/the-goland-2023-2-early-access-program-has-started#Generics:Improvederrormessageformissingarguments\">error message for missing arguments<\/a> in a type\u2019s instantiation has been improved.<\/li>\n\n\n\n<li>The <em>Wrap error handling in a closure<\/em> intention now has a <a href=\"https:\/\/blog.jetbrains.com\/zh-hans\/go\/2023\/05\/12\/the-goland-2023-2-early-access-program-has-started#PreviewfortheWraperrorhandlinginaclosureintention\">preview<\/a>.<\/li>\n\n\n\n<li>A warning for redundant conditions in for loops has been added.<\/li>\n<\/ul>\n<\/li>\n\n\n\n<li>In performance updates, there\u2019s a new tool for <a href=\"https:\/\/blog.jetbrains.com\/zh-hans\/go\/2023\/05\/19\/user-experience-and-performance-improvements-in-goland-2023-2-eap-2#Newtoolforeasilygeneratingsharedindexes\">easily generating shared indexes<\/a>.<\/li>\n\n\n\n<li>Make sure to try our brand-new <a href=\"https:\/\/blog.jetbrains.com\/zh-hans\/idea\/2023\/06\/ai-assistant-in-jetbrains-ides\"><strong>AI Assistant<\/strong><\/a>!<\/li>\n\n\n\n<li>You can now <a href=\"https:\/\/blog.jetbrains.com\/zh-hans\/go\/2023\/06\/16\/goland-2023-2-eap-5#Optiontocommitspecificlinesofcode\">commit specific lines of code<\/a>.<\/li>\n\n\n\n<li>We also have improvements for <a href=\"https:\/\/blog.jetbrains.com\/zh-hans\/go\/2023\/06\/16\/goland-2023-2-eap-5#Docker\">Docker integration<\/a> and the <a href=\"https:\/\/blog.jetbrains.com\/zh-hans\/go\/2023\/06\/16\/goland-2023-2-eap-5#Kubernetes\">Kubernetes plugin<\/a>.<\/li>\n\n\n\n<li>User experience enhancements include:\n<ul>\n<li><a href=\"https:\/\/blog.jetbrains.com\/zh-hans\/go\/2023\/05\/12\/the-goland-2023-2-early-access-program-has-started#VSCodekeymapisbundled\">Bundled VS Code keymap<\/a>.<\/li>\n\n\n\n<li><a href=\"https:\/\/blog.jetbrains.com\/zh-hans\/go\/2023\/06\/09\/goland-2023-2-eap-4#FilesortingbymodificationtimeintheProjectview\">File sorting by modification time in the <em>Project<\/em> view<\/a>.<\/li>\n\n\n\n<li><a href=\"https:\/\/blog.jetbrains.com\/zh-hans\/go\/2023\/06\/09\/goland-2023-2-eap-4#PinnedrunconfigurationsintheRunwidget\">Pinned run configurations in the <em>Run<\/em> widget<\/a>.<\/li>\n\n\n\n<li><a href=\"https:\/\/blog.jetbrains.com\/zh-hans\/go\/2023\/06\/02\/gitlab-integration-2023-2-eap-3#Improvedmaintoolbarcustomization\">Improved main toolbar customization<\/a>.<\/li>\n\n\n\n<li><a href=\"https:\/\/blog.jetbrains.com\/zh-hans\/go\/2023\/06\/02\/gitlab-integration-2023-2-eap-3#Single-clicknavigationbetweenprojectdirectories\">Single-click navigation between project directories<\/a>.<\/li>\n\n\n\n<li><a href=\"https:\/\/blog.jetbrains.com\/zh-hans\/go\/2023\/06\/02\/gitlab-integration-2023-2-eap-3#TextsearchinSearchEverywhere\">Text search in <em>Search Everywhere<\/em><\/a><em>.<\/em><\/li>\n<\/ul>\n<\/li>\n\n\n\n<li>For the user interface, we have <a href=\"https:\/\/blog.jetbrains.com\/zh-hans\/go\/2023\/06\/26\/goland-2023-2-eap-6-ai-assistant#ColoredprojectheadersinthenewUI\">colored project headers<\/a> in the new UI.<\/li>\n\n\n\n<li>The much-anticipated <a href=\"https:\/\/blog.jetbrains.com\/zh-hans\/go\/2023\/06\/02\/gitlab-integration-2023-2-eap-3#GitLabintegration\">GitLab integration<\/a> is available.<\/li>\n\n\n\n<li>We have also added the <a href=\"https:\/\/blog.jetbrains.com\/zh-hans\/go\/2023\/06\/09\/goland-2023-2-eap-4#TheKafkaplugin\">Kafka<\/a> plugin.<\/li>\n\n\n\n<li><a href=\"https:\/\/blog.jetbrains.com\/zh-hans\/go\/2023\/06\/30\/goland-2023-2-eap-7#LSPsupportforplugindevelopers\">LSP API support<\/a> is available for plugin developers.<\/li>\n\n\n\n<li>Don\u2019t miss the improvements we\u2019ve implemented for the <a href=\"https:\/\/blog.jetbrains.com\/zh-hans\/go\/2023\/06\/30\/goland-2023-2-eap-7#HTTPClient\">HTTP Client<\/a> and <a href=\"https:\/\/blog.jetbrains.com\/zh-hans\/go\/2023\/06\/30\/goland-2023-2-eap-7#ImprovementsforSwaggerandOpenApi\">Swagger and OpenAPI support<\/a>.<\/li>\n<\/ul>\n\n\n\n<p>This RC build includes some new features as well. Let\u2019s take a look!<\/p>\n\n\n\n<h2 class=\"wp-block-heading\">Support for <code>errors.Is<\/code> and <code>errors.As<\/code><\/h2>\n\n\n\n<p>We\u2019ve implemented two inspections that will highlight the cases where <a href=\"https:\/\/go.dev\/blog\/go1.13-errors\" target=\"_blank\" rel=\"noreferrer noopener\"><code>errors.Is<\/code><\/a> or<a href=\"https:\/\/go.dev\/blog\/go1.13-errors\" target=\"_blank\" rel=\"noopener\"> <\/a><a href=\"https:\/\/go.dev\/blog\/go1.13-errors\" target=\"_blank\" rel=\"noreferrer noopener\"><code>errors.As<\/code><\/a> should be used. There are also quick-fixes that will help you refactor the existing code to <code>errors.Is<\/code> or <code>errors.As<\/code> usages.<\/p>\n\n\n\n<p>The first inspection highlights the direct comparisons of errors.<\/p>\n\n\n\n<p>In Go 1.13 and later, errors can be wrapped using the <code>fmt.Errorf<\/code> function with the <code>%w<\/code> verb, and direct comparison of errors using the equality check may fail on wrapped errors.<\/p>\n\n\n\n<p>The preferred way of checking for a specific error is to use the <code>errors.Is<\/code> function from the standard library. GoLand now has a quick-fix that suggests converting direct error comparisons to usages of <code>errors.Is<\/code>.<\/p>\n\n\n\n<figure class=\"wp-block-image size-full\"><img decoding=\"async\" loading=\"lazy\" width=\"1500\" height=\"600\" src=\"https:\/\/blog.jetbrains.com\/wp-content\/uploads\/2023\/07\/errorsIs.gif\" alt=\"\" class=\"wp-image-374753\"\/><\/figure>\n\n\n\n<p>The second inspection highlights type assertions and type switches on errors, such as &nbsp;<code>err.(*MyErr)<\/code> or <code>switch err.(type)<\/code>, as they may also fail on wrapped errors.<\/p>\n\n\n\n<p>The preferred way in Go 1.13 and later is to use <code>errors.As<\/code>. Our new quick-fix suggests converting type assertions and type switches on errors to usages of <code>errors.As<\/code>.<\/p>\n\n\n\n<figure class=\"wp-block-image size-full\"><img decoding=\"async\" loading=\"lazy\" width=\"1500\" height=\"600\" src=\"https:\/\/blog.jetbrains.com\/wp-content\/uploads\/2023\/07\/errorsAs.gif\" alt=\"\" class=\"wp-image-374764\"\/><\/figure>\n\n\n\n<h2 class=\"wp-block-heading\">Support for <code>min<\/code>, <code>max<\/code>, and <code>clear<\/code><\/h2>\n\n\n\n<p>GoLand 2023.2 RC provides basic support for <code>min<\/code>, <code>max<\/code>, and <code>clear<\/code> \u2013 the new functions introduced in Go 1.21.<\/p>\n\n\n\n<p>That\u2019s it for today! We\u2019d love to hear what you think about the new features. Get in touch with us on <a href=\"https:\/\/twitter.com\/GoLandIDE\" target=\"_blank\" rel=\"noopener\">Twitter<\/a>, leave your comments below, report any issues in <a href=\"https:\/\/youtrack.jetbrains.com\/issues\/GO?_gl=1*1ryja4i*_ga*MTMzMTM3NzQ1MS4xNjIxOTM2MTky*_ga_0WQ2ZF5VGT*MTYyMjQ3MTM1Ny4zOS4xLjE2MjI0NzE0NDkuMA..&amp;_ga=2.61428393.463726163.1622398163-1331377451.1621936192&amp;_gac=1.49805012.1621529532.Cj0KCQjwkZiFBhD9ARIsAGxFX8CLxXvfJzlAlF42EN3ry-0foEM5GdeLKEOzRSUXC2Dj1LK8EQNhW5UaAoKBEALw_wcB\" target=\"_blank\" rel=\"noopener\">our tracker<\/a>, or drop us a message in the <a href=\"https:\/\/invite.slack.golangbridge.org\/\" target=\"_blank\" rel=\"noopener\">Gophers Slack<\/a> #goland channel. Thanks!<\/p>\n","protected":false},"author":1254,"featured_media":374720,"comment_status":"closed","ping_status":"closed","template":"","categories":[907],"tags":[8112],"cross-post-tag":[],"acf":[],"_links":{"self":[{"href":"https:\/\/blog.jetbrains.com\/zh-hans\/wp-json\/wp\/v2\/go\/374702"}],"collection":[{"href":"https:\/\/blog.jetbrains.com\/zh-hans\/wp-json\/wp\/v2\/go"}],"about":[{"href":"https:\/\/blog.jetbrains.com\/zh-hans\/wp-json\/wp\/v2\/types\/go"}],"author":[{"embeddable":true,"href":"https:\/\/blog.jetbrains.com\/zh-hans\/wp-json\/wp\/v2\/users\/1254"}],"replies":[{"embeddable":true,"href":"https:\/\/blog.jetbrains.com\/zh-hans\/wp-json\/wp\/v2\/comments?post=374702"}],"version-history":[{"count":10,"href":"https:\/\/blog.jetbrains.com\/zh-hans\/wp-json\/wp\/v2\/go\/374702\/revisions"}],"predecessor-version":[{"id":374913,"href":"https:\/\/blog.jetbrains.com\/zh-hans\/wp-json\/wp\/v2\/go\/374702\/revisions\/374913"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/blog.jetbrains.com\/zh-hans\/wp-json\/wp\/v2\/media\/374720"}],"wp:attachment":[{"href":"https:\/\/blog.jetbrains.com\/zh-hans\/wp-json\/wp\/v2\/media?parent=374702"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/blog.jetbrains.com\/zh-hans\/wp-json\/wp\/v2\/categories?post=374702"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/blog.jetbrains.com\/zh-hans\/wp-json\/wp\/v2\/tags?post=374702"},{"taxonomy":"cross-post-tag","embeddable":true,"href":"https:\/\/blog.jetbrains.com\/zh-hans\/wp-json\/wp\/v2\/cross-post-tag?post=374702"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}