Script lab custom functions feature does not work - excel-addins

When I try to access script lab custom functions feature I am greeted with message.
Script lab -> funtions
So the issue is not even in some particular function, the whole feature does not work.
Error:
{
"stack": "RichApi.Error: There was an internal error while processing the request.\n at new n (https://appsforoffice.microsoft.com/lib/beta/hosted/excel-win32-16.01.js:26:235928)\n at n.o.processRequestExecutorResponseMessage (https://appsforoffice.microsoft.com/lib/beta/hosted/excel-win32-16.01.js:26:299150)\n at https://appsforoffice.microsoft.com/lib/beta/hosted/excel-win32-16.01.js:26:297255",
"message": "There was an internal error while processing the request.",
"name": "RichApi.Error",
"code": "GeneralException",
"traceMessages": [],
"innerError": null,
"debugInfo": {
"code": "GeneralException",
"message": "There was an internal error while processing the request.",
"errorLocation": "CustomFunctionManager.register",
"statement": "v.register(...);",
"surroundingStatements": [
"var workbook = context.workbook;",
"var v = Microsoft.ExcelServices.CustomFunctionManager.newObject();",
"// >>>>>",
"v.register(...);",
"// <<<<<"
],
"fullStatements": [
"Please enable config.extendedErrorLogging to see full statements."
]
},
"httpStatusCode": 500
}

I've had this issue. I think I've seen there are differences between 2019 standalone and Office 365 subscriptions and the office js scripts that run. In my case, I was logged into a 365 enterprise subscription which reproduces the same error described. So what I did as a work-around was simply log out. And then register the function, and then log back in again. The registered function continues to work after log in.

Related

Seeks 'commentsResolvedState' API proposal, but it doesn't exist

[warning] Via 'product.json#extensionEnabledApiProposals' extension
'github.vscode-pull-request-github' wants API proposal
'commentsResolvedState' but that proposal DOES NOT EXIST. Likely, the
proposal has been finalized (check 'vscode.d.ts') or was abandoned.
I don't know what is this error msgs mean is it a bug on the current version of vscode 1.75.1?
I don't know why it's called extension even though I don't install any extension named github.vscode-pull-request-github
also I tried to (check 'vscode.d.ts') in my laptop. I dont find any file of it, there's only vscode.d. Well My code and project still works find but this error msg always appear every time I opened my vs code and kind of annoying to see. I use windows 11
This is what I found on github:
https://github.com/microsoft/vscode-pull-request-github/pull/4447/commits/f36acaff7b81f077db18e74a7c673cf249eba996
I tried to put the code in setting.json but it seems doesn't work. this is the code:
{
"name": "vscode-pull-request-github",
"displayName": "%displayName%",
"description": "%description%",
"icon": "resources/icons/github_logo.png",
"repository": {
"type": "git",
"url": "https://github.com/Microsoft/vscode-pull-request-github"
},
"bugs": {
"url": "https://github.com/Microsoft/vscode-pull-request-github/issues"
},
"enabledApiProposals": [
"tokenInformation",
"contribShareMenu",
"treeItemCheckbox",
"contribCommentPeekContext",

GitHub Classroom / GitHub Actions Autograding, how to give positive feedback by mail?

We are experimenting and evaluating GitHub Classroom and GitHub Actions for "autograding".
In our assignment students get points if unit tests are passed. So the autograding.json is comparably simple running mvn test -Dtest=testClass#testmethod.
In the default setup I am unhappy with the following points:
GitHub (Actions) sends you a mail if the build (i.e. test) fails, but you do not receive a mail, if the test succeeds. It would be very nice if students get a feedback when they pass the autograding (i.e. unit test). How can this be done?
GitHub (Actions) does not provide any details in the mail, you have to visit the actions page. It would be nicer if you could supply the number of points and maybe some one-line explanation of the error. How can this be done?
To illustrate what I would like: it would be nice if the JSON allows to specify a feedback message upon success and a feedback message upon failure and the GitHub Action mail should contain this text (if that is not possible, there should be a nicely formatted web-page displaying this text). Unfortunately I did not find any documentation on the JSON. Is there any documentation of the autograde.json?
I am also interested in other options.
Here is an example for the autograde.json currently used by us:
{
"tests": [
{
"name": "Unit Tests - Testing your Application: DoubleVector - BasicFunctionality",
"setup": "",
"run": "mvn -q -B -Dtest=DoubleVectorFromArrayTest#testBasicFunctionality test",
"input": "",
"output": "",
"comparison": "included",
"timeout": 10,
"points": 0.5
},
{
"name": "Unit Tests - Testing your Application: DoubleVector - Accuracy",
"setup": "",
"run": "mvn -q -B -Dtest=DoubleVectorFromArrayTest#testAccuracy test",
"input": "",
"output": "",
"comparison": "included",
"timeout": 10,
"points": 0.5
},
{
"name": "Unit Tests - Testing your Application: QuadraticEuation",
"setup": "",
"run": "mvn -q -B -Dtest=QuadraticEuationFromCoefficientsTest test",
"input": "",
"output": "",
"comparison": "included",
"timeout": 10,
"points": 1
}
]
}
GHA doesn't provide such a functionality out of the box. Instead, you need to either implement it by your own, or use an existing action from the marketplace.
This is one example, which lets you send emails via smpt. (Note: I didn't use the linked action myself, but expect it to work).

How to upload file to Google drive with Postman using multipart?

How could I upload file to Google Drive using Google Drive API with Postman?
I also want to set file's name and parent directory.
What have I done:
I try to upload file with following properties:
But I get 403 error:
{
"error": {
"errors": [
{
"domain": "global",
"reason": "parseError",
"message": "Parse Error"
}
],
"code": 400,
"message": "Parse Error"
}
}
I have resolved my problem, using answer on this question: How to send application/json data along with file in postman multipart/form-data post request?.
Solution
1) create file for upload to Google Drive: test.txt;
2) create file upload-options.json with file's metadata properties in json format:
{
"name": "my-uploaded-file.txt",
"parents": ["<parent-directory-id>"]
}
3) add two form-data fields:
first - upload-options.json
second - test.txt
you should consider about permission scope of your app.
add line code below help you access full control of google driver api
const SCOPES = ['https://www.googleapis.com/auth/drive'];

Unable to automate scan with Nessus 7 professional

I am evaluating the product Nessus 7 to perform vulnerability scans on the systems in my network.I am able to perform the scans successfully, but I am unable to automate it with a python Nessrest client. The following error is thrown by the nessrest client. Please help me out with this issue. Thank you.
No Title
*****************START ERROR*****************
JSON :
{"uuid": "ab4bacd2-05f6-425c-9d79-3ba3940ad1c24e51e1f403febe40",
"settings": {"text_targets": "targetIp", "file_targets": "",
"folder_id": 82, "description": "Created with REST API", "filters": [],
"launch": "ON_DEMAND", "scanner_id": "1", "emails": "", "filter_type": "",
"name": ""}}
{}
HEADERS :
{'X-Cookie': 'token=1c1c4f11e325eb19440feaaf04706d1265f347d105a06f44',
'Content-type': 'application/json', 'Accept': 'text/plain'}
URL : https://ipaddress:8834/scans
METHOD : POST
RESPONSE: 412
{
"error": "API is not available"
}
******************END ERROR******************
Traceback (most recent call last):
File "nessrest.py", line 1, in <module>
import nessrest
File "C:\Users\ballalc\nessrest.py", line 8, in <module>
scan.scan_add(targets="ipaddress")
File "C:\Users\ballalc\ness6rest.py", line 705, in scan_add
self.scan_uuid = self.res["scan"]["uuid"]
KeyError: 'scan'
Nessus has stopped implicit API Support from 7.x. You should either be using their Free Version "Nessus Home" or licensed to "SecurityCenter or Tenable.io" to use API for automation.
If you were an existing licensee, you can still use API until December, 2018 provided you don't update to Nessus Pro v7
Nessus Update ScreenShot
I know you are willing to see copy/past solution here, but not that easy just read till the end.
Also suffer for API removal, but finally developed a small java workaround class to handle all the automation and bypass Nessus API restrictions. Do not want to publish it since if they see will block it as well. They no longer want people to use Nessus and actively forcing everyone to switch to tenable.io
I can send it to anyone personally or if needed explain how it's work.

Google Storage API - Retrieve object with "/" in name

When I try to retrieve an object with a "/" in the name I get all of the file information and metadata in the response, but the link to the file itself just points to "not found". This applies to both in my code, and using the API Explorer on their website.
For example, a file named "testfolder/test.txt". It shows up in the Developer Console correctly as a pseudo-folder named "testfolder/" and a file inside named "test.txt", but when do a Get on "testfolder/test.txt", or List with prefix of "testfolder/" I run into the issue mentioned above.
I can retrieve the object file fine in gsutil and from the console. I can also retrieve the object file fine with the API if I use a symbol other than "/". It's just something about the "/" causing the link from the API response to not point to the file correctly.
Request:
GET https://www.googleapis.com/storage/v1/b/dschaffertestbucket/o/testfolder%2Ftest.txt?key={YOUR_API_KEY}
Response:
200 OK
{
"kind": "storage#object",
"id": "dschaffertestbucket/testfolder/test.txt/1429992872601000",
"selfLink": "https://www.googleapis.com/storage/v1/b/dschaffertestbucket/o/testfolder%2Ftest.txt",
"name": "testfolder/test.txt",
"bucket": "dschaffertestbucket",
"generation": "1429992872601000",
"metageneration": "1",
"contentType": "application/octet-stream",
"updated": "2015-04-25T20:14:32.600Z",
"storageClass": "STANDARD",
"size": "14",
"md5Hash": "vLrQ6JkgmdfYKJKKN1ebFQ==",
"mediaLink": "https://www.googleapis.com/download/storage/v1/b/dschaffertestbucket/o/testfolder%2Ftest.txt?generation=1429992872601000&alt=media",
"owner": {
"entity": "user-00b4903a971fb6d48e9e442442b7892dfc55f81ce026106122cb58989d926f00",
"entityId": "00b4903a971fb6d48e9e442442b7892dfc55f81ce026106122cb58989d926f00"
},
"crc32c": "Qcfj8Q==",
"etag": "CKjLz8miksUCEAE="
}
In this article you can find that Cloud Storage doesn't have a file hierarchy like Windows and Linux, and that 'gsutil' and Cloud Storage APIs simply give the illusion of one.
In your case it would be easier to just avoid including the "/" character in your file names, or use a different character instead.