X-Authentication-Warning: delorie.com: mail set sender to geda-user-bounces using -f X-Recipient: geda-user AT delorie DOT com Date: Tue, 2 Feb 2021 13:07:21 +0100 (CET) From: Roland Lutz To: "Glenn (glimrick AT epilitimus DOT com) [via geda-user AT delorie DOT com]" Subject: Re: [geda-user] recursive subsheet issue In-Reply-To: Message-ID: References: User-Agent: Alpine 2.21 (DEB 202 2017-01-01) MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII; format=flowed Reply-To: geda-user AT delorie DOT com Errors-To: nobody AT delorie DOT com X-Mailing-List: geda-user AT delorie DOT com X-Unsubscribes-To: listserv AT delorie DOT com Precedence: bulk Hi Glenn, On Mon, 1 Feb 2021, Glenn (glimrick AT epilitimus DOT com) [via geda-user AT delorie DOT com] wrote: > If traverse-hierarchy is true and a subsheet sheet has as a subsheet a > sheet from higher up in the hierarchy there is no check to prevent run > away recursion. well... in this case, the input is invalid, but you are right that gnetlist should output a useful error message instead of recursing infinitely. > Or am I missing something? If not let me know and I write a fix. I was about to suggest this. :-) > - keep a list of all sheets traversed so far up to the current sheet and > check it. The Python "set" type may come in handy. > I came across it because I am trying to figure out a way to extract the > hierarchy from the netlist. What exactly are you trying to do? Roland