Gil Rotem · GPRWork

Cocktail kits · Shopify Plus · Code, performance and security review · Git and branches

Spicehaus:AI agents running the operations of a Shopify Plus store

Twenty themes, and not one of them a restore point

Spicehaus sells ready-made cocktails and gift boxes. The store runs on Shopify Plus, with a theme written in Vue and compiled from source code the client did not have.

When we arrived, the store had 20 themes: one live, four copies of the same base theme, an abandoned attempt to move to a different theme, and drafts nobody remembered creating. There was no version control and no history to go back to. A third of the code in the live theme was dead: 24 of 66 components were not loaded by any page.

The "Romantic cocktail box" product page of the Spicehaus store on desktop: the box with four cocktail bottles, the name, the price and the add-to-cart button.

We went in through the code

We went in through the code, measured before fixing, stopped a fault that was breaking 26 pages in production, and handed the client a team that now works with Git, branches and Pull Requests. The work was run by an environment of AI agents I built for Spicehaus, covering code, security, optimization and visuals, working through branches and permissions.
The Spicehaus workspace, diagram: Code – One Git repository, branches and pull requests; a theme in Liquid, Vue 3 and Webpack; Security – Three leaks documented: account data, customer details, a token in the repository; Optimization – A measurement system: 5 pages, 2 screen sizes, 2 connection types, 7 loads per combination; Visual – Visual review: different screen sizes, and Hebrew right to left. Connected to: Shopify Plus, The live theme: read only, An isolated, unpublished theme, Git repository, Upload script with a blocklist, 38 external vendors, mapped. Who works in it: AI agents – Work in hierarchies and as a team, through branches and permissions, each in its own area; Gil Rotem · GPR – Set up the workspace; every fix is built and measured there first; The Spicehaus team – Visual review, code review and merge; builds from the code itself.

First, touch nothing

We pulled a copy of the live theme into our own repository and saved every pull as a commit. That gave the client change history for the first time, and let us spot when another vendor pushed a new build to the site.

The Spicehaus home page on a phone: the delivery bar, the invitation to build a box and the tasting boxes.

Measure, don't guess

The external report the client received recommended adding dimensions to the product images, but the space for the images was already reserved. We built a measurement system that loads a page under controlled conditions, measures how much it jumps and points to the component that caused the jump: five pages, two screen sizes, two connection types and seven loads for each combination.
git log of the audit branch: commits for findings F-04 to F-27, including nine requests per load that return nothing, the fix for escaping text in attributes and a sweep of 604 of 604 URLs; 31 findings and 9 decisions, every claim with how it was verified.

The answer was at the top of the page

On the home page, the top menu contributes 0.153 to the layout shift score (CLS) and on its own passes Google's threshold of 0.1. The announcement bar contributes 0.081 and the main banner 0.063. The product carousels, which had been the focus of the work until then, contribute 0.029 and came in only sixth.
Chart: what makes the home page jump, share of the CLS score on desktop, median of 7 loads. Header 0.153, announcement bar 0.081, hero banner 0.063, product carousels 0.029; Google's threshold 0.1.

A tool that refuses to write to the live site

Every fix was built in a separate, unpublished theme. The upload script reads our theme ID from a single file and refuses any other target. After every upload we pulled the live theme again and compared: zero differences, three times in a row.
PowerShell: the upload script refuses the live theme 136861647099 and writes only to the test theme 161176158459; one file pushed, the live theme pulled again, and zero files changed against the snapshot.

Placeholder blocks

We reserve in advance the place where content will appear, so nothing gets pushed around when it loads. In the most widely used component in the theme, which appears in 21 templates, the shift dropped from 0.26 to 0.11. In the home page carousels it dropped 78%, and the worst loads disappeared.
Chart: the most used component in the theme before and after, CLS score on the careers page on desktop. Before 0.261, after 0.106; Google's threshold 0.1.
Eleven home page loads, a pink dot for each load where the carousel jumped significantly: the row without the fix has such loads, the row with the fix has none.

One quotation mark took down 26 pages

The titles of 24 products include the Hebrew abbreviation for ml, which contains a quotation mark. An update that replaced Vue's development build with the production build exposed an old bug: the product name went into an HTML attribute without encoding, the quotation mark cut it off, and Vue refused to compile the page. We fixed nine places in seven files, including seven that hadn't blown up yet. It was our only write to the live site, made with the client's approval and with a restore point.
Live check of a product page before and after the fix: Vue apps mounted 3, then 8; product section 0 px, then 1,770 px; compiler errors 1, then 0; and the title with the ml abbreviation intact.

Three leaks you couldn't see on screen

An installed app printed the store's account data on every public page, code from an app that had been removed kept publishing a list of 30 past orders, and a settings file with a Shopify token was stored inside the code repository. We documented what was exposed without reading the values, and passed the decision to the client along with the way to close each one.
The source of every public page: a full_page_ext_data script with planName Shopify Plus and fields for last month's revenue, order count and support system IDs, with the values masked; and a leftover from an uninstalled app: 30 past orders, 14,807 bytes.bash: the .env file is tracked in the repository, .gitignore does not mention it, and only the variable names were read: ACCESS_TOKEN, VERSION, SHOP.

Who is really running in the store

We mapped 38 external vendors and cross-checked each one against what is actually installed. On every home page load, nine network requests came back empty, and three of them blocked the page from rendering until they failed.
Chart: who holds the code in the theme, page sections by source, live against dead. The theme itself 34 of 36 live, page builder 4 of 19, page builder 2 1 of 5, free gifts 1 of 2, box builder 0 of 1.
Network on the home page, 7 cold loads with cache off: four files return 404 in all 7 loads, three of them render-blocking, and one CSS file aborted 13 times; 9 requests per load return nothing.

The Spicehaus home page marked with each area's share of the layout shift (CLS): announcement bar 0.081, header 0.153 and hero banner 0.063.

One repository. Branches. Numbers you can check.

604 of 604 URLs in the store were checked after the fix, with zero broken. The 26 pages that fell in production were working again the same day, and nine lines of code were the entire fix.
Sweep terminal: two passes over every store URL with Vue's production compiler, 556 of 556 and 48 of 48 clean; 604 of 604 URLs clean, zero broken.

The layout shift of the most widely used component in the theme dropped 59%. The client is left with a Git repository that is the source of truth, a documented fix with a restore point, three leaks with a way to close each one, a measurement system, and 31 findings and 9 decisions, each with how it was verified.

The storefront: what Spicehaus customers see.
The Spicehaus home page on desktop: the announcement bar, the menu and the Black Friday banner.The tasting boxes on the Spicehaus home page.The gift box carousel on the Spicehaus home page.The gift box collection in the Spicehaus store.

The fix-escape.patch file in a code editor: seven files, nine changes, and in each one the product name or title passes through escape before it goes into an HTML attribute.

One line separated the repository from the site

When we got access to the theme's code repository, we compared it with the live site: 65 of 66 components were identical, and so were all the snippets and all the layout files. One line differed in the entire codebase, and it was our fix. Their upload script pushes the whole folder to the site, so the next upload would have brought back the August fault.

We had permission to push straight to master, and we didn't use it. We opened a branch and a Pull Request with nine lines, an explanation of why now, and a merge left in their hands. Permission is a capability. The decision belongs to the client.
Pull request #3, Escape merchant text in Vue-compiled attributes: open, one commit into master, an explanation that nine interpolations gain escape and why now, no conflicts, and the merge left to the team.git log as a graph: the branch gpr/escape-merchant-text-in-attributes beside master, with the team's earlier commits below them.

Today the code lives in one repository, and every change goes through a branch, review and merge before it reaches the site. The Spicehaus team holds the code and builds from it themselves, with no dependence on the previous development company.

The "Romantic cocktail box" product page on a phone after the fix, with its title and description intact.
Map of the 20 themes in the store: the live theme in red, then copies, drafts, abandoned themes and page builders, and last our isolated, unpublished theme with a dashed outline. The names are illustrative.

How many teams are working on the same code at your company?

If they keep stepping on each other's toes, tell me where it gets stuck.

Privacy on this site

This site uses cookies to improve your browsing, in line with Amendment 13 to Israel's Privacy Protection Law (2025). Full policy (Hebrew)