I'm trying to test a site out using the IBM Watson Natural Language Understanding service. I'm doing so using this tool (https://natural-language-understanding-demo.mybluemix.net/) and entering a URL from our site to test.
Using our production servers (https://www.knox.edu), I get the following error for every page of the site.
{code: 400, error: "attempt to fetch failed: :closed"}
Using a test server of the same site (https://cmstest.knox.edu/test), it all works fine though.
What would be causing the errors from our production server?
Thanks!
This error is typically caused by a site's robots.txt preventing the Watson NLU service from scraping the URL.
Check your robots.txt file to see if it's blocking user-agents (perhaps globally).
There's some additional info from a discussion of this error using the Python SDK here: https://github.com/watson-developer-cloud/python-sdk/issues/199
Looks like NLU has updated their crawling engine, the website you mentioned is crawlable from NLU now, when I ran categories call I am receiving the following output
{
"categories": [{
"score": 0.999469,
"label": "/education/graduate school/college"},{
"score": 0.497251,
"label": "/law, govt and politics/legal issues/legislation/tax laws},{
"score": 0.466882,
"label": "/travel/tourist destinations/africa"}]
}
Related
I'm trying to automatically create review apps as part of my pipeline and testing procedure when pull requests are created on the corresponding GitHub repository. When the PR is created, it appears as a review app, but doesn't actually get created.
In the DevTools console, a 404 error is there about the review-app-config. I'm not sure if this is directly related, as I've successfully created a review app on a different pipeline (with a different owner) with the same error.
This 404 error changes between the file not being available at all, or that it's returning an error. When it's the latter, the file contains the following:
{"id":"missing_version","error":"Please specify a version along with Heroku's API MIME type. For example, `Accept: application/vnd.heroku+json; version=3`.\n"}
I'm creating and managing all of the apps/pipelines with the GUI on dashboard.heroku.com. The version accept header appears to be needed for the Heroku API but I've no idea how to implement it. Any help would be greatly appreciated!
Firstly check that your app.json file is valid json. If it isn't then that will cause the deployment to fall over.
Secondly check if you have any scripts in the app.json key. If you have any here and they are incorrect then this will also cause it to hand and fall over with no warning displayed.
{
"name": "App name",
"scripts": {
"deploy": "command that won't work!!"
},
...
}
You many not need any scripts in here so it can also be empty!
{
"name": "App name",
"scripts": {},
...
}
When trying to access a specific folder in my sharepoint site's drive using the Microsoft Graph API relative pathing I get an unknown error. This exact same request worked fine just over a week ago but stopped working this week when using it again.
Test Results is a folder on my site's drive. According to OneDrive dev docs this is how the request should look: /drive/root:/path/to/folder:/children
Actual Request (site-id removed):
https://graph.microsoft.com/v1.0/sites/<site-id>/drive/root:/Test%20Results:/children
Expected Result: a list of all folders/items within the 'Test Results' folder
Actual Result:
{
"error": {
"code": "-1, Microsoft.SharePoint.Client.UnknownError",
"message": "Unknown Error",
"innerError": {
"request-id": "79b530f9-1bb9-455d-84e0-b3144fbf9c1c",
"date": "2017-11-06T18:58:11"
}
}
}
This originally used beta instead of v1.0 but it seems that the sharepoint and drive calls are no longer beta (also get the same results using beta in place of v1.0).
I've tried several different changes to my previously working request, but keep getting the unknown error. Am I missing something here since it's no longer using beta - or is this a bug on the Microsoft side? Any help is greatly appreciated.
According to this post, the issue was on the MS side. They reverted and the issue is now resolved for me.
I'm deploying a resource group to Azure consisting of a VM, a network, an Automation Account with some runbooks, among other things, using a JSON Template.
I'm getting the following errors,
New-AzureRmResourceGroupDeployment : 4:49:23 PM - Resource
Microsoft.Automation/automationAccounts/runbooks
'DeployAutomationName/AzureClassicAutomationTutorial' failed with
message '{ "code": "BadRequest", "message":
"{\"Message\":\"Invalid argument specified. Argument contentLink
cannot be null.\"}"
As well as:
New-AzureRmResourceGroupDeployment : 4:49:23 PM - Resource
Microsoft.Automation/automationAccounts/modules
'DeployAutomationName/Microsoft.WSMan.Management' failed with message
'{ "code": "BadRequest", "message": "{\"Message\":\"The
ContentLink property must be supplied in PUT or re-PUT operations.\"}"
}'
These two errors repeat for all sorts of different "Assets" ( I think that's the term) of my automation account. So for modules, runbooks, certificates, and connections.
What is a contenLink, and how can I make sure it's not Null? "ContentLink" apppears nowhere in my template, nor can I found any explanation on the internet of what exactly a contentLink is, besides this. Furthermore, I'm assuming that "PUT" or "re-PUT" is part of the rest API that delivers the template, and I have no direct control over this process either. Of what use is an error message that describes problems I have no direct control over?
This problem is synonymous with many of the difficulties I've had succesfully troubleshooting Azure templates: the error messages I get seem to be describing Azure Internals that I have no understanding of nor access too. How can I troubleshoot or debug when I don't have access to the code that is actually throwing these exception, nor the explanation of what this exception means?
Thanks! Here is my template , I would have only copied the relevant text, but I haven't a clue what is relevant and what's not:
Ok, so after poking a little bit, it looks like you are missing the runbook content (the script itself). so your runbook resource should look like this:
{
"type": "Microsoft.Automation/automationAccounts/runbooks",
"name": "[parameters('runbooks_AzureAutomationTutorial_name')]",
"apiVersion": "2015-10-31",
"location": "eastus2",
"properties": {
"runbookType": "GraphPowerShell",
"logVerbose": false,
"logProgress": false,
"publishContentLink": {
"uri": "[variables('scriptUri')]",
"version": "1.0.0.0"
}
},
"resources": [],
"dependsOn": [
"[resourceId('Microsoft.Automation/automationAccounts', parameters('automationAccounts_deployautomation_name_1'))]"
]
},
and the variable:
"variables": {
"scriptUri": "https://raw.githubusercontent.com/Azure/azure-quickstart-templates/master/101-automation-runbook-getvms/Runbooks/Get-AzureVMTutorial.ps1",
},
I can't test the whole template, as I don't have base64 values, but I believe this should solve your issue. There might be another one after this, thou ;) who knows.
Reference data: https://raw.githubusercontent.com/Azure/azure-quickstart-templates/master/101-automation-runbook-getvms/azuredeploy.json
Also, you can just remove modules from the template, as they are not required, they are all the default ones, but for them the idea is the same, you are deploying the module without giving the module data.
And you might be missing other mandatory properties here and there, looks like Automation Script doesn't really work well with Azure Automation yet. You might want to resort to Powershell to provision Automation Account, as that works perfectly fine.
P.S. I have no idea what the content of the graphical runbook looks like. But i'd guess, you can export it and upload to github, and it would work.
I have Moodle & Drupal integrated system, Drupal is primary, user is created in drupal first then it will create in moodle via web services, but I am not able to carry user picture from drupal to moodle, I don't want core fixes, need clean and systematically solution for it.
Can anyone help me?
Unfortunately there isn't an appropriate web service in core which supports this at the moment. You can see web services documented in your Moodle install in Home ▶ Site administration ▶ Plugins ▶ Web services ▶ API Documentation.
There are many ways to support this with plugins, but since you do not seem keen to go down this route, have your considered using Gravatar as a solution? There are docs on how to set this up: http://docs.moodle.org/25/en/Roles_settings#Enable_Gravatar
the first step upload the picture
localhost/moodle/webservice/upload.phptoken=9f47591ed3f6cc53720f0dc4e81&filearea=draft
Params:-
token=9f47591ed3f6cc53720f0dc4e81
filearea=draft
then you will get a response like
[
{
"component": "user",
"contextid": 5,
"userid": "2",
"filearea": "draft",
"filename": "Ali Hasans Resume.pdf",
"filepath": "/",
"itemid": 560134043,
"license": "unknown",
"author": "Admin User",
"source": "O:8:\"stdClass\":1:{s:6:\"source\";s:21:\"Ali Hasans Resume.pdf\";}"
}
]
second step
update the profile picture
localhost/moodle/webservice/rest/server.php?moodlewsrestformat=json&draftitemid=560134043&wsfunction=core_user_update_picture&wstoken=9f47591ed3f6cc53720f0dc4e81
params
moodlewsrestformat=json
draftitemid=560134043 this "draftitemid" comes from upload.php response
wsfunction=core_user_update_picture
wstoken=9f47591ed3f6cc53720f0dc4e81
if it's a success then the response will like
{
"success": true,
"profileimageurl": "http://localhost/moodle/theme/image.php/alpha/core/1609845491/u/f1",
"warnings": []
}
here I get this idea https://tracker.moodle.org/browse/MDL-56070
I've followed the procedure documented at "Adding new ways to share content"
...but keep getting an error:
Failed to preload gadget http://....
Detailed error: 400 Gadget is not trusted to render in this container. cre.iruntime:cre.iwidget.event:cre.wire:cre.iwidget:cre.iwidget.itemset:cre….ibm.connections.ee:ibm.connections.ee:container.nongadget:open-views.js:4
sharebox error http://i7.minus.com/ibiLz4SSWA5EL8.png
This looks like some sort of trust problem with external servers, but my other gadgets (embedded experience & home page gadgets) on the same external host are all working fine.
What have I missed out in the configuration?
OK, shamefully, it looks like I missed out swapping the security attribute whitelistEnabled="true" to whitelistEnabled="false" in:
/opt/IBM/WebSphere/AppServer/profiles/Dmgr01/config/cells/connectionswwCell01/LotusConnections-config/opensocial-config.xml
Here:
<security whitelistEnabled="false" featureAdminEnabled="true">
More details in this slide: How to add your own OpenSocial Gadgets to IBM Connections.
Of course, in a production system, you'll have to checkout the opensocial config using wsadmin.sh, edit, checkin & restart.