-
Notifications
You must be signed in to change notification settings - Fork 220
Closed
Labels
Description
Overview
Part of gofeed v2 development. This issue tracks modernizing dependencies, updating the Go version, and preparing the module for v2 release following Go module conventions.
Goals
- Update Go version to a more recent stable version (e.g., Go 1.21 or 1.22)
- Review and update all dependencies to their latest stable versions
- Replace dependencies with stdlib alternatives where possible
- Ensure minimal dependency footprint for the core library
- Properly version the module as v2 following Go module conventions
Tasks
Dependencies & Modernization
- Update Go version in go.mod (1.21+)
- Audit all current dependencies for:
- Security vulnerabilities
- Maintenance status (last updated, open issues)
- Whether they can be replaced with stdlib
- Update all dependencies to latest stable versions
- Run
go mod tidyto clean up - Document any dependencies that could be replaced with stdlib but require significant refactoring
v2 Module Preparation
- Change module declaration to
module github.com/mmcdole/gofeed/v2 - Update all internal imports to use /v2 suffix
- Create migration guide for v1 to v2 users
- Document breaking changes and minimum Go version requirements
Future Considerations
- Evaluate moving
cmd/ftestto a separate module to avoid pulling in CLI dependencies (currently uses urfave/cli) - see Dependency update needed #128 - Consider if any other structural changes would benefit library users
Current Dependencies Review
The library currently depends on:
PuerkitoBio/goquery- HTML parsing for feed detectionjson-iterator/go- JSON parsing performancemmcdole/goxpp- XML pull parsingurfave/cli- Only used by cmd/ftest, not the library itselfgolang.org/x/net- HTML parsing supportgolang.org/x/text- Character encoding
Version Migration Strategy
Following Go module conventions for v2:
- Module path becomes
github.com/mmcdole/gofeed/v2 - Users import with:
import "github.com/mmcdole/gofeed/v2" - v1 continues to work unchanged at
github.com/mmcdole/gofeed - This prevents breaking existing v1 users when v2 is released
References
- Related to v2 RFC: RFC: gofeed v2 – Proposed Changes #241
- Issue Dependency update needed #128 suggested making cmd/ftest a separate module
- Go modules v2 documentation: https://go.dev/blog/v2-go-modules
Labels
- v2
- enhancement
Reactions are currently unavailable