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

ManagedUpload.send's callback may return null instead of an Error #3904

Merged
merged 1 commit into from
Oct 13, 2023

Conversation

jaller94
Copy link
Contributor

@jaller94 jaller94 commented Sep 30, 2021

This callback's TypeScript definition says it would always return an AWSError, however, by looking at the actual code and JSDocs one notices that the err may also be null.

* @param err [Error] an error or null if no error occurred.

I don't intent to maintain this PR – I just though a code change would be more descriptive than filing an issue. Please edit this or commit it yourself if you must not have contributors without CLA signature in your code.

Checklist
  • npm run test passes
  • .d.ts file is updated
  • changelog is added, npm run add-change
  • run bundle exec rake docs:api and inspect doc/latest/index.html if documentation is changed
  • run npm run integration if integration test is changed
  • non-code related change (markdown/git settings etc)

@github-actions
Copy link

github-actions bot commented Oct 1, 2022

Greetings! We’re closing this issue because it has been open a long time and hasn’t been updated in a while and may not be getting the attention it deserves. We encourage you to check if this is still an issue in the latest release and if you find that this is still a problem, please feel free to comment or open a new issue.

@github-actions github-actions bot added the closing-soon This issue will automatically close in 4 days unless further comments are made. label Oct 1, 2022
@jaller94
Copy link
Contributor Author

jaller94 commented Oct 1, 2022

This type error still exists.

Based on recent reviews, @kuhe, could you have a look at this please?

@github-actions github-actions bot removed the closing-soon This issue will automatically close in 4 days unless further comments are made. label Oct 2, 2022
@github-actions
Copy link

github-actions bot commented Oct 3, 2023

Greetings! We’re closing this issue because it has been open a long time and hasn’t been updated in a while and may not be getting the attention it deserves. We encourage you to check if this is still an issue in the latest release and if you find that this is still a problem, please feel free to comment or open a new issue.

@github-actions github-actions bot added closing-soon This issue will automatically close in 4 days unless further comments are made. closed-for-staleness and removed closing-soon This issue will automatically close in 4 days unless further comments are made. labels Oct 3, 2023
@github-actions github-actions bot closed this Oct 5, 2023
@jaller94
Copy link
Contributor Author

This is still an issue and even the TypeScript types now have this incorrect type assumption.

send(callback?: (err: AWSError, data: ManagedUpload.SendData) => void): void;

@kuhe kuhe reopened this Oct 13, 2023
@kuhe kuhe requested a review from a team as a code owner October 13, 2023 15:42
@kuhe kuhe merged commit eb47a0f into aws:master Oct 13, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants