Skip to content
Putting technology to work.
Insights to guide decisions and action.

Search articles

Nobody can read the predecessor's GAS — Rebuilding inherited automation through custom development

Table of contents · 6 items

"Every morning at 9:00 AM, an aggregated summary report arrives via email out of nowhere. It's convenient, but the person who built it has already left the company, and no one knows how it works or how to stop it." We frequently hear this kind of concern from companies that have used Google Apps Script (GAS) for years. Calculations embedded in spreadsheets, automatic notifications on form submissions, midnight data synchronization routines—all seamlessly integrated into daily business operations running as if by second nature, yet not a single person in the company can open the source code or explain what it actually does. As long as they keep running, no one encounters immediate trouble; but precisely because they keep running, nobody touches them, and years pass with the code remaining a complete black box.

GAS is an exceptional tool for easily automating Google Sheets, Drive, and Gmail. At the same time, because of that ease, it is all too common for a single employee to write scripts alone without leaving documentation, leaving behind "code that runs, but nobody understands" after their transfer or resignation. What is more, 2026 is a year where multiple triggers for neglected scripts to break naturally converge. In this article, we outline from the perspective of a partner undertaking custom maintenance how to inventory inherited black-box GAS scripts and rebuild them before they grind to a halt.

Why GAS so easily becomes a "working black box"

The tendency for GAS to become dependent on individual knowledge stems from structural factors rather than technical ones.

First, anyone can write it anywhere. Because GAS allows code to be written directly behind spreadsheets or forms, individual frontline employees can create automations on the fly without going through the IT team. While this is an advantage, the flip side is that it creates a situation where no one knows how many scripts exist across the company or where they reside.

Second, scripts run invisibly via triggers. Scripts driven by time-based triggers or form submission triggers display no UI buttons on screen. Only the outcomes—incoming emails or updated rows—are visible, while the engine remains hidden in the background. Consequently, their presence goes unnoticed until a problem occurs, and when it does, teams must start from scratch just figuring out where the script is located.

Third, specifications exist solely inside the author's head. GAS written with the mindset of "as long as it works" often lacks comments and documentation, with variable names known only to the author. When that person transfers or resigns, the code remains, but the intent is lost. This "running, yet inexplicable" pattern shares the exact same nature as the anxieties surrounding inherited custom authentication discussed in our article on inspecting inherited authentication code.

In 2026, neglected GAS scripts begin to break

You might think, "If it's running fine, why bother touching it?" However, in 2026, several factors converge that cause neglected scripts to break on their own.

The clearest example is the retirement of the legacy Rhino runtime. GAS previously ran on an older JavaScript engine called Rhino, but the V8 runtime is now the standard, and Google has laid out plans to phase out Rhino progressively after January 31, 2026. Among scripts that have been neglected for a long time, some still assume Rhino, causing behavioral discrepancies or outright errors under V8. Google itself notes that incompatibilities exist between Rhino and V8, requiring scripts to be inspected and corrected during migration. In short, just because a script has always worked does not guarantee it will continue to run.

In addition, the APIs and libraries of the various services that GAS calls undergo specification changes year after year. Scripts that fail to keep pace with updates to Gmail, Drive, or external services can suddenly fail without warning. The more mission-critical a script is to business operations, the greater the impact when it fails—and often, teams only discover its existence once it breaks. This is the greatest risk of leaving black boxes unattended.

Rebuilding through custom maintenance: Visualize first, then fix

Rebuilding inherited GAS does not begin with blindly rewriting code. The essential sequence is to first make the entire ecosystem visible, and only then start fixing.

StageScopeObjective
AuditIdentify where, how many, and under what triggers scripts runInventorying existence
VisualizationCatalog each script's read, write, and send targets alongside its operational roleUnderstanding of internals
RemediationMigrate to V8, rectify risky permissions/shares, and add error handlingResilience and leak prevention
DocumentationDocument specifications, operational procedures, and rerun steps in RunbooksEliminating individual dependency
In-house enablementTransfer ownership and train internal staff to read and modify scriptsSustainable operational structure

The initial inventory and visualization deliver the greatest value. Simply compiling a clear list of how many scripts exist across the company, for what purpose, and what data they touch makes it possible to distinguish mission-critical processes from obsolete, abandoned scripts. From there, teams can prioritize high-impact scripts to implement V8 compatibility, add error handling, and correct hazardous sharing permissions. This workflow of "making operations visible and structuring them so they never fail" aligns directly with the inventory-driven approach covered in our article on automating IT team operations with the Google Workspace CLI.

And crucially, one must not overlook final documentation and in-house enablement. If you remediate the system only to lock specifications back inside a single individual's head, you will repeat the exact same cycle years later. Creating Runbooks that document specifications and operating procedures, while empowering internal staff to read and edit the code independently, constitutes the true scope of custom maintenance work.

Our case study: A former employee's GAS almost failed right before financial closing

Here is a concrete example. We received an inquiry from a mid-sized wholesale company (company name withheld), who told us: "The automated monthly accounting spreadsheet used by our finance department occasionally produces mismatched figures. The employee who built it left six months ago, and no one understands how it works." With the fiscal year-end closing approaching, they could no longer afford to leave it unaddressed.

Upon inspecting the scripts, we discovered that time-driven triggers were running across multiple spreadsheets. Parts of the code were still written in legacy Rhino syntax and designed to continue executing silently even when errors occurred, as if nothing had gone wrong. That was the reason behind the vague symptom of "numbers occasionally not matching." When fetching data failed halfway through, the script did not halt; it proceeded to aggregate incomplete numbers. Unnoticed by anyone, results had been fluctuating from month to month.

We began by cataloging all related scripts and triggers into an inventory, reviewing what each script reads and writes alongside the accounting team. We then refactored the scripts to run safely on V8, implemented safeguards that halt processing and alert staff whenever data retrieval fails, and delivered a concise single-page operational manual detailing "why, when, and what each process touches." We added no flashy features. We simply made the invisible visible and transformed code that erred silently into code that stops and notifies upon failure. This successfully averted the nightmare scenario of financial numbers quietly diverging right before closing.

Inventorying scripts while anxieties are still small

When handling inherited GAS, the most important lesson is not to panic after systems fail, but to conduct an inventory while scripts are still running. The more critical the workflow, the heavier the cost of downtime and the fewer clues left for recovery. Right now, while automations are still active, compiling a list of what runs where and remediating high-risk components in order is by far the most cost-effective path.

If you feel uneasy about mysterious scripts running every morning, struggle with unmaintained GAS left by departed staff, or want to audit what might break with the retirement of Rhino, please reach out via GleamHub's contact page. We will uncover all existing scripts and triggers, clarify which represent operational choke points and which can be safely cleaned up, and rebuild them into a secure, leak-free system that your team can maintain in-house.

Sources

Share this articleXFacebook
Kakeru Suzuki

Fascinated by the possibilities of technology, has had a deep interest in programming and digital art since student days

Turn this article's theme into your company's next step

The right way forward with Workspace for your company.

We organize data to migrate, sharing rules, and governance structures to map out the journey from implementation to daily operations.

  • Migration and initial setup
  • Sharing and permission organization
  • Governance structure
Consult on Workspace implementation and operations

You can consult with us from the initial conceptual stage. Details from this article will be carried over to the inquiry form.

Receive the latest articles by email