Having cloned the latest ColdBox Zero to Hero code most things seem to work - however I am getting this error in the tests and it’s repeated over and over…
Pass: 0 Failures: 0 Errors: -1 Skipped: 0 Reset
Suites:0 Specs:0
Global Bundle Exception (2,782 ms)
Argument reference not located: grammar
436: detail : "Injecting: #thisMap.getName()#. The argument details are: #local.thisArg.toString()#.",437: type : "Injector.ArgumentNotFoundException",438: extendedInfo: "Current Injector -> #variables.injector.getName()#"439: );440: }
Does anybody recognise it? I can’t find what the problem is, nor can ChatGPT 4. I’ve looked at the Grammar installed for qb and tried changing it to MySQL but there is still a problem.
TIA
Tony Legge
This seemed to solve the problem.
// Map the MySQLGrammar
map(“MySQLGrammar”).to(“qb.models.Grammars.MySQLGrammar”);
Where was this @Eggely so I can update the source as well. or can you send us a PR please?
Hi Luis
I added this to the WireBox.cfc in config.
component extends=“coldbox.system.ioc.config.Binder” {
/**
* Configure WireBox, that’s it!
/
function configure(){
/*
* --------------------------------------------------------------------------
* WireBox Configuration (https://wirebox.ortusbooks.com)
* --------------------------------------------------------------------------
* Configure WireBox
*/
wireBox = {
// Scope registration, automatically register a wirebox injector instance on any CF scope
// By default it registeres itself on application scope
scopeRegistration : {
enabled : true,
scope : “application”, // server, cluster, session, application
key : “wireBox”
},
// DSL Namespace registrations
customDSL : { },
// Custom Storage Scopes
customScopes : { },
// Package scan locations
scanLocations : ,
// Stop Recursions
stopRecursions : ,
// Parent Injector to assign to the configured injector, this must be an object reference
parentInjector : “”,
// Register all event listeners here, they are created in the specified order
listeners :
};
// Map Bindings below
// Map the MySQLGrammar
map(“MySQLGrammar”).to(“qb.models.Grammars.MySQLGrammar”);
}
}
Regards
Tony