Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Conversation

ml1nk
Copy link

@ml1nk ml1nk commented Jun 23, 2025

Tablewriter was updated to v1 and contains some breaking changes. In our codebase we got an error after updating some other dependency which depends on tablewriter v1.

# entgo.io/ent/cmd/internal/printer
/go/pkg/mod/entgo.io/[email protected]/cmd/internal/printer/printer.go:50:8: table.SetAutoFormatHeaders undefined (type *tablewriter.Table has no field or method SetAutoFormatHeaders)
/go/pkg/mod/entgo.io/[email protected]/cmd/internal/printer/printer.go:51:8: table.SetHeader undefined (type *tablewriter.Table has no field or method SetHeader)
/go/pkg/mod/entgo.io/[email protected]/cmd/internal/printer/printer.go:70:8: table.SetAutoFormatHeaders undefined (type *tablewriter.Table has no field or method SetAutoFormatHeaders)
/go/pkg/mod/entgo.io/[email protected]/cmd/internal/printer/printer.go:71:8: table.SetHeader undefined (type *tablewriter.Table has no field or method SetHeader)
/go/pkg/mod/entgo.io/[email protected]/cmd/internal/printer/printer.go:84:11: table.NumLines undefined (type *tablewriter.Table has no field or method NumLines)
ent/generate.go:4: running "go": exit status 1

@giautm giautm requested a review from a8m June 23, 2025 10:50
@ml1nk ml1nk force-pushed the feature/tablewriter branch from 588125c to 77e7b35 Compare June 23, 2025 15:24
@ml1nk
Copy link
Author

ml1nk commented Jun 23, 2025

Made linter happy by ignoring errors which cannot occur in this usage.

@golanglemonade
Copy link

We are seeing this issue as well:

# entgo.io/ent/cmd/internal/printer
../../../../../pkg/mod/entgo.io/[email protected]/cmd/internal/printer/printer.go:50:8: table.SetAutoFormatHeaders undefined (type *tablewriter.Table has no field or method SetAutoFormatHeaders)
../../../../../pkg/mod/entgo.io/[email protected]/cmd/internal/printer/printer.go:51:8: table.SetHeader undefined (type *tablewriter.Table has no field or method SetHeader)
../../../../../pkg/mod/entgo.io/[email protected]/cmd/internal/printer/printer.go:70:8: table.SetAutoFormatHeaders undefined (type *tablewriter.Table has no field or method SetAutoFormatHeaders)
../../../../../pkg/mod/entgo.io/[email protected]/cmd/internal/printer/printer.go:71:8: table.SetHeader undefined (type *tablewriter.Table has no field or method SetHeader)
../../../../../pkg/mod/entgo.io/[email protected]/cmd/internal/printer/printer.go:84:11: table.NumLines undefined (type *tablewriter.Table has no field or method NumLines)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants