Latest combo box broken, but only in on firebase?

I’ve been using the same vaadin combo box - except for versions - for over a year, deployed on both firebase hosting and also running in localhost launched with >polymer serve.

Everything else in my app seems to work fine as before with Polymer1 or Polymer2, and properly versioned elements. But the 10% of the pages with the combo box now blow up - ONLY on firebase, the combo box runs fine with >polymer serve.

Wondering if anyone else has seen this?

element-mixin.html:453 Uncaught TypeError: Cannot read property ‘instanceCount’ of undefined
at HTMLElement._initializeProperties (element-mixin.html:453)
at new PropertiesChanged (properties-changed.html:153)
at new PropertyAccessors (property-accessors.html:112)
at new TemplateStamp (template-stamp.html:121)
at new PropertyEffects (property-effects.html:1133)
at new PropertiesMixin (properties-mixin.html:105)
at new PolymerElement (element-mixin.html:425)
at new ReduxMixin (polymer-redux.html:157)
at new MyApp (my-app.html:243)
_initializeProperties @ element-mixin.html:453
PropertiesChanged @ properties-changed.html:153
PropertyAccessors @ property-accessors.html:112
TemplateStamp @ template-stamp.html:121
PropertyEffects @ property-effects.html:1133
PropertiesMixin @ properties-mixin.html:105
PolymerElement @ element-mixin.html:425
ReduxMixin @ polymer-redux.html:157
MyApp @ my-app.html:243
vaadin-themable-mixin.html:4 Uncaught TypeError: Cannot read property ‘indexOf’ of undefined
at vaadin-themable-mixin.html:4
(anonymous) @ vaadin-themable-mixin.html:4
vaadin-text-field.html:137 Uncaught TypeError: Vaadin.ThemableMixin is not a function
at vaadin-text-field.html:137
(anonymous) @ vaadin-text-field.html:137
iron-list.html:299 Uncaught TypeError: Polymer is not a function
at iron-list.html:299
at iron-list.html:1945
(anonymous) @ iron-list.html:299
(anonymous) @ iron-list.html:1945
vaadin-combo-box-item.html:42 Uncaught TypeError: Vaadin.ThemableMixin is not a function
at vaadin-combo-box-item.html:42
(anonymous) @ vaadin-combo-box-item.html:42
vaadin-overlay.html:111 Uncaught Error: Unexpected Polymer version undefined is used, expected v2.0.0 or later.
at vaadin-overlay.html:111
(anonymous) @ vaadin-overlay.html:111
vaadin-combo-box-dropdown.html:41 Uncaught TypeError: Class extends value undefined is not a constructor or null
at vaadin-combo-box-dropdown.html:41
(anonymous) @ vaadin-combo-box-dropdown.html:41
vaadin-combo-box-dropdown-wrapper.html:64 Uncaught TypeError: Class extends value undefined is not a constructor or null
at vaadin-combo-box-dropdown-wrapper.html:64
(anonymous) @ vaadin-combo-box-dropdown-wrapper.html:64
vaadin-combo-box-mixin.html:18 Uncaught TypeError: Class extends value undefined is not a constructor or null
at Object.Vaadin.ComboBoxMixin.subclass [as ComboBoxMixin]
(vaadin-combo-box-mixin.html:18)
at vaadin-combo-box.html:187

Hi, please pay attention to this error: “Unexpected Polymer version undefined is used, expected v2.0.0 or later”

So threre seems to be a timing issue: the Polymer.version is undefined by the time the element is loaded. Could you provide us with a link to the sample Firebase app where this happens?

The app is a little bit locked down due to it’s pre-alpha state, so you would have to jump through a couple hoops to test it.
https://pullmodel.com
I am only testing with chrome at this time
enter any email address (goes to dev/null)
then log in with either google or facebook or… (twitter sometimes works, github never seems to work)
then click on either ‘Topics You Message About’ or ‘Messages You Publish’ to see the error.
You may need to refresh page or return to https://pullmodel.com if the page seems to log you out
The 2 ultimate consumers of the combo box are
https://github.com/poly-on-fire/pullmodel/blob/master/public/src/my-manage-topics.html and
https://github.com/poly-on-fire/pullmodel/blob/master/public/src/my-manage-messages.html
which in turn call the element providing the combo box at
https://github.com/poly-on-fire/pullmodel/blob/master/public/src/db-combo-box.html
Again, the Polymer1 version of this app seems to perform flawlessly and the rest of my Polymer2 conversion worked fine, just not this one widget.

Someone on the slack channel tried to help but my auth failed them so I’m just going to cut my losses and migrate to Polymer/paper-dropdown-menu.

So we discussed this in Slack, and the reason was in the firebase config rewriting 404 on the missing HTML import to index.html
To eliminate the problem with the redirect, the correct config should look like this:

“rewrites”: [ {
“source”: “/!(.js|.html|.css|.json|.svg|.png|.jpg|.jpeg)”,
“destination”: “/index.html”
} ]