Youtube API Node.js quickstart not working: "The API returned an error: Error: invalid_grant" - node.js

I followed the tutorial Node.js Quickstart, including installing the libraries googleapis and google-auth-library. I believe I followed the instructions for setting up the credentials properly to my best ability, but I lack the experience to know for sure.
I was unable to exactly follow the tutorial, specifically this line:
e. Select the application type Other, enter the name "YouTube Data API Quickstart", and click the Create button.
because the drop down selection box had no "Other" type.
I had a project using this system working in the past, but it suddenly stopped working. I had not used the program for months, so it is possible something happened in the meantime, but I also absentmindedly revoked the program's access to my Google account.
I am not using the same credentials as before it broke -- in the developer console, I not only deleted the old credentials and downloaded brand-new ones, I created a new project altogether.
Here is an image of the credential:
Of course, I downloaded and renamed the client_secret JSON as instructed.
Here are my project files:
Since I directly copied the code, I have not tried changing it, though I did look through it to make sure there were no IDs I needed to copy in or anything of the sort.
I tried looking through this article, but I had no idea where to even begin the stated debugging processes, as my only experience with OAuth, Node.js, and the YouTube API is this project, and I don't even understand how I got it working originally.
If anyone has any ideas on ways I could try fixing this, or more thorough instructions on how I could begin debugging, I would be immensely grateful.
If relevant at all, I am using the WebStorm IDE.
Screenshot of the terminal:

Related

Integrating Wagtail Into Django

I have confirmed that my Django project works perfectly. However, I am interested in integrating wagtail CMS into the project.
I am following Wagtail documentation, for proper guidance.
However, on clicking python manage.py runserver. I get the error shown below.
Wagtail Integration Error:
I have removed all my created apps from INSTALLED_APP, I have also removed them from the available URLs.
Unfortunately, non of the above method fixed the problem for me.
Your guide on how to fix this type of error will be appreciated.
I am not 100% sure of the steps you have taken. If I understand your question correctly, you added Wagtail to your Django site and then removed it again. But you are still getting an error message related to wagtailcore.Site. If that is the sequence of events, then I would say you did not fully remove all mentions of Wagtail from your code. Can you reset your code to the point before you added Wagtail using version control (git or whatever)? Or, if you have made other changes you don't want to lose, perhaps search your code for any other mentions of "wagtail".
If you would like to carry on integrating Wagtail into your site, please repeat the install steps and then post any errors you receive at that point so we can try to help. (And by the way, posting the error message inline as a code snippet makes it a lot easier for us to see the error at the same time as the description of how you got there.

Azure B2C Provider in DNN

i am using B2C provider for DNN and trying to install it as extension and it's throwing error https://i.stack.imgur.com/6faW1.png
i am trying to use multiple version as well but not installed properly and using source from https://github.com/intelequia/dnn.azureadb2cprovider/releases
Please help me out.
There was an issue in the DNN manifest file that has been solved on v1.4.7 (release https://github.com/intelequia/dnn.azureadb2cprovider/releases/tag/v1.4.7). Tracking the issue at https://github.com/intelequia/dnn.azureadb2cprovider/issues/19
I wrote the answer below before seeing this: https://github.com/intelequia/dnn.azureadb2cprovider/issues/19
Perhaps this is pertinent to your question. You might want to check with Ryan Moore (moorecreative" to see if he was able to resolve the issue.
First, please bear in mind that I am not familiar with this particular extension, but it seems as if it is "just another" authentication provide for DNN.
I'm also a little confused. The error message indicates that you've already installed th Intelequia AzureB2C provider. Is that true?
You also say "I am using" and then "trying to install it as an extension." If you are using it, that means that it is already installed as an extension, so a second attempt to install it should throw an error. But, I would think that the installer should see that problem earlier in the process.
Finally, you say "i am trying to use multiple version as well." A provider should be installed only once, and that is what the error message is telling you.
Once you have installed an authentication provider you typically enable it for a portal, and it becomes part of the authentication process.
You should read the documentation carefully, and make sure that you are trying to use the provider as the developer intended.

How do I set up a project for gcloud datastore emulator?

I'm trying to do some offline development with gcloud sdk where I want to build a Python Flask app presenting data queried from a datastore. The reason for doing it offline is simply that it's faster during development, it will be deployed online later using App Engine.
First of all: The datastore emulator is running.
However I am having trouble importing data into the datastore. I am using below from here to try and import (with my values).
curl -X POST localhost:8081/v1/projects/[PROJECT_ID]:import \
-H 'Content-Type: application/json' \
-d '{"input_url":"[ENTITY_EXPORT_FILES]"}'
The problem I am having is that it just returns
NOT FOUND
I think I know what it is but not how to solve it: I don't have a project defined in my offline environment. So I wonder, how do I set up a project in my "offline cloud SDK environment"?
The PROJECT_ID for the DataStore Emulator is set during it's installation.
I've looked a bit into it and in the link at the bottom you can see how it's done. You need to set your project-id as an environment variable, or do it with an automatic command that sets it for you.
Have a look here, I think this is what you're missing.
Hope this helps.
EDIT:
Hey again Nelumbo, I think that the NOT FOUND you received before and the NotFoundHandler are the same error. The common errors in Datastore reflect that NOT_FOUND is generated when an request attempts to update an entity that does not exist which means that it might be a malformed address.
Taking into account that your Datastore emulator starts correctly, that is my first thought of a probable cause, that we are pointing wrong or in the wrong format.
If you are completely sure that is not the case and I'm assuming you attempted different formats and double check.
I have a few other ideas of things that you can checked out in order to discard potential causes.
Are you running in a different port than 8081?
What is your cloud sdk components version? Have you updated them lately?
Have you attempted to pass manually the project ID in the curl?
Also, I'm understanding that you are importing data into the datastore emulator and everything is done locally.
Let me know.
EDIT2:
Hey Nelumbo, the only different things that I can think of that might be affecting you or for you to try is that I'm seeing that the configured port for the installation is 8432 and the one for the import is 8081 as you can see in the following docs. When you checked the environment variables was it 8432 or 8081?
Another thing that I would suggest is attempting to do this in the Cloud Shell to make sure it works and if it does raise a public issue tracker with the GCP team as it might be an issue with the Windows version.
And at least try to update the SDK version to the latest one maybe it's related to that. But yeah, as the initial question of how to add a PROJECT ID to the emulator is solved, making a new one in order to also bring more visibility to it might be helpful.

IBM Watson Speech to Text with diarization, language dropdown selector not working

I have downloaded and trying to check the new added feature of Speaker Diarization. Since it has some limitation that it will work only with language models (en-US_NarrowbandModel, es-ES_NarrowbandModel, ja-JP_NarrowbandModel), I am trying to change the drop down. But it's not changing and remain fixed at "US Broadband Model (16KHz)".
Please let me know in case I am doing any thing wrong.
After downloading the source code, I did "npm install" and run the server "npm start", then from Firefox "http://localhost:3000/" it's working correctly. But, after deployment in Bluemix, the language selector is not working. The screen comes correctly but language model is not changing. I am not able to select language models other than "US Broadband Model (16KHz)".
Please advice if I am doing anything wrong.
[Note: The previous version (without Speaker Diarization feature) downloaded and it work correctly i.e. the screen comes correctly as well as language model is changing.]
Also answered on DeveloperWorks Answers - https://developer.ibm.com/answers/questions/337891/ibm-watson-speech-to-text-with-diarization-languag.html
I think, based on your post that you have downloaded and modified a sample application. When you run the modified application locally your changes take effect, but when you deploy to bluemix they don't. In which case you need to work out what is different. Without seeing your modifications everything else is speculation.
Since your modified code would be browser side I suspect that they are not the same application as you would be running the code in the same browser. As your changes would be browser side, open up a developer view, and check the source on the page, to verify that your modified code is being returned. If isn't then you need to check how, where and what you are trying to deploy.
If you do see your modified code being returned then you will need to step through it to work out why it isn't being invoked correctly, possibly because of the side effect of other bluemix only scripts being invoked on the page.

Spotify apps dead after update?

I was developing a Spotify apps and all of the sudden Spotify restarted and updated.
Yey, great.. I got version 0.8.3.222.g317ab79d... however typing spotify:app:the_app_name doesnt work anymore. I get metadataFailed, sorry I could not find this app.
Anyone knows where I can find a downgrade?
Spotify 0.8.3 changed the app lookup slightly. The URI for getting at apps in development is now spotify:app:application-identifier-in-manifest.
This changes the behaviour in old versions, which used the application's directory name to load applications. It's also worth noting that your application must have a valid identifier and version in its manifest.json file. Remember to restart the client when changing your manifest so it notices the changes!
The keys you need to set are BundleIdentifier (which will be used to find the app) and BundleVersion. Documentation on the keys can be found here.
When you check spotify.com you can see there is a be right back message this indicated either server or application failures just hold for a few minutes/hours and return to developing after message is gone.

Resources