<commit_before>package main

import (
	"fmt"
	"io"
	"io/ioutil"
	"net/http"
)

func hello(w http.ResponseWriter, r *http.Request) {
	body, err := ioutil.ReadAll(r.Body)
	if err != nil {
		return
	}

	line := fmt.Sprintf("webbhook: -> %s", string(body))
	fmt.Println(line)
	io.WriteString(w, line)
}

func main() {
	http.HandleFunc("/", hello)
	http.ListenAndServe(":3010", nil)
}<commit_msg>Fix gosec finding of unhandled errors (#29398)<commit_after>package main

import (
	"fmt"
	"io"
	"io/ioutil"
	"log"
	"net/http"
)

func hello(w http.ResponseWriter, r *http.Request) {
	body, err := ioutil.ReadAll(r.Body)
	if err != nil {
		return
	}

	line := fmt.Sprintf("webbhook: -> %s", string(body))
	fmt.Println(line)
	if _, err := io.WriteString(w, line); err != nil {
		log.Printf("Failed to write: %v", err)
	}
}

func main() {
	http.HandleFunc("/", hello)
	log.Fatal(http.ListenAndServe(":3010", nil))
}
{'fraction_non_alphanumeric': 0.18805309734513273, 'fraction_numerical': 0.014380530973451327, 'mean_word_length': 4.142045454545454, 'pattern_counts': {'":': 2, '<': 3, '<?xml version=': 0, '>': 5, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '4664065', 'n_tokens_mistral': 396, 'n_tokens_neox': 376, 'n_words': 80}