Where can I find my NSCocoaErrorDomain description? - macos

So I'm running a command line Swift tool to manage my dock.
The command dockutil --remove #{appName} works when doing it straight on the shell but when I execute it from within Swift I get this error.
Error Domain=NSCocoaErrorDomain Code=3587 "(null)"
Fine enough. Except that when I check up the docs there is no useful information.
You can see for yourself here: https://developer.apple.com/documentation/foundation/nscocoaerrordomain
Where would I be able to find this? Thinking to try a header file but not sure which one.

There's no good documentation by Apple with all error codes (as far as I know), but there is a very useful site: OSStatus.com
According to this site, code 3587 is only used once by Apple: NSExecutableLoadError in the Foundation framework.

Related

Windows 10 Octave 3.2.4 not running .m files

I'm trying to work my way through the Stanford open machine learning course and it requires me to run a .m file called submit1.m
I have this file and i have made sure i am in the correct directory.
When i try to run this file and submit my answer example - submit1.m(eye(5,5)
I receive this error message:
error: `submit1' undefined near line 9 column 1
Sorry in advance if I'm missing something really simple but I am a completely new to octave.
I have search for an answer on many forums but none of the given solutions are working for me.
If any more information is required please ask and i will do my best.
Thanks

Firefox Addon SDK1.17 Annotator tutorial: widget/button does not appear

I am trying to work through https://developer.mozilla.org/en-US/Add-ons/SDK/Tutorials/Annotator with jpm (https://developer.mozilla.org/en-US/Add-ons/SDK/Tools/jpm) rather than cfx, and running into difficulties:=> the button/widget that the addon adds does not appear in my browser. Not even in the Additional Tools and Features section if I go to Customize the browswer appearance.
This is the SDK v1.17, and Firefox v38.0.1 for Linux (openSuSE13.2).
I have created the structure and files with given names and contents, telling jpm to use main.js as the entry point, rather than index.js, in order to match the tutorial (which is cfx-based).
I am also passing jpm the -b PATH-TO-FIREFOX-BINARY flag, because it apparently doesn't follow the symlink at /usr/bin/firefox, but it sounds like that's a known issue.
I am also also passing jpm the -p MY-DEV-PROFILE flag because I found that with the introductory tutorial (https://developer.mozilla.org/en-US/Add-ons/SDK/Tutorials/Getting_Started_%28jpm%29) that was the only way I could get that button to show up.
But that doesn't help here, nor does leaving off that option.
The Addon Manager confirms that the extension is installed.
So I am open to suggestions. Obviously I am new to extension development, and pretty new to javascript in general.
I had also better ask while I am here: What I want to do is modify the behaviour of Firefox's Find (in page); can something like that be done with the SDK, or do I need to use the Overlay method?
Any other suggestions helpful for learning addon development would also be welcome (but should probably be done as comments, rather than Answers; let's save Answers for the original question about this tutorial button).
Thanks!
The widget api was removed in Firefox 38. For most cases you can replace widget with the button apis we introduced in Firefox 29, see this blog post for more information.
Ah, heheh, never mind.
It was just an impedence mismatch between the original cfx instructions and the jpm way of doing things.
While I had told jpm to use main.js instead of index.js, I had failed to tell it that main.js was in the "./lib/" directory instead of the root directory of the extension.
After changing the package.json to say
"main": "./lib/main.js"
it works - as far as that goes. But it turns out that the entire tutorial is no longer valid; see my (Edward's) comment on canuckistani's answer.
My subsidiary questions about whether the SDK will even do what I want (changing some Find behaviour) and any other advice/resources still stand, however.

Nitrous.io: Are there any docs for autoparts package development

I'm developing a package for nitrous.io autoparts and wonder if there is any documentation or resources for package developers.
My main problem is that autoparts is not very verbose. It's just telling me that a command failed but not why it failed or the output of that command. Is there a way to increase the verbosity? Log files? Anything?
Additionally, it's behaviour is really strange, see that gist: https://gist.github.com/phortx/9504396
The Autoparts documentation has been updated to include package development information. Here are a couple guides to help you out.
Guidelines and contribution instructions: https://github.com/nitrous-io/autoparts/blob/master/docs/contributing.md
Example part: https://github.com/nitrous-io/autoparts/blob/master/docs/example-part.rb
You can also view the documentation within your Nitrous.IO box by running the following commands within the console. You may need to run $ parts update in the console first to pull the latest documentation.
$ cat ~/.parts/autoparts/docs/contributing.md
$ cat ~/.parts/autoparts/docs/example-part.rb
Meanwhile I still not found docs, but found solutions for my problems. Actually parts is verbose, it crashes before any output. The reason for that crash which I also showed in my gist is that it can't extract .xz files.

Assist with: Interface Builder was unable to determine the type of "FileName.xib"

I'm working on source code for an IPA another developer is building for me. Hadn't made any adjustments as of yet because, knowing how temperamental the environment can be, wanted to do a test build first of the freshly unpacked project. I'm getting two errors right off the bat, saying:
Interface Builder was unable to determine the type of "FileName.xib"
("FileName" is a placeholder for the two files represented. Error message is the same for both.)
I've done some research and found this could be an XCode version issue between the developer and myself, but the developer won't be available to ask until next week, and I've got some critical testing to do this weekend. Need to get this one resolved as soon as possible.
Any advice would be helpful.
Thanks.
Cayce

Can't run Informix 4GL Interactive Debugger

I am reading through Informix 4GL By Example. Ex4 is giving a segmentation fault so I am attempting to use the debugger to find out where the program is failing, but the debugger is not working.
From within r4gl, I can compile forms and modules. But when I debug it shows a blank screen with
"Press Return to continue".
From the command line fgldb returns the following error:
fgldb: symbol lookup error: fgldb: undefined symbol: kw__numkws
DB is up and running, I can isql in and run queries.
System details:
OpenSuSE 12.1 32 bit
Informix RDS 7.50 UC6
Informix SQL DEV 7.50 UC6
Informix Growth Edition 11.70 UC5
Informix Interactive Debugger 7.50 UC6
I have searched the net, but have not found anything helpful. Any idea what's wrong?
UPDATE 1:
Thank you again for the assistance. I will be trying to install in a seperate directory and let you know. This is probably blonde but how do I install in a different directory. If I attempt to I get errors:
"INFORMIXDIR and working directory do not match."
"INFORMIXDIR = /usr/informix"
"Current working directory = /usr/informix/i4gl"
Can I edit $INFORMIXDIR to match where I want to install?
Many thanks,
Neill
UPDATE 2:
OK, so I got them both installed in /usr/informix/i4gl.
Set variables to point to that directory, not sure exactly which ones need to though because I still receive errors.
fgldb: -16326: Cannot open file 'fgldb.iem'
The /usr/informix/i4gl does contain a directory msg/en_us/0333, but that file does not exist there, while /usr/informix/msg/en_us/0333 does include the fgldb.iem file.
isql -> Query Language: Says SELECT DATABASE, but none or shown for me to select.
Kind regards
Neill
UPDATE 3:
OK, my blonde momnets are getting crazy now, but after installing into /usr/informix/i4gl, I never changed back the $INFORMIXDIR variable. I did this and then stopped and started the DB.
Now when trying to compile the demo f_custkey.per (using stores_demo db as before) form, I get errors -329 and -2810, which are to do with the database not found.
I am not sure if this is what you were talking about in your last statement. I am unsure if splitting these two into seperate directories has solved my debugger issue because now I can't compile anything, but I sense I am getting close.
Kind regards,
Neill
UPDATE 4 - Final!
OK, so it is working now.
Ran the dbaccessdemo7 command again to recreate the database and all is well in the land of nod.
Compiling and debugging ex4 now works.
Thank you so much for all the information. Learning as I go.
Kind regards
Neill
The kw_numkws issue is fixed post 7.50.UC6. So the next available fixpack will have the fix.
In the interim, IBM Technical Support has posted a "Tech Alert" advising customers to install I4GL (and ISQL) in a separate directory - option #2 suggested by Jonathan Leffler above.
The core dump/crash that you're hitting is an unfortunate bug that we found out about earlier this week. The ESQL/C code is fixed (as of today), but the fixed releases are not yet available, and won't be for a while (read 'until after Thanksgiving at the earliest'). The I4GL and ISQL code still has to be fixed (some separate, but closely related problems).
What's happened is that a structure changed size in the CSDK. I4GL will be compiling the code with the one size and the CSDK libraries are expecting another size; the difference is about 4 bytes.
This leads to hard to track memory overwriting.
The kw__numkws issue is an older problem that I thought was fixed in 7.50.UC6. I'll have to check whether that release did get the fix, and if so, how you are seeing that error still.
There are a couple of short-term options that should get you going until a fixed ensemble is available:
Reinstall I4GL (and ISQL) in the server directory. I've not proved that this will work. The concept is to make sure I4GL is using the CSDK libraries it was built with, rather than the updated 3.70.xC6 version.
Reinstall I4GL (and ISQL) in a separate directory (/opt/IBM/i4gl, perhaps). Have a suitable sqlhosts file in this directory; it might be a symlink to the one in the IDS directory. Point the I4GL programs at this alternative directory, setting LD_LIBRARY_PATH appropriately.
Option 2 ensures that I4GL is using the 'correct' CSDK. Option 1 may achieve the same result, but I'm not ready to guarantee it. Consequently, I suggest option 2.
If your I4GL code needs to run DB-Access or other programs found in the server $INFORMIXDIR, there are ways to deal with that — indicate in a comment and I'll explain, but I'd rather not confound you if there's no need. (It's not dreadfully hard, but it isn't completely trivial either.)
Option 3. is to discover what CSDK was used to create the 4GL tools and install THAT instead of the current one. In the case of 4GL 7.50FC6 it CSDK 3.70FC4.
I had problems splitting up the engine and the tools. This appears to work, so far.

Resources