[Closed] ExternalError: TypeError: $jscomp.makeIterator is not a function

What I’m trying to do:
Today I encountered an error message while running my app, please see below:

ExternalError: TypeError: $jscomp.makeIterator is not a function

What I’ve tried and what’s not working:

I think the error is caused by anvil.server.call to the server module and uplink, I didn’t make any changes to my app before the error occurs. Not sure if this is a bug that Anvil is working on resolving, please keep me updated! Thanks!

Code Sample:

# this is a formatted code snippet.
# paste your code between ``` 

Clone link:
share a copy of your app

@michaelwang925 thanks for reporting
It looks like a bug in a standard lib module somewhere.

What standard lib modules are you importing? (e.g. functools, operator, datetime etc)
Anything you can do to isolate the problem would be very handy.

I’m using the following lib in my server module:

import anvil.google.auth, anvil.google.drive, anvil.google.mail
from anvil.google.drive import app_files
import anvil.users
import anvil.tables as tables
import anvil.tables.query as q
from anvil.tables import app_tables
import anvil.server
import pandas as pd
import anvil.media
import random
from datetime import datetime, timedelta
from functools import wraps
from time import time
import numpy as np
import bcrypt
from random import SystemRandom
random = SystemRandom()
import sys
from anvil.http import url_encode
import anvil.email

The actual server function that is raising the error basically just makes calls to the data table, nothing special about it. Did you guys push some changes that might cause this issue, because on my end this is not an issue until a couple of hours ago?

no changes in the last couple of hours

This will be a client side error not a server side error

I see, on the client side I’m using the following libs:

from ._anvil_designer import ReportTemplate
from anvil import *
import plotly.graph_objects as go
import anvil.js
import anvil.server
from tabulator.Tabulator import Tabulator
import anvil.users
import anvil.tables as tables
import anvil.tables.query as q
from anvil.tables import app_tables
from datetime import datetime, timedelta, date, timezone
from …FormPopup import FormPopup
import time

So it’s probably something on my end that is causing the issue? If so any guidance on how I can approach this problem? Thanks.

Nice to see you’re using Tabulator :wink: .

It could be any of the stdlib modules.
But also anvil uses some of those modules for certain things.
And tabulator also uses those modules so all bets are off.

Perhaps you can try to:
work out the line of code on the client,
right before the error is thrown,
possibly with some debug print statements,
then we can isolate the line of code,
and I can try to work from there on reproducing.

You can also try running the app in a private browser, or a different browser to see if it’s browser related.

(and if you have a clone link you can always share it with me privately, with reproductions steps - that’ll be the quickest way)

Tabulator is fantatic! :slight_smile:
ummm… two different error pops out:

  1. ExternalError: TypeError: $jscomp.makeIterator is not a function. (In ‘$jscomp.makeIterator(W(“date”,[“year”,“month”,“day”],a,b,[null,null]))’, ‘$jscomp.makeIterator’ is undefined)
  2. ExternalError: TypeError: $jscomp.makeIterator is not a function. (In ‘$jscomp.makeIterator(W(“timedelta”,“days seconds microseconds milliseconds minutes hours weeks”.split(" "),a,b,Array(7).fill(F)))’, ‘$jscomp.makeIterator’ is undefined)

I essentially created a new branch on earlier version and the problem was gone, I think I’m embedding some HTML code and that is causing the issue, thanks anyway!

Thanks for reporting back - i’ll assume this is closed.
But let us know if you experience it again.