godotengine / godotengine/godot
Internal Script Error: Opcode 0 (Please report) when using CACHE_MODE_IGNORE_DEEP with ResourceLoader.load()
- Dominant language
- C++
- Stars
- 117k
- Forks
- 26.8k
- PR merge metrics
- PR metrics pending
Description
### Tested versions
Godot version: 4.3.stable
### System information
Godot v4.3.stable - Windows 10.0.26100 - GLES3 (Compatibility) - NVIDIA GeForce RTX 3060 (NVIDIA; 32.0.15.6636) - 12th Gen Intel(R) Core(TM) i7-12700F (20 Threads)
### Issue description
Got an internal script error Opcode 0 and it is requested that I report it so I'm reporting it. Here's the image.


### Steps to reproduce
Use ResourceLoader.load(..., CACHE_MODE_IGNORE_DEEP) to load the same Resource at least twice.
### Minimal reproduction project (MRP)
MRP attached
[opcode-0-bug.zip](https://github.com/user-attachments/files/18283798/opcode-0-bug.zip)
Update: it appears to be related to the cach_mode I was using with ResourceLoader. Loading the resource a second time causes the issue. My understanding is that my use case should be valid but correct me if I misunderstood.
Contributor guide
Research direction
Start with the attached opcode-0-bug.zip reproduction and the ResourceLoader.load() call using CACHE_MODE_IGNORE_DEEP. Reproduce loading the same resource at least twice, then trace the cache-mode handling in the Godot engine. Done means the repeated load no longer produces the internal Opcode 0 error.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- godot
- Domain
- game-dev
- Issue type
- Bug
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 35/100