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

Subscriber/Subscription.close does not support promises #212

Closed
mgabeler-lee-6rs opened this issue Aug 13, 2018 · 3 comments
Closed

Subscriber/Subscription.close does not support promises #212

mgabeler-lee-6rs opened this issue Aug 13, 2018 · 3 comments
Assignees
Labels
api: pubsub Issues related to the googleapis/nodejs-pubsub API. 🚨 This issue needs some love. triage me I really want to be triaged. type: bug Error or flaw in code with unintended results or allowing sub-optimal usage patterns.

Comments

@mgabeler-lee-6rs
Copy link
Contributor

mgabeler-lee-6rs commented Aug 13, 2018

Environment details

  • OS: Linux
  • Node.js version: 7.5.0
  • npm version: 6.3.0
  • @google-cloud/pubsub version: 0.19.0

Steps to reproduce

  1. Call subscription.close() without a callback argument
  2. Expect to receive a promise per documentation
  3. No promise is returned

UTSL: The code for the Subscription class calls promisifyAll on its members, but Subscriber, where close is implemented, does not, and so close doesn't actually adhere to its JSdoc.

@JustinBeckwith JustinBeckwith added the triage me I really want to be triaged. label Aug 14, 2018
@stephenplusplus
Copy link
Contributor

Thanks for reporting!

@callmehiphop - I can't find this method in the public-facing docs. Is this intended to be a public method?

P.S. What's "UTSL"?

@stephenplusplus stephenplusplus added priority: p2 Moderately-important priority. Fix may not be included in next release. type: bug Error or flaw in code with unintended results or allowing sub-optimal usage patterns. and removed triage me I really want to be triaged. labels Aug 14, 2018
@mgabeler-lee-6rs
Copy link
Contributor Author

What's "UTSL"?

Use The Source, Luke!

@callmehiphop
Copy link
Contributor

@stephenplusplus it is, I think when I moved the Subscriber code into a separate class it got lost. So my take away is that we need to promisify the Subscriber object and include a JSDoc tag to make close (and any other public method) show up on the docs.

@ghost ghost assigned callmehiphop Oct 10, 2018
@ghost ghost removed the priority: p2 Moderately-important priority. Fix may not be included in next release. label Oct 10, 2018
@google-cloud-label-sync google-cloud-label-sync bot added the api: pubsub Issues related to the googleapis/nodejs-pubsub API. label Jan 31, 2020
@yoshi-automation yoshi-automation added triage me I really want to be triaged. 🚨 This issue needs some love. labels Apr 6, 2020
feywind pushed a commit to feywind/nodejs-pubsub that referenced this issue Nov 12, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
api: pubsub Issues related to the googleapis/nodejs-pubsub API. 🚨 This issue needs some love. triage me I really want to be triaged. type: bug Error or flaw in code with unintended results or allowing sub-optimal usage patterns.
Projects
None yet
Development

Successfully merging a pull request may close this issue.

5 participants