-
Notifications
You must be signed in to change notification settings - Fork 1.1k
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
transcribestream still doesn't work #2287
Comments
Are you following this example? |
Yes, definitely. |
Which version of Ubuntu are you using? |
Sure, lsb_release -a |
I'm able to successfully run the sample with ubuntu 22.04.1 on an amazon ec2 instance. I see that the error you are getting is preceded by a `BadRequestException'. Have you set up your credentials correctly with the right permissions to use this service? |
Greetings! It looks like this issue hasn’t been active in longer than a week. We encourage you to check if this is still an issue in the latest release. Because it has been longer than a week since the last update on this, and in the absence of more information, we will be closing this issue soon. If you find that this is still a problem, please feel free to provide a comment or add an upvote to prevent automatic closure, or if the issue is already closed, please feel free to open a new one. |
Hello, I just re-checked my permissions in IAM. I have full access to AWSPolly and AWSTranscribe. Furthermore I have been testing AWSPolly without any issues. The same credentials should work for AWSTranscribe so I assume the issue must be elsewhere and not with credentials. I have also tested the online AWS transcription via the browser and it worked although I think the browser uses separate logon. However the aws-doc-sdk-example get_transcript still doesn't work, nor does my application using the transcription. |
Still getting this after checking all permissions are good. Just giving you a heads up. |
Hey when looking through your logs the first error I see is
This is fairly a runtime dependent error and comes around because of dependencies, Are you running this from your laptop? are you running this from a EC2 instance? can you replicate your environment where this occurs in a docker image?
We set the curl option
Which is described by curl as
Which will never terminate the connection. I would suggest trying this out. |
This is running on a powerful desktop, my connection is 1Gb up and down. I tried the lowSpeedLimit and re-compiled but the exact same error occurs. Again AWS-polly works fine. I checked and get_transcript is linked with local version of curl which is very recent. The first error is actually what is below in the [DEBUG] section line 464.
|
Are you behind a corporate firewall or have some special network settings that might be blocking some of the requests? |
I'm not, just personal firewall but even if I was I'm not aware of any special port requirements to use this AWS service? AWSPolly works. Or should I run the python version of this test to rule this out? |
Trying to repro it with python would be a good idea. I'm still unsure what might be causing this and if it does(or doesn't) happen with another sdk that would be helpful to know |
Okay I've tested the following python transcription example: https://github.com/awsdocs/aws-doc-sdk-examples/tree/main/python/example_code/transcribe
It works without any issues. Are you sure that you've tested the
and it worked for you under:
|
Yes we have tested and verified it with several platforms, one of them being AL2, specific docker file:
I see that you are using mint/ubuntu earlier. Are you able to replicate your dependencies in a dockerfile? that way we could replicate it as well? |
Well I could replicate my dependencies in a docker but let me check and run your docker test to see if that works? Would I be able to run yours in my workstation? |
yeah, everything there you can/should be able to use, that would really be appreciated if you could give that a shot! give me a shout if that works or not. if it does work we can start narrowing down why your deps dont work. |
apologies, i spent a little more time on it and i can provide a more complete set of docker file and instructions now, the latter lacked how to run it. so given the dockerfile
once you have that file from the dir you can run
followed by
to actually run the example. let me know how that works for you. |
That worked:
I've looked and the containers version of curl is:
While the curl version I'm linking is master from github v8.0.0-dev and I'm linking with OpenSSL_1_1_1-stable branch. I would guess either of those two is the culprit? |
...Update: I built openssl 1.0.2k and curl v7.88.1 for linking with and the same issue manifests. BTW I have two machines that exhibit the same issue one is Linux Mint, the other Ubuntu. |
I can run it on ubuntu with the following docker image (same instructions as above).
i know that that is not the version of curl and open ssl you are referring to, but with this setup it it will work on ubuntu. If you could update this docker file to reflect your deps to reproduce it, it will be a lot easier for us to debug it as we will have a baseline of exactly what deps are wrong. |
Ok I will try to build a docker image with the issue manifested. BTW I tried to build with the stock system openssl and curl and it also has the issue. So for now the versions of openssl and curl I've used originally to locally link has the issue, the systemwide(apt) libs has the issue and even if I link the same versions as in your AL2 docker libs also has the issue. So it seems that it works in the AL2 docker container but not when linked on my machine. This seems to suggest the issue is not with these two libraries. So it's either another dependency or it's a gcc bug in my version. But now if it works in your Ubuntu 22 docker I'm really lost as to what it could be...? I will try to build over the Ubuntu 22 docker. |
...Ok it works after all when linked with the stock system libraries. What must have happened was that it was still picking up something from the locally built curl/openssl. So I think the issue is when I locally build curl/openssl something isn't quite right with the resulting libraries or linking sequence to aws-sdk. Actually I often see the following:
Even though libssl.so is there in the local directory and CMAKE_PREFIX_PATH points to that lib dir. I will replicate this now in a container. |
Here is the failing docker test case with some notes: I tried to wget the same versions of libs as in aptitude.
The workaround for now is to link with systemwide curl/openssl. |
thank you so much for providing this, happy to say i can replicate. we can start a investigation into why these deps and these versions cause this. |
Sure, my guess is that the versions of those deps should not matter much, it's some kind of linkage problem. |
...Update, I debugged my application with the workaround and I was perplexed to find that it still had this bug. Then I ran the get_transcript test from within my application and it worked. As I re-checked my logic I saw that I had prematurely called Aws::TranscribeStreamingService::Model::AudioStream::Close(), after with the my code was still writing to it. This has the same symptom as the bug. I fixed my code and now my application works. However I'm wondering if the bug isn't some kind of race condition which closes the stream prematurely. This can happen if the semaphores aren't initialized for example. |
Did you need any more help with transcribe streaming while using this sdk? |
Not at the moment, however I would not consider this resolved. I'm simply using a workaround to make it work for now. The issue still exists as I demonstrated with the docker setup when the SDK is built locally from sources. |
The issue goes away if you build your local curl with http2 support (by adding nghttp2). |
Closing this issue as it seems to be working correctly now if you use the correct version of curl/openssl:
Please let us know if you are still running into any problems with transcribestream. |
|
Describe the bug
aws-doc-sdk-examples fails with
./get_transcript
Starting...
ERROR: A complete signal was sent without the preceding empty frame.
Failed to create a stream
Failed to send an empty frame
Expected Behavior
Test should pass
Current Behavior
Exception:
ERROR: A complete signal was sent without the preceding empty frame.
Reproduction Steps
Run the
aws-doc-sdk-examples get_transcript test
Possible Solution
No response
Additional Information/Context
No response
AWS CPP SDK version used
1.10.48
Compiler and Version used
11.3.0
Operating System and version
Ubuntu
The text was updated successfully, but these errors were encountered: