Skip to content

Fix various bugs and cleanup deprecated code#1646

Merged
james00012 merged 12 commits intomainfrom
fix/v1-cleanup
Dec 26, 2025
Merged

Fix various bugs and cleanup deprecated code#1646
james00012 merged 12 commits intomainfrom
fix/v1-cleanup

Conversation

@james00012
Copy link
Copy Markdown
Contributor

@james00012 james00012 commented Dec 25, 2025

Summary

Bug fixes

  • AWS: Fix swapped VPC filter constants and variable assignments, fix PutECRRepoPolicy calling wrong function
  • GCP: Fix newMetadata appending to wrong slice, fix error shadowing in region callbacks, fix missing error handling in storage bucket deletion
  • Database: Fix defer before nil check (would panic on error)
  • Docker: Fix multierror.Append missing first argument
  • Slack: Fix returning wrong error type
  • SSH: Fix defer-in-loop resource leak in SSH agent
  • Collections: Fix off-by-one error in GetSliceIndexValueE

Cleanup

  • Replace deprecated imports (golang.org/x/net/contextcontext, ioutilos)
  • Fix overly permissive directory permissions (0777 → 0755)
  • Remove unreachable code in lambda.go
  • Fix typos in documentation comments

- Replace golang.org/x/net/context with standard library context
- Replace ioutil.ReadFile with os.ReadFile in k8s config tests
- Fix database rows defer before nil check (would panic on error)
- Fix docker multierror.Append missing first argument
- Fix slack returning wrong error type (was fmt.Errorf, should be MessageNotFoundErr)
- Fix swapped VPC filter constants (resourceTypeFilterName/resourceIdFilterName)
- Fix PutECRRepoPolicy calling wrong function (was calling PutECRRepoLifecyclePolicyE)
- Fix database rows defer before nil check (would panic on error)
- Fix docker multierror.Append missing first argument
- Fix slack returning wrong error type (was fmt.Errorf, should be MessageNotFoundErr)
- Fix newMetadata appending to wrong slice (was appending to oldMetadata.Items instead of items)
- Fix error variable shadowing in GetAllGcpRegionsE callback
- Fix error variable shadowing in GetAllGcpZonesE callback
- Fix overly permissive directory permissions (0777 -> 0755)
- Remove dead code in lambda.go (unreachable error check)
- Fix off-by-one error in collections stringslicevalue
- Fix typos in AWS module (region.go, s3.go, rds.go)
- Fix typos in Azure module (errors.go, compute.go, nsg.go, frontdoor.go, loadbalancer.go)
- Fix typos in GCP module (gcr.go, storage.go, compute.go)
- Fix typos in K8s module (errors.go, pod.go)
- Fix typos in Terraform module (errors.go)
- Fix newMetadata appending to wrong slice (was appending to oldMetadata.Items instead of items)
- Fix error variable shadowing in GetAllGcpRegionsE callback
- Fix error variable shadowing in GetAllGcpZonesE callback
- Fix overly permissive directory permissions (0777 -> 0755)
- Remove dead code in lambda.go (unreachable error check)
- Fix off-by-one error in collections stringslicevalue
…in/fix/aws-critical-bugs', 'origin/fix/gcp-critical-bugs', 'origin/fix/doc-typos' and 'origin/fix/code-quality' into fix/v1-cleanup
- Fix SSH agent defer-in-loop resource leak (move defer inside goroutine)
- Fix GCP storage missing error handling for object deletion
- Fix typos in Azure compute and nsg modules
@james00012 james00012 changed the title Fix bugs and cleanup for v1.0.0 Fix bugs and code cleanup Dec 25, 2025
@james00012 james00012 changed the title Fix bugs and code cleanup Fix various bugs and cleanup deprecated code Dec 25, 2025
@james00012 james00012 merged commit c2d371f into main Dec 26, 2025
2 of 3 checks passed
@james00012 james00012 deleted the fix/v1-cleanup branch December 26, 2025 20:29
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