- Issue created by @someshver
I encountered this error while the autocomplete is being populated with text.
The error does not happen with core 10.2.5 installed.
I only see it when I update to 10.2.6.
It looks like the screenshot from someshver → also shows the version at 10.2.6 https://www.drupal.org/files/issues/2024-05-13/Untitled.png →
Full js error output
bundle.js?v=10.2.6:8 Uncaught TypeError: this[{(intermediate value)(intermediate value)(intermediate value)}[r]] is not a function
at u.computeTids (bundle.js?v=10.2.6:8:10308)
at n (bundle.js?v=10.2.6:1:101244)
at HTMLInputElement. (bundle.js?v=10.2.6:1:101687)
at HTMLInputElement.dispatch (jquery.min.js?v=3.7.1:2:40035)
at v.handle (jquery.min.js?v=3.7.1:2:38006)
u.computeTids @ bundle.js?v=10.2.6:8
n @ bundle.js?v=10.2.6:1
(anonymous) @ bundle.js?v=10.2.6:1
dispatch @ jquery.min.js?v=3.7.1:2
v.handle @ jquery.min.js?v=3.7.1:2
bundle.js?v=10.2.6:8 Uncaught TypeError: this[{(intermediate value)(intermediate value)(intermediate value)}[r]] is not a function
at u.computeTids (bundle.js?v=10.2.6:8:10308)
at n (bundle.js?v=10.2.6:1:101244)
at HTMLInputElement. (bundle.js?v=10.2.6:1:101687)
at HTMLInputElement.dispatch (jquery.min.js?v=3.7.1:2:40035)
at v.handle (jquery.min.js?v=3.7.1:2:38006)
u.computeTids @ bundle.js?v=10.2.6:8
n @ bundle.js?v=10.2.6:1
(anonymous) @ bundle.js?v=10.2.6:1
dispatch @ jquery.min.js?v=3.7.1:2
v.handle @ jquery.min.js?v=3.7.1:2
bundle.js?v=10.2.6:8 Uncaught TypeError: this[{(intermediate value)(intermediate value)(intermediate value)}[r]] is not a function
at u.computeTids (bundle.js?v=10.2.6:8:10308)
at n (bundle.js?v=10.2.6:1:101244)
at HTMLInputElement. (bundle.js?v=10.2.6:1:101687)
at HTMLInputElement.dispatch (jquery.min.js?v=3.7.1:2:40035)
at v.handle (jquery.min.js?v=3.7.1:2:38006)
u.computeTids @ bundle.js?v=10.2.6:8
n @ bundle.js?v=10.2.6:1
(anonymous) @ bundle.js?v=10.2.6:1
dispatch @ jquery.min.js?v=3.7.1:2
v.handle @ jquery.min.js?v=3.7.1:2- Assigned to brunoalmeida
- Status changed to Needs work
7 months ago 3:49pm 5 June 2024 - Merge request !48Issue #3446865 by brunoalmeida: Uncaught TypeError: this[{(intermediate... → (Open) created by brunoalmeida
- Issue was unassigned.
- Status changed to Needs review
7 months ago 4:07pm 5 June 2024 This issue happens when the Drupal field wrapper has a select and an input field. That's the typical scenario when using the "chosen" library, 'cos it will have the select default field plus the "chosen" html inputs. The DomClient._getInputType is getting lost 'cos it will find first a select and after an input, which will make the function return 'undefined' causing the error mentioned above. I created a 'else if' condition to avoid this issue.
I tried applied the diff as a patch. It applied cleanly to 3.1.33 but it did not work for me. Still seeing the error. FWIW I am not using the chosen module. I am using the Autocomplete (Tag style) widget.
_KASH_ could you please attach a screenshot of your field with this widget? I changed the widget from chosen to Autocomplete (Tag style) and it's working as expected here.
I've attached a screenshot along side the error.
The field actually works still. However the js error is causing my tests to fail. So I need to fix the js error.I am narrowing down the cause.
I've successfully updated Core to 10.2.7 and PBT to 3.1.33 and the tests pass (there is no JS error)
However, when I do a composer update for the rest of the modules that need to be brought up to date, that is when I start to encounter the error.
So, it seem that the error is somehow related to one of these updates included below. So, there is a possibility this bug does not even reside with permissions by term.
I am going to try to figure out which package update introduces the error. Could take a while...
composer update --dry-run
Loading composer repositories with package information
Updating dependencies
Lock file operations: 7 installs, 45 updates, 3 removals
- Removing phenx/php-font-lib (0.5.6)
- Removing phenx/php-svg-lib (0.5.4)
- Removing textalk/websocket (1.5.8)
- Upgrading chi-teck/drupal-code-generator (3.5.0 => 3.6.0)
- Upgrading composer/class-map-generator (1.1.1 => 1.3.3)
- Upgrading composer/composer (2.7.2 => 2.7.7)
- Upgrading composer/pcre (3.1.3 => 3.1.4)
- Upgrading composer/xdebug-handler (3.0.4 => 3.0.5)
- Upgrading dmore/chrome-mink-driver (2.9.2 => 2.9.3)
- Upgrading doctrine/event-manager (2.0.0 => 2.0.1)
- Upgrading dompdf/dompdf (v2.0.7 => v3.0.0)
- Locking dompdf/php-font-lib (1.0.0)
- Locking dompdf/php-svg-lib (1.0.0)
- Upgrading drevops/behat-steps (2.2.0 => 2.3.0)
- Upgrading drupal/better_exposed_filters (6.0.3 => 6.0.6)
- Upgrading drupal/coder (8.3.23 => 8.3.24)
- Upgrading drupal/collapsiblock (4.1.0 => 4.2.0)
- Upgrading drupal/core-dev (10.2.5 => 10.2.7)
- Upgrading drupal/entity_print (2.13.0 => 2.14.0)
- Upgrading drupal/google_tag (2.0.4 => 2.0.5)
- Upgrading drupal/jquery_ui (1.6.0 => 1.7.0)
- Upgrading drupal/jquery_ui_datepicker (2.0.0 => 2.1.0)
- Upgrading drupal/jquery_ui_slider (2.0.0 => 2.1.0)
- Upgrading drupal/jquery_ui_touch_punch (1.1.0 => 1.1.1)
- Locking drupal/js_cookie (1.0.1)
- Upgrading drupal/key (1.17.0 => 1.18.0)
- Upgrading drupal/tfa (1.6.0 => 1.7.0)
- Upgrading drupal/upgrade_status (4.2.0 => 4.3.2)
- Upgrading drupal/views_bulk_operations (4.2.6 => 4.2.7)
- Upgrading drush/drush (12.5.1 => 12.5.2)
- Upgrading grasmash/yaml-cli (3.2.0 => 3.2.1)
- Upgrading league/csv (9.15.0 => 9.16.0)
- Upgrading mglaman/phpstan-drupal (1.2.10 => 1.2.11)
- Upgrading onelogin/php-saml (4.1.0 => 4.2.0)
- Upgrading paragonie/constant_time_encoding (v2.6.3 => v2.7.0)
- Upgrading phpstan/extension-installer (1.3.1 => 1.4.1)
- Upgrading phpstan/phpstan (1.10.67 => 1.11.4)
- Upgrading phpstan/phpstan-deprecation-rules (1.1.4 => 1.2.0)
- Upgrading phpstan/phpstan-phpunit (1.3.16 => 1.4.0)
- Locking phrity/net-stream (1.3.0)
- Locking phrity/net-uri (1.3.0)
- Locking phrity/util-errorhandler (1.1.0)
- Locking phrity/websocket (1.7.3)
- Upgrading psy/psysh (v0.12.3 => v0.12.4)
- Upgrading react/promise (v3.1.0 => v3.2.0)
- Upgrading squizlabs/php_codesniffer (3.9.1 => 3.10.1)
- Upgrading symfony/browser-kit (v6.4.3 => v6.4.8)
- Upgrading symfony/config (v6.4.6 => v6.4.8)
- Upgrading symfony/css-selector (v6.4.3 => v6.4.8)
- Upgrading symfony/dom-crawler (v6.4.4 => v6.4.8)
- Upgrading symfony/http-client (v6.4.6 => v6.4.8)
- Upgrading symfony/lock (v6.4.6 => v6.4.8)
- Upgrading symfony/phpunit-bridge (v6.4.6 => v6.4.8)
- Upgrading symfony/translation (v6.4.4 => v6.4.8)
- Upgrading webflo/drupal-finder (1.2.2 => 1.3.0)
Installing dependencies from lock file (including require-dev)
Package operations: 7 installs, 45 updates, 3 removals
- Removing textalk/websocket (1.5.8)
- Removing phenx/php-svg-lib (0.5.4)
- Removing phenx/php-font-lib (0.5.6)
- Upgrading phpstan/phpstan (1.10.67 => 1.11.4)
- Upgrading phpstan/extension-installer (1.3.1 => 1.4.1)
- Upgrading symfony/http-client (v6.4.6 => v6.4.8)
- Upgrading symfony/dom-crawler (v6.4.4 => v6.4.8)
- Upgrading symfony/css-selector (v6.4.3 => v6.4.8)
- Upgrading symfony/browser-kit (v6.4.3 => v6.4.8)
- Upgrading composer/pcre (3.1.3 => 3.1.4)
- Upgrading composer/class-map-generator (1.1.1 => 1.3.3)
- Upgrading composer/xdebug-handler (3.0.4 => 3.0.5)
- Upgrading symfony/config (v6.4.6 => v6.4.8)
- Upgrading symfony/translation (v6.4.4 => v6.4.8)
- Installing phrity/util-errorhandler (1.1.0)
- Installing phrity/net-uri (1.3.0)
- Installing phrity/net-stream (1.3.0)
- Installing phrity/websocket (1.7.3)
- Upgrading dmore/chrome-mink-driver (2.9.2 => 2.9.3)
- Upgrading doctrine/event-manager (2.0.0 => 2.0.1)
- Installing dompdf/php-font-lib (1.0.0)
- Installing dompdf/php-svg-lib (1.0.0)
- Upgrading webflo/drupal-finder (1.2.2 => 1.3.0)
- Upgrading drevops/behat-steps (2.2.0 => 2.3.0)
- Upgrading drupal/jquery_ui (1.6.0 => 1.7.0)
- Upgrading drupal/jquery_ui_touch_punch (1.1.0 => 1.1.1)
- Upgrading drupal/jquery_ui_slider (2.0.0 => 2.1.0)
- Upgrading drupal/jquery_ui_datepicker (2.0.0 => 2.1.0)
- Upgrading drupal/better_exposed_filters (6.0.3 => 6.0.6)
- Installing drupal/js_cookie (1.0.1)
- Upgrading drupal/collapsiblock (4.1.0 => 4.2.0)
- Upgrading symfony/phpunit-bridge (v6.4.6 => v6.4.8)
- Upgrading symfony/lock (v6.4.6 => v6.4.8)
- Upgrading phpstan/phpstan-phpunit (1.3.16 => 1.4.0)
- Upgrading phpstan/phpstan-deprecation-rules (1.1.4 => 1.2.0)
- Upgrading mglaman/phpstan-drupal (1.2.10 => 1.2.11)
- Upgrading squizlabs/php_codesniffer (3.9.1 => 3.10.1)
- Upgrading drupal/coder (8.3.23 => 8.3.24)
- Upgrading react/promise (v3.1.0 => v3.2.0)
- Upgrading composer/composer (2.7.2 => 2.7.7)
- Upgrading drupal/core-dev (10.2.5 => 10.2.7)
- Upgrading dompdf/dompdf (v2.0.7 => v3.0.0)
- Upgrading drupal/entity_print (2.13.0 => 2.14.0)
- Upgrading drupal/google_tag (2.0.4 => 2.0.5)
- Upgrading drupal/key (1.17.0 => 1.18.0)
- Upgrading psy/psysh (v0.12.3 => v0.12.4)
- Upgrading grasmash/yaml-cli (3.2.0 => 3.2.1)
- Upgrading chi-teck/drupal-code-generator (3.5.0 => 3.6.0)
- Upgrading drush/drush (12.5.1 => 12.5.2)
- Upgrading onelogin/php-saml (4.1.0 => 4.2.0)
- Upgrading paragonie/constant_time_encoding (v2.6.3 => v2.7.0)
- Upgrading drupal/tfa (1.6.0 => 1.7.0)
- Upgrading drupal/upgrade_status (4.2.0 => 4.3.2)
- Upgrading drupal/views_bulk_operations (4.2.6 => 4.2.7)
- Upgrading league/csv (9.15.0 => 9.16.0)Well, I've done some more digging and found my issue.
Upgrading dmore/chrome-mink-driver (2.9.2 => 2.9.3)
That causes my tests to fail from the JS error.
The JS error seems to exist in my current build as well... sometimes
Uncaught TypeError: this[{(intermediate value)(intermediate value)(intermediate value)}[r]] is not a function
at u.computeTids (bundle.js?v=10.2.5:8:10308)
at n (bundle.js?v=10.2.5:1:101244)
at HTMLInputElement. (bundle.js?v=10.2.5:1:101687)
at HTMLInputElement.dispatch (jquery.min.js?v=3.7.1:2:40035)
at v.handle (jquery.min.js?v=3.7.1:2:38006)I am going to pin chrome-mink-driver to 2.9.2 and move on for now...
- 🇮🇳India someshver Panchkula
It is working perfectly with the version 3.1.30. So I think we need to compare the module with the older version to see what is changed on the newer versions. Currently I am not updating this module till the issue is not fixed.
igor mashevskyi → made their first commit to this issue’s fork.
I encountered the same issue. The patch https://git.drupalcode.org/project/permissions_by_term/-/merge_requests/... resolved the problem for some content edit form pages, but I continued experiencing the issue with other content types. Upon further investigation, I discovered that this error occurs when certain taxonomy fields are not displayed in the form.
After the latest changes in the patch, the issue should now be resolved.
- First commit to issue fork.
- 🇩🇪Germany marcoliver Neuss, NRW, Germany
Hi! I just updated the issue for against the latest state of 3.1.x-dev.
Can someone involved with this issue please verify that the issue fork still works for them?