Error/Warning on Startup Started Happening Suddenly A Couple Days Ago

ni has a “census mode,” invoked from the command line with -census, whose function is to create a listing of installed extensions. Chapter 27.5 of the manual suggests that the program is automatically run in census mode before every story file compilation. I don’t know what code 2 means or why it would pop up that message on startup of the IDE, though.

EDIT: Perhaps @DavidK can shed some light on the subject?

If the error shows up specifically in the census mode, perhaps something’s messed up with your extensions? (A directory with the wrong permissions, for example, so ni can see it but can’t access it?)

As @FriendOfFred says, census mode is used to update the documentation pages describing installed extensions. It is run when the front-end starts, and when an extension is installed. A return code of 2 indicates that a fatal error occurred when doing this.

The census process also runs as part of compiling any project. First thing to try: open a project and run it. Go to the Results tab, then click “Console”. Can you post the text that is there?

No problem. Here you go.

E:\Games\Inform 7\Compilers\ni \
    -internal "E:\Games\Inform 7\Internal" -project "E:\Projects\Interactive Fiction\My Games\Inform 7\Miner 49er\Miner 49er.inform" -format=ulx
Inform 7 build 6M62 has started.
I've now read your source text, which is 5448 words long.
I've also read Standard Rules by Graham Nelson, which is 42655 words long.
I've also read English Language by Graham Nelson, which is 2297 words long.
I've also read Basic Help Menu by Emily Short, which is 2368 words long.
I've also read Basic Screen Effects by Emily Short, which is 2218 words long.
I've also read Menus by Emily Short, which is 2001 words long.

  The 5448-word source text has successfully been translated into an
    intermediate description which can be run through Inform 6 to complete
    compilation. There were 29 rooms and 37 things.
Inform 7 has finished.

E:\Games\Inform 7\Compilers\inform6 \
    -wSDG +include_path=..\Source,.\ auto.inf output.ulx
Inform 6.33N for Win32 (30th August 2015)
In:  1 source code files             73029 syntactic lines
 63104 textual lines               2374335 characters (ISO 8859-1 Latin1)
Allocated:
  9338 symbols (maximum 20000)    14078807 bytes of memory
Out:   Glulx story file 1.200813 (688K long):
    21 classes (maximum 200)           112 objects (maximum 640)
   230 global vars (maximum 512)     97363 variable/array space (maximum 180000)
   109 verbs (maximum 255)             455 dictionary entries (maximum 2000)
   217 grammar lines (version 2)       332 grammar tokens (unlimited)
   114 actions (maximum 200)            44 attributes (maximum 56)
    40 common props (maximum 256)       30 individual props (unlimited)
153312 characters used in text      116430 bytes compressed (rate 0.759)
     0 abbreviations (maximum 64)     3129 routines (unlimited)
 75314 instructions of code          43247 sequence points
144128 bytes writable memory used   559872 bytes read-only memory used
704000 bytes used in machine    1073037824 bytes free in machine
Compiled with 1917 suppressed warnings
Completed in 1 seconds

Compiler finished with code 0

Sadly that doesn’t tell us anything, no sign of any errors there. The next thing to try is to run ni in census mode directly from a command line prompt, and see if that shows an error. Start a command prompt, then enter these commands:

set HOME=<my documents dir>
E:\Games\Inform 7\Compilers\ni -internal "E:\Games\Inform 7\Internal" -census

In the above you’ll need to replace “<my documents dir>” with the full path to your “My Documents” directory, which should have the “Inform” directory in it. Hope that makes sense. Try that and post its output.

I hope I did this right. I had to change the directory to where I actually have Inform 7 itself installed.
Results:

Inform 7 build 6M62 has started.
Can’t open debug log
Offending filename: <C:\Users\freeman\Documents\Inform\Documentation\Census\Debu
g log.txt>

Well, that’s the answer: it can’t create that file. Try creating it manually in Windows Explorer and see what happens.

1 Like

Nope. That didn’t fix it. In fact, there was already a “Debug log.txt” file in there. I renamed it with a .bak extension then manually created a new one. I also DIDN’T create a new one to see if Inform would do it itself.
I even went so far as to make sure my ENTIRE “Documents” folder is NOT set to “Read Only” (as it was, which seems odd)
I suppose the next step would be a total un- and re-install.
Could it be a problem in the Registry?

I’ve never ever found uninstalling and reinstalling solved any problems. You’re welcome to try, of course, but I would bet that it won’t help. It seems unlikely that it’s a registry problem, either.

I would try deleting the entirety of the “Inform” folder from “My Documents” (or maybe just rename it to something else if you’re feeling cautious) and then starting Inform 7.

1 Like

Yeah. Un-/re-installing it didn’t help.
Removing the folder didn’t help.
I dunno … Like I said, this doesn’t appear to affect the functionality at all.

It’s compiling successfully, but it’s failing to update the list of installed extensions. That’s the functionality you’ve lost.

(I have no idea why. Windows is funny.)

1 Like

Well, look at that.
That is indeed happening. The list is empty.
I can DL all extensions, but then when I restart the IDE they’re all gone again.
However, if I click the Public Library tab then “Everything,” it shows all the extensions.
I can “Include” any of them and the game compiles just fine.
hmmm
I wonder how that happened. And even MORESO, how to fix it.

My first guess is some sort of permissions problem with your “My Documents” directory. To test this, try:

set HOME=C:\Temp
E:\Games\Inform 7\Compilers\ni -internal "E:\Games\Inform 7\Internal" -census

(Or whatever your temp directory is if not c:\temp). Does that succeed or not?

That gives me the result: “Inform 7 build 6M62 has started.”
… but that’s it.
(incidentally, I did un-/re-install it, and this time put it in C:\Program Files\Inform 7)
And I have NOW noticed that I cannot access the help for any of the extensions. Now THAT is indeed a problem. Kinda … I have found this website where I can access the documentation for them >> https://i7el.herokuapp.com/

As to permissions …
I was looking into that a couple days ago.
For some reason, EVERY folder on EVERY drive in my system is set to ‘Read Only,’ and even tho I’m Admin, it won’t let me change that. I mean … It SAYS it’s changing it, but then the folders remain Read Only.
However, all the files are just fine, not Read Only. It’s only the folders that are Read Only.
I fought this for several hours, even going to the lengths of taking ownership of C:\ away from TrustedInstaller. … Which I learned after doing so is a bad idea. So now I’ve changed it back.
Ultimately, I still have no idea what’s up with that. I did recently clone my 128 gig SSD (boot drive) to a 500 gig SSD (again as the boot drive) but I don’t see how that could have caused something like this. Frankly, I’m not even sure if all the folders were previously set to Read Only. From what I’ve read, it really shouldn’t matter as long as the files IN the folders aren’t read only. I’ve not had difficulties with anything else.
Could it be that I’m running the updated IDE that was put out earlier this year. I DLed it on June 9th, but didn’t actually install it until a few weeks ago.
I see now tho that there is another update (Beta) on the GitHub page from July 13th. So I’ll DL that and install it, see what happens.
Alternatively, I could roll back to the “official” 6M62 release on the Inform website, from 2015.

Well, that’ll do it. No version of Inform is going to work under those conditions.

it really shouldn’t matter as long as the files IN the folders aren’t read only

If an application deletes a file and then tries to recreate it, it will fail.

EDIT-ADD: Ignore this comment. I didn’t understand what Windows was telling you. Gavin’s comment explains that.

Except that Inform 7 is the only app on my computer having a problem.
I’ve installed A LOT of other software since the SDD swap, and none of it is having any problems writing to C:\ , D:\ , or E:\ … except Inform 7

WELL!! Problem “semi-solved.” … Time to file a bug report methinx.
I completely uninstalled Inform, again. This time I also ran CCleaner to clean the registry, then went in and manually removed all remaining traces. And there were several.
I reverted to the official Inform 7 from the Inform website. The one from 2015.
It works just fine. No errors. All extensions listed and help is accessible.
As such, I reckon it’s pretty clearly an issue with the updated IDE, which @DavidK is maintaining.
Shall I file an official bug report on GitHub David, or will this suffice?
EDIT: The one from 2015 installs to “Program Files (x86)” while the updated one from a couple months ago installs to “Program Files.” … I also tried installing the one from a couple month ago on top of / over the “official” one in the x86 folder, but that again broke it.

System: (all drivers up to date)
Win 7 64-bit Pro
AMD FX6300 CPU
Radeon RX580 GPU
16 gigs DDR3 1333 RAM
MSI 970A-G43 mobo
Focusrite Scarlett 2i4 audio interface
500 gig SSD boot drive
500 gig data HDD
4 TB data HDD

You’re misinterpreting that. The square box doesn’t mean “this folder is read only” it means “there might be some files that are read only but I haven’t checked”. It then lets you untick the box to force all files to not be read-only, or tick the box to force all files to be read-only, but then regardless it will always show the square box afterwards.

A folder itself can’t be read-only on Windows, that’s not how those things are controlled. Instead it’s the Security tab that affects the real permissions of the folder. But do not, I repeat do not touch that tab – you have already proved that there is nothing wrong there by being able to create a file there yourself, and messing with it will only lead to grief unless you know precisely what you’re doing.

2 Likes

Working through all this in order:

Well, that’s good news: that is what I would expect from a correct run with “-census”. So if this works with HOME set to a directory other than “My Documents”, but fails when it is set to “My Documents”, this strongly suggests a permissions problem with “My Documents”.

Well, yes, that is what I would expect. What the census run does is, primarily, generate the documentation for the extensions from the extensions themselves.

That isn’t what I meant by permissions. As Gavin said, the read-only check-box on the properties dialog doesn’t mean quite what you think it does for directories, only files. I am talking about the contents of the Security tab in the properties dialog.

That is surprising. However, you’re changing so many things at once I think it’s easy to loose track of what change has had what effect.

If you want to dig into this further, I suggest the following: install the build from inform7.com, and try running ni from the command line with -census as discussed above, with HOME set to both “My Documents” and to some other directory. Then install the beta version from github.com and try the above again. Then let me know the results.

That’s not a good idea. The version from inform7.com is a 32-bit build, so goes in “Program Files (x86)”. The new beta on github.com is 64-bit, so belongs in “Program Files”.

2 Likes