Make sure you have the latest version of the Google Docs Writing Tracker

I have had some reports of DocsList errors from folks using the Google Docs Writing Tracker. This is because those functions have been deprecated. Several months ago, I updated the master branch with code that uses the newer DriveApp object model. I have been using that code for a few months with no errors. If you are seeing errors in the last few days caused by DocsList objects, I recommend you pull the latest version of the scripts. That should fix the problem. Please see the readme for additional details and instructions.


  1. So, I am missing something. Pulling down the latest code errors off for needing a “Project Sheet”.

    Is there an updated spreadsheet posted somewhere ?

  2. Anyone else getting errors? I keep getting a getDailyWordCount error: ReferenceError: “DocsList” is not defined. (line 152, file “Code”)

    I first did the scripts update for current users of the Writing Tracker (several iterations of that). Later I deleted ALL of the previous files and did a clean installation/setup as a new user. Every time, though, I get this same error.

    My programmer boyfriend thinks it may be due to the lack of a variable definition (e.g., “var DocsList”) in the WritingStats, so I may give that a try next. But I also wanted to check in here with the other Writing Tracker users to see if anyone else had experienced a similar problem.

  3. Oh, geez. Never mind. This whole time I’d thought I’d been grabbing the new code, but I was just copying and pasting the old scripts over and over again. I feel so completely brilliant right now. 😉

  4. I’m still seeing a single instance of DocsList in the updated WritingStats, in line 530:
    var doc2 = DocsList.getFileById(file.getId()).getContentAsString();

    Should this still be in there?

    1. Actually, the code should only ever run that line (530) if you are using plain text files instead of Google Documents. If the latter, line 530 should never execute… which is probably why some people are not seeing an error. I’ll still fix it, but that at least explains it.

  5. You’re right. Comment out line 530. I’ll put a fix in when I have chance to remove that line entirely. Line 529 takes care of what 530 does. I think I just forgot to remove the line.

  6. . . . And so that explains why I’m still getting errors, whether I comment-out line 530 or not.

    I’m working in Scrivener and doing an auto-sync between folders with .txt files.

    At least I’m learning more about coding. 😉


This site uses Akismet to reduce spam. Learn how your comment data is processed.