premake / premake/premake-core

Modules '_preload.lua' only executed for embedded modules

Open
#1,235 11 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
C
Stars
3.6k
Forks
654
Avg merge
1d 1h
Merged PRs (30d)
13

Description

This has caught me by surprise, but it looks like modules _preload.lua is only called for built-in embedded modules in _premake_main.lua:preloadModules.

It's a little bit weird, I would expect _preload.lua to be called when requiring any module, embedded or not. In fact, I can see that some modules have some hacks inside to workaround this issue.

Is this by design?

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start in _premake_main.lua at preloadModules and trace how embedded and non-embedded modules are loaded. Review the module hacks mentioned in the issue and determine whether preload behavior should be unified; done means the intended behavior is decided and its affected module-loading cases are covered.

Written by the indexing model from the issue text.

Assessment

Tech stack
lua
Domain
build-system
Issue type
Feature
Difficulty
5/5
Estimated time
Over a week
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
25/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.