From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Ryan Olson Newsgroups: gmane.emacs.bugs Subject: bug#46713: 27.1; Variable binding depth exceeds max-specpdl-size in js-mode with js-indent-level 2 and indent-tabs-mode nil on new line Date: Mon, 22 Feb 2021 19:03:39 -0700 Message-ID: References: <871rd7enmz.fsf@gnus.org> Mime-Version: 1.0 Content-Type: text/plain; charset="UTF-8" Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="28486"; mail-complaints-to="usenet@ciao.gmane.io" Cc: 46713@debbugs.gnu.org To: Lars Ingebrigtsen Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Tue Feb 23 03:04:09 2021 Return-path: Envelope-to: geb-bug-gnu-emacs@m.gmane-mx.org Original-Received: from lists.gnu.org ([209.51.188.17]) by ciao.gmane.io with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1lEN3Z-0007Hh-At for geb-bug-gnu-emacs@m.gmane-mx.org; Tue, 23 Feb 2021 03:04:09 +0100 Original-Received: from localhost ([::1]:45128 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1lEN3Y-0008WN-9f for geb-bug-gnu-emacs@m.gmane-mx.org; Mon, 22 Feb 2021 21:04:08 -0500 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]:50006) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1lEN3S-0008W4-2b for bug-gnu-emacs@gnu.org; Mon, 22 Feb 2021 21:04:02 -0500 Original-Received: from debbugs.gnu.org ([209.51.188.43]:46415) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1lEN3R-0000TE-Rm for bug-gnu-emacs@gnu.org; Mon, 22 Feb 2021 21:04:01 -0500 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1lEN3R-00014P-Mi for bug-gnu-emacs@gnu.org; Mon, 22 Feb 2021 21:04:01 -0500 X-Loop: help-debbugs@gnu.org Resent-From: Ryan Olson Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Tue, 23 Feb 2021 02:04:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 46713 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: moreinfo Original-Received: via spool by 46713-submit@debbugs.gnu.org id=B46713.16140458384105 (code B ref 46713); Tue, 23 Feb 2021 02:04:01 +0000 Original-Received: (at 46713) by debbugs.gnu.org; 23 Feb 2021 02:03:58 +0000 Original-Received: from localhost ([127.0.0.1]:57961 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1lEN3O-000148-7Q for submit@debbugs.gnu.org; Mon, 22 Feb 2021 21:03:58 -0500 Original-Received: from mail-ed1-f47.google.com ([209.85.208.47]:40768) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1lEN3M-00013u-1Y for 46713@debbugs.gnu.org; Mon, 22 Feb 2021 21:03:56 -0500 Original-Received: by mail-ed1-f47.google.com with SMTP id q10so24254935edt.7 for <46713@debbugs.gnu.org>; Mon, 22 Feb 2021 18:03:56 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc; bh=fE8SaZPKrqtncWx5xugiD1A0RWV5yCE802i2948BFTw=; b=cpvJbTdtwwpXrHF+eCB7AgaqL/jVQdGmyLoON46YhfC/INwues8dDWIydEWZ1v1I3E TT8O2qz3ctTpED28Q3zkn7ruZsGTusl76IR04gDBIISGj6kgjBMcyFZckm8QjmQs0os+ riwIk1w4Aloa0rnOZI8KHXzffazHfTt3ORFWlaI/ErUPo5shIOfvgvtsOIQVul1PXCmc WZc/Oy+u67HHe40bK8MgFBC0wbxAr6GL7mPLlicp4WnWSlOFk+eBxIoG4wx734M+59Qy +hk8c67gNlepkO4ilbsEiSGwf1CH4NHS8hU+DLBn49GdWkg0Hr8Jp7s43E3rwbCQHeFE FSfA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc; bh=fE8SaZPKrqtncWx5xugiD1A0RWV5yCE802i2948BFTw=; b=RcS0ucP4kd+9VX4t5NCdEqFdhLhgh5nZ/6DHjORO51SHLqdbQpC1vnpVSTAo+WVcvG w7bRPjPPljQOAyMLee2XnR9xmbmaxnnHDQjuvn0QGwZbXVKbF75zgEuFlIr544QHRO3R VffYGpNNtf2sDspm23YFrMN6X4dVAkAZsOJsDrKBFniVplRrLT7lRpEsi0kS0lOFeHJf fBF7SElkIqbfTzk1NM6IvziJHJcGm7k9VoGUp+UY2HNjSGF7TEcRbjrZBbwdZ/T8Lu6o ZIIOEuQjIs+KVd1W1tjpp1F+uLtNFsHipA97inESM1t06T35gOsvm2xFlYfrJOLqPkAz BTYg== X-Gm-Message-State: AOAM533uM1R+/LjB68hPdGpDTKW+LTCz9uy/D3WOXjo4mPJ83NboClqJ ek4HN8zkY3hZMnoCjLGWJ+sg40E0hd7fvadQMaw= X-Google-Smtp-Source: ABdhPJw9dagxKfgN286fs7FCmfTk5opw2nw8HhuZHOOrk2XGm3c9Tkfz/DZm+kIY0Y4FCujLoorEC1YQpLwAtriYCgw= X-Received: by 2002:aa7:cb0d:: with SMTP id s13mr25145203edt.221.1614045830242; Mon, 22 Feb 2021 18:03:50 -0800 (PST) In-Reply-To: <871rd7enmz.fsf@gnus.org> X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-BeenThere: bug-gnu-emacs@gnu.org List-Id: "Bug reports for GNU Emacs, the Swiss army knife of text editors" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Original-Sender: "bug-gnu-emacs" Xref: news.gmane.io gmane.emacs.bugs:200639 Archived-At: Hi Lars, I do. I'm not sure why it takes this, but for my specific js file (with a few things replaced -- because it's company code) it has issues. Repro steps: 1. Open foo.js with emacs -Q --eval '(setq-default js-indent-level 2 indent-tabs-mode nil)' foo.js 2. Go to line 61 3. Delete brace at end of that line 4. Save 5. Add brace back 6. Press RET 7. Errors happen foo.js: import React, { useEffect } from 'react'; import { useDispatch, useSelector } from 'react-redux'; import { useHistory } from 'react-router'; import { Link } from 'react-router-dom'; import { Grid } from '@rmwc/grid'; import { getFoos, selectFoos, selectIsLoadingFoos, selectTotalTimesFoosFetched, } from 'store/slices/foos.slice'; import { clearFoo } from 'store/slices/foo.slice'; import { filterDefinitions, getUniqueFooKey, searchProperties, getFeaturesForFoo, } from './foosHelpers'; import { useFilters } from 'components/Filtering/useFilters'; import Fab from 'components/Fab'; import SortableDataTable from 'components/SortableDataTable'; import FilterBar from 'components/Filtering/FilterBar'; import useUpdateEffect from 'hooks/useUpdateEffect'; export default function FoosList() { const dispatch = useDispatch(); const history = useHistory(); const isLoading = useSelector(selectIsLoadingFoos); const foos = useSelector(selectFoos); const totalTimesFoosFetched = useSelector( selectTotalTimesFoosFetched ); const filterBag = useFilters( 'foos', foos, filterDefinitions, searchProperties ); const { getFilterByKey, clearFilter } = filterBag; const canAddFoo = useSelector(state => state.permissions.canAddFoo); function requestFoos() { dispatch(getFoos({ dispatch })); } // Get foos from the server (if needed). // It attempts to skip reloading the foos, when it can. useEffect(() => { const isFirstLoad = totalTimesFoosFetched === 0; // Since we're only checking this on mount, I think // it's safe to say that if we don't have foos and it's // not our first load (while mounting), then this would be a // place where we've invalidated foos by clearing them out. // (to force a load) const foosInvalidated = !isFirstLoad && foos.length === 0; const shouldFetch = isFirstLoad || foosInvalidated; if (shouldFetch) { requestFoos(); } }, []); // When show foos filter changes, // get foos from the server. useUpdateEffect(() => { requestFoos(); }, []); // Clear foo data from redux. useEffect(() => { // Clear foo itself. dispatch(clearFoo()); }, []); // If we initially load foos and none come back that follow // our initial filter (only show centralized foos == true) // Remove that filter and fetch foos again. useEffect(() => { if (totalTimesFoosFetched === 1 && foos.length === 0) { // NOTE: this triggers a different effect to get foos that // match this filter. clearFilter(); } }, [foos, totalTimesFoosFetched]); function getFooLink(foo) { if (hasValue(foo.fooCode)) { return `/foos/foo/fooCode/${foo.fooCode}`; } if (foo(foo)) { return `/foos/foo//${foo.id}`; } // Shouldn't get here. If all else fails, it shouldn't route anywhere. return '#'; } return ( < /> ( {foo.fooName} ), getSortValue: foo => foo.fooName, }, { headerName: 'Foo Code', getColumnValue: foo => foo.fooCode, className: globalCss.width100, }, { headerName: 'Site ID', // If there's no site id, it comes down as 0. getColumnValue: foo => foo.siteId || null, className: globalCss.width100, }, { headerName: 'Master Foo ID', getColumnValue: foo => foo.id, className: globalCss.width100, }, ].filter(Boolean), }} /> {canAddFoo && ( history.push('/foos/new')} /> )} ); } On Mon, Feb 22, 2021 at 3:36 PM Lars Ingebrigtsen wrote: > > Ryan Olson writes: > > > (error "Variable binding depth exceeds max-specpdl-size") > > back-to-indentation: internal--syntax-propertize did not move > > syntax-propertize--doneError during redisplay: > > (internal--syntax-propertize 2645) signaled (error "Variable binding > > depth exceeds max-specpdl-size") > > Do you have a recipe to reproduce this error, starting from "emacs -Q"? > > -- > (domestic pets only, the antidote for overdose, milk.) > bloggy blog: http://lars.ingebrigtsen.no