cdda-guide icon indicating copy to clipboard operation
cdda-guide copied to clipboard

Recursion error

Open aMegaSloth opened this issue 3 years ago • 10 comments

Not sure what is going on but there seems to be a recursion error that came up within the last 24 hours or so. I see it on most things, mostly items. The specific link/item I am looking at for example is the food processor

https://nornagon.github.io/cdda-guide/#/item/food_processor

There was a problem displaying this page. Not all versions of Cataclysm are supported by the Guide currently. Try selecting a different build.

too much recursion

Il@https://nornagon.github.io/cdda-guide/build/bundle.js:1:173094
Rl@https://nornagon.github.io/cdda-guide/build/bundle.js:1:173275
Tl@https://nornagon.github.io/cdda-guide/build/bundle.js:1:171806
kl/</<.loot<@https://nornagon.github.io/cdda-guide/build/bundle.js:1:171638
kl/<@https://nornagon.github.io/cdda-guide/build/bundle.js:1:171611
kl@https://nornagon.github.io/cdda-guide/build/bundle.js:1:171522
Rl/o<@https://nornagon.github.io/cdda-guide/build/bundle.js:1:173967
Il/</<@https://nornagon.github.io/cdda-guide/build/bundle.js:1:173178
Il/<@https://nornagon.github.io/cdda-guide/build/bundle.js:1:173162
Il@https://nornagon.github.io/cdda-guide/build/bundle.js:1:173131
Rl@https://nornagon.github.io/cdda-guide/build/bundle.js:1:173921
Rl/o<@https://nornagon.github.io/cdda-guide/build/bundle.js:1:174100
Rl@https://nornagon.github.io/cdda-guide/build/bundle.js:1:174090
Tl@https://nornagon.github.io/cdda-guide/build/bundle.js:1:171806
kl/</<.loot<@https://nornagon.github.io/cdda-guide/build/bundle.js:1:171638
kl/<@https://nornagon.github.io/cdda-guide/build/bundle.js:1:171611
kl@https://nornagon.github.io/cdda-guide/build/bundle.js:1:171522
Rl/o<@https://nornagon.github.io/cdda-guide/build/bundle.js:1:173967
Il/</<@https://nornagon.github.io/cdda-guide/build/bundle.js:1:173178
Il/<@https://nornagon.github.io/cdda-guide/build/bundle.js:1:173162
Il@https://nornagon.github.io/cdda-guide/build/bundle.js:1:173131
Rl@https://nornagon.github.io/cdda-guide/build/bundle.js:1:173921
Rl/o<@https://nornagon.github.io/cdda-guide/build/bundle.js:1:174100
Rl@https://nornagon.github.io/cdda-guide/build/bundle.js:1:174090
Tl@https://nornagon.github.io/cdda-guide/build/bundle.js:1:171806
kl/</<.loot<@https://nornagon.github.io/cdda-guide/build/bundle.js:1:171638
kl/<@https://nornagon.github.io/cdda-guide/build/bundle.js:1:171611
kl@https://nornagon.github.io/cdda-guide/build/bundle.js:1:171522
Rl/o<@https://nornagon.github.io/cdda-guide/build/bundle.js:1:173967
Il/</<@https://nornagon.github.io/cdda-guide/build/bundle.js:1:173178
Il/<@https://nornagon.github.io/cdda-guide/build/bundle.js:1:173162
Il@https://nornagon.github.io/cdda-guide/build/bundle.js:1:173131
Rl@https://nornagon.github.io/cdda-guide/build/bundle.js:1:173921
Rl/o<@https://nornagon.github.io/cdda-guide/build/bundle.js:1:174100
Rl@https://nornagon.github.io/cdda-guide/build/bundle.js:1:174090
Tl@https://nornagon.github.io/cdda-guide/build/bundle.js:1:171806
kl/</<.loot<@https://nornagon.github.io/cdda-guide/build/bundle.js:1:171638
kl/<@https://nornagon.github.io/cdda-guide/build/bundle.js:1:171611
kl@https://nornagon.github.io/cdda-guide/build/bundle.js:1:171522
Rl/o<@https://nornagon.github.io/cdda-guide/build/bundle.js:1:173967
Il/</<@https://nornagon.github.io/cdda-guide/build/bundle.js:1:173178
Il/<@https://nornagon.github.io/cdda-guide/build/bundle.js:1:173162
Il@https://nornagon.github.io/cdda-guide/build/bundle.js:1:173131
Rl@https://nornagon.github.io/cdda-guide/build/bundle.js:1:173921
Rl/o<@https://nornagon.github.io/cdda-guide/build/bundle.js:1:174100
Rl@https://nornagon.github.io/cdda-guide/build/bundle.js:1:174090
Tl@https://nornagon.github.io/cdda-guide/build/bundle.js:1:171806
kl/</<.loot<@https://nornagon.github.io/cdda-guide/build/bundle.js:1:171638
kl/<@https://nornagon.github.io/cdda-guide/build/bundle.js:1:171611
kl@https://nornagon.github.io/cdda-guide/build/bundle.js:1:171522
Rl/o<@https://nornagon.github.io/cdda-guide/build/bundle.js:1:173967
Il/</<@https://nornagon.github.io/cdda-guide/build/bundle.js:1:173178
Il/<@https://nornagon.github.io/cdda-guide/build/bundle.js:1:173162
Il@https://nornagon.github.io/cdda-guide/build/bundle.js:1:173131
Rl@https://nornagon.github.io/cdda-guide/build/bundle.js:1:173921
Rl/o<@https://nornagon.github.io/cdda-guide/build/bundle.js:1:174100
Rl@https://nornagon.github.io/cdda-guide/build/bundle.js:1:174090
Tl@https://nornagon.github.io/cdda-guide/build/bundle.js:1:171806
kl/</<.loot<@https://nornagon.github.io/cdda-guide/build/bundle.js:1:171638
kl/<@https://nornagon.github.io/cdda-guide/build/bundle.js:1:171611
kl@https://nornagon.github.io/cdda-guide/build/bundle.js:1:171522
Rl/o<@https://nornagon.github.io/cdda-guide/build/bundle.js:1:173967
Il/</<@https://nornagon.github.io/cdda-guide/build/bundle.js:1:173178
Il/<@https://nornagon.github.io/cdda-guide/build/bundle.js:1:173162
Il@https://nornagon.github.io/cdda-guide/build/bundle.js:1:173131
Rl@https://nornagon.github.io/cdda-guide/build/bundle.js:1:173921
Rl/o<@https://nornagon.github.io/cdda-guide/build/bundle.js:1:174100
Rl@https://nornagon.github.io/cdda-guide/build/bundle.js:1:174090
Tl@https://nornagon.github.io/cdda-guide/build/bundle.js:1:171806
kl/</<.loot<@https://nornagon.github.io/cdda-guide/build/bundle.js:1:171638
kl/<@https://nornagon.github.io/cdda-guide/build/bundle.js:1:171611
kl@https://nornagon.github.io/cdda-guide/build/bundle.js:1:171522
Rl/o<@https://nornagon.github.io/cdda-guide/build/bundle.js:1:173967
Il/</<@https://nornagon.github.io/cdda-guide/build/bundle.js:1:173178
Il/<@https://nornagon.github.io/cdda-guide/build/bundle.js:1:173162
Il@https://nornagon.github.io/cdda-guide/build/bundle.js:1:173131
Rl@https://nornagon.github.io/cdda-guide/build/bundle.js:1:173921
Rl/o<@https://nornagon.github.io/cdda-guide/build/bundle.js:1:174100

image

aMegaSloth avatar May 23 '22 04:05 aMegaSloth

Last working build seems to be "cdda-experimental-2022-05-21-1817", tho i didn't do any deep testing

Xtrem532 avatar May 24 '22 18:05 Xtrem532

I am also experiencing this issue. I use this tool constantly while playing, so it's kind of a bummer that it's unusable ATM.

Laraso avatar May 26 '22 13:05 Laraso

it's probably a simple fix. Just a matter of the dev getting to it when they can

opy188 avatar May 26 '22 16:05 opy188

Thanks, I'm aware of this! Haven't had time to fix yet, but hopefully will get to it in the next few days.

nornagon avatar May 31 '22 20:05 nornagon

okay, the problem here is that the aircraft_carrier_palette palette is recursive.

  1. aircraft_carrier_palette specifies that δ means crates_supplies_mechanics (sometimes)
  2. crates_supplies_mechanics uses aircraft_carrier_palette as a palette, though it only uses the Ж character

this results in infinite recursion trying to parse out the item probabilities for the aircraft_carrier_palette palette.

this could be fixed in the game's JSON by breaking this recursion and making the definition of crates_supplies_mechanics not depend on the aircraft_carrier_palette palette. i'm not sure yet how to resolve this in the Guide, maybe we need to parse palettes per-character instead of all at once? don't have time yet to dig into it, but if someone wants to fix the JSON in the game that should unbreak the Guide.

nornagon avatar Jun 01 '22 17:06 nornagon

hopefully 26b19d2 will stop the Guide from crashing, but it does not solve the underlying issue and will result in inaccurate spawn info for mapgens which use aircraft_carrier_palette.

nornagon avatar Jun 01 '22 17:06 nornagon

dang, that does seem like a bit of a complex issue. I would love to try and help with the issue if I was any sort of competent with c++

opy188 avatar Jun 01 '22 17:06 opy188

@opy188 no C++ needed, the issue in the game is with the JSON only. The guide itself is written in TypeScript.

nornagon avatar Jun 02 '22 05:06 nornagon

This seems to be fixed now

taatu avatar Jun 02 '22 16:06 taatu

It's hidden but not fixed; the spawn info is inaccurate for mapgens with aircraft_carrier_palette (or any other recursive palette)

nornagon avatar Jun 03 '22 18:06 nornagon