CocaineCong / tangseng

Tangseng search engine including full text search and vector search base on golang. 基于go语言的搜索引擎,信息检索系统
https://cocainecong.github.io/tangseng/
Apache License 2.0
111 stars 29 forks source link

refactor: Use a more engineering-oriented error code wrapper #57

Closed lyt122 closed 9 months ago

lyt122 commented 9 months ago

Fix the issue https://github.com/CocaineCong/tangseng/issues/48.I change the files in ./app/search_engine. Use "github.com/pkg/errors" to wrap error. In a word, If a function doesn't need to return an error, print the error and stack information with logrus, otherwise wrap the error and append some information.

CocaineCong commented 9 months ago

can you fix the golangci-lint error first ? It maybe caused by the sort of import pkg.

lyt122 commented 9 months ago

can you fix the golangci-lint error first ? It maybe caused by the sort of import pkg.

I sort the import pkg , but it seems doesn't work