The Go Blog has released the Go Developer Survey for Q2 2022. According to reports, a total of 5,752 developers participated in this survey, sharing their experiences and insights on using the new features in Go 1.18.

main findings

  • Generics have been rapidly adopted.Most respondents are aware that Go 1.18 has officially supported generics, and about a quarter of respondents said they have started using generics in Go code. However, developers have also encountered some limitations of the initial generic implementation.
  • Fuzzing is new to most Go developers. Respondents were far less aware of Go’s built-in fuzzing than generics, and they had more uncertainty about why or when to consider fuzzing.
  • Third-party dependencies are the most important security concern.avoidDependencies with known vulnerabilitieswas the biggest security-related challenge faced by respondents. More broadly, security work is often unplanned and unrewarded, which means that tools require the developer’s time and attention.
  • Officials can do better when releasing new features. A random sample of participants was less likely to know about the most recent version of the Go tools than people who found this survey through the Go blog. This suggests that officials should seek opportunities outside of blog posts to communicate changes in the Go ecosystem, or expand their influence to share these posts more widely.
  • Error handling remains a challenge. With the release of generics, the biggest challenge respondents faced when using Go shifted to error handling. Overall, however, developer satisfaction with Go remains high, and respondents reported no noticeable changes in the way they use Go.

Respondents’ perception of Go generics

The vast majority of respondents (86%) already knew that generics were released as part of the Go 1.18 release. Officials say the ratio is much higher than they expected. Additionally, about a quarter of respondents have started using generics in Go code (26%), with 14% saying they already use generics in production or release code. The majority of respondents (54%) are not opposed to using generics, but they are not currently required. A further 8% of respondents said they would like to use generics in Go but are currently blocked by something.

So what prevents developers from using generics? Most respondents fall into one of two categories. First, 30% of respondents said they encountered limitations of their current generics implementation, such as required parameterization methods, improved type inference, or switching types. Respondents said these issues limit the potential use cases for generics, or believe they make generic code unnecessarily verbose. The second category involves things that don’t support generics yet – linters are the most common tools, and also includes organizations still using earlier Go versions or relying on Linux distributions that aren’t yet supported.

12% of respondents said Go generics have a steep learning curve or lack useful documentation. In addition to these top questions, respondents also described a range of less common challenges, as shown in the chart below:

What do respondents use Go to develop for?

The two most common use cases remain building API/RPC services (73%) and writing CLIs (60%).

The Go team used a linear model to investigate whether there was a relationship between how long respondents spent using Go and the type of things they built with Go. It was ultimately found that respondents with < 1 year of Go development experience were more likely to build something (GUI, IoT, games, ML/AI, or mobile apps) in the lower half of this chart, indicating that they are more likely to build something in the lower half of this chart. Domains interested in using Go. But after having 1 year of Go development experience, these developers are less focused on the above areas, which means they encounter significant obstacles in using Go in these areas.

The majority of respondents use Linux (59%) or macOS (52%) when developing with Go, and the vast majority deploy to Linux systems (93%). In this survey, officials added an option to develop on WSL, which was selected by the final 13% of respondents.

Respondents’ favorite editor for writing Go code

It can be seen that the free and open source Visual Studio Code is the mainstream choice for Go developers to write code (45%), and the proportion of GoLand is slightly lower (34%).

Full report.

#Developer #Survey #Report #News Fast Delivery

Leave a Comment

Your email address will not be published. Required fields are marked *