average-vr-56795
04/10/2023, 7:19 AMEnvironmentBehavior
deprecation? Defaulting to USES_ENVIRONMENTS
? Removing a default and requiring the property to be overridden in every Goal
subclass?AttributeError: type object 'AccessTokenAcquisition' has no attribute 'environment_behavior'
Looks like a plugin (presumably the toolchain one) needs migrating?hundreds-father-404
04/10/2023, 2:25 PMancient-vegetable-10556
04/10/2023, 4:36 PMaverage-vr-56795
04/10/2023, 4:51 PMmain
branch appears to not be working... It looks like it's using the latest release on pypi, maybe a release needs to happen?ancient-vegetable-10556
04/10/2023, 4:52 PMaverage-vr-56795
04/10/2023, 5:12 PMancient-vegetable-10556
04/10/2023, 5:18 PMenvironment_behavior
attribute correctly, and I’ve not seen a deprecation warning against main
with the Toolchain plugin enabled for several months now. Can you dump the error you’re seeing?average-vr-56795
04/10/2023, 5:27 PM% ./pants help
19:26:45.65 [INFO] waiting for pantsd to start...
19:26:47.00 [INFO] pantsd started
19:26:50.53 [INFO] Initializing scheduler...
19:26:50.55 [ERROR] type object 'AccessTokenAcquisition' has no attribute 'environment_behavior'
Traceback (most recent call last):
File "/Users/dwh/src/github.com/pantsbuild/pants/src/python/pants/bin/daemon_pants_runner.py", line 133, in single_daemonized_run
scheduler, options_initializer = self._core.prepare(options_bootstrapper, complete_env)
File "/Users/dwh/src/github.com/pantsbuild/pants/src/python/pants/pantsd/pants_daemon_core.py", line 181, in prepare
scheduler_restart_explanation,
File "/Users/dwh/src/github.com/pantsbuild/pants/src/python/pants/pantsd/pants_daemon_core.py", line 119, in _initialize
raise e
File "/Users/dwh/src/github.com/pantsbuild/pants/src/python/pants/pantsd/pants_daemon_core.py", line 110, in _initialize
bootstrap_options, build_config, dynamic_remote_options, self._executor
File "/Users/dwh/src/github.com/pantsbuild/pants/src/python/pants/init/engine_initializer.py", line 212, in setup_graph
is_bootstrap=is_bootstrap,
File "/Users/dwh/src/github.com/pantsbuild/pants/src/python/pants/init/engine_initializer.py", line 329, in setup_graph_extended
QueryRule(Snapshot, [PathGlobs]), # Used by the SchedulerService.
File "/Users/dwh/src/github.com/pantsbuild/pants/src/python/pants/init/engine_initializer.py", line 320, in <genexpr>
for goal_type in goal_map.values()
AttributeError: type object 'AccessTokenAcquisition' has no attribute 'environment_behavior'
Use -ldebug for more logs.
See <https://www.pantsbuild.org/v2.17/docs/troubleshooting> for common issues.
Consider reaching out for help: <https://www.pantsbuild.org/v2.17/docs/getting-help>
ancient-vegetable-10556
04/10/2023, 5:31 PMaverage-vr-56795
04/10/2023, 5:33 PMancient-vegetable-10556
04/10/2023, 7:49 PMClassVar
without a default doesn’t actually set the attribute. I’ve landed an update of the Toolchain plugin which will get published soonishly, and it doesn’t break when we stop setting the default.