Files
zeekay abbf1a0837 feat(log): replace slog DiscardHandler with luxfi/log bridge
Delete the old slog-based log package (format.go, handler.go,
handler_glog.go, logger.go, root.go) which initialized with
DiscardHandler — silently swallowing all log output including Crit
messages before calling os.Exit(1). This caused the EVM plugin
subprocess to die with no trace.

Replace with a thin bridge package (log/log.go) that re-exports
github.com/luxfi/log, ensuring:
- All geth log.Crit/Fatal calls properly log to stderr before exiting
- Default logger writes to stderr (not /dev/null)
- slog.Handler shims for backward compatibility

Also rewrite all 249 source files to import luxfi/log directly.
2026-02-10 21:07:22 -08:00

27 lines
518 B
Go

// Copyright (C) 2019-2025, Lux Industries, Inc. All rights reserved.
// See the file LICENSE for licensing terms.
package factory
import (
"github.com/luxfi/geth/plugin/evm"
"github.com/luxfi/ids"
log "github.com/luxfi/log"
"github.com/luxfi/vm/chain"
)
var (
// ID this VM should be referenced by
ID = ids.ID{'e', 'v', 'm'}
)
type Factory struct{}
func (*Factory) New(logger log.Logger) (interface{}, error) {
return &evm.VM{}, nil
}
func NewPluginVM() chain.ChainVM {
return &evm.VM{IsPlugin: true}
}