Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Reset the file pointer to the beginning of the file on each retry to send dags to dag server #1656

Merged
merged 1 commit into from
May 29, 2024

Conversation

rujhan-arora-astronomer
Copy link
Contributor

@rujhan-arora-astronomer rujhan-arora-astronomer commented May 29, 2024

Description

Reset the file pointer to the beginning of the file on each retry to send dags to dag server

🎟 Issue(s)

https://github.com/astronomer/issues/issues/6390

🧪 Functional Testing

Locally

📋 Checklist

  • Rebased from the main (or release if patching) branch (before testing)
  • Ran make test before taking out of draft
  • Ran make lint before taking out of draft
  • Added/updated applicable tests
  • Tested against Astro-API (if necessary).
  • Tested against Houston-API and Astronomer (if necessary).
  • Communicated to/tagged owners of respective clients potentially impacted by these changes.
  • Updated any related documentation

@rujhan-arora-astronomer
Copy link
Contributor Author

@rishkarajgi Do we need to backport this to the older cli versions too?

Copy link

codecov bot commented May 29, 2024

Codecov Report

Attention: Patch coverage is 33.33333% with 2 lines in your changes are missing coverage. Please review.

Project coverage is 86.72%. Comparing base (d858097) to head (69d2ad5).

Files Patch % Lines
pkg/fileutil/files.go 33.33% 1 Missing and 1 partial ⚠️
Additional details and impacted files
@@           Coverage Diff           @@
##             main    #1656   +/-   ##
=======================================
  Coverage   86.72%   86.72%           
=======================================
  Files         114      114           
  Lines       16707    16710    +3     
=======================================
+ Hits        14489    14492    +3     
  Misses       1329     1329           
  Partials      889      889           

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

// Reset the file pointer to the beginning of the file
_, err = file.Seek(0, io.SeekStart)
if err != nil {
return fmt.Errorf("error seeking file: %w", err)
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Couldn't find how to produce an error at this line. We can keep it uncovered acc to me.

@rujhan-arora-astronomer
Copy link
Contributor Author

@kushalmalani Which is the next CLI version and when are we releasing it?
Also, can you merge it too plz?

@kushalmalani
Copy link
Contributor

@kushalmalani Which is the next CLI version and when are we releasing it? Also, can you merge it too plz?

Sure. There is no planned release. If this is a bug fix we can do a patch release tomorrow or early next week

@kushalmalani kushalmalani merged commit 6aad882 into main May 29, 2024
3 of 5 checks passed
@kushalmalani kushalmalani deleted the 6390 branch May 29, 2024 19:45
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