Hi,
First: I have been working with the main release versions of the “arduino” framework for the “nordicnrf52” platform successfully for the past few months. However, due to several reasons,
I included my own fork of the Adafruit nrf52 Arduino Framework via the paltform_packages option via:
platform_packages =
framework-arduinoadafruitnrf52 @ https://github.com/CSC-Sendance/Adafruit_nRF52_Arduino
However, this resulted in an Assertion Error during dependency scanning (after the framework was installed):
Processing sensotronic2 (board: adafruit_feather_nrf52840; platform: nordicnrf52; framework: arduino)
-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
AssertionError: Traceback (most recent call last):
File "C:\.platformio\penv\lib\site-packages\platformio\__main__.py", line 103, in main
cli() # pylint: disable=no-value-for-parameter
File "C:\.platformio\penv\lib\site-packages\click\core.py", line 1130, in __call__
return self.main(*args, **kwargs)
File "C:\.platformio\penv\lib\site-packages\click\core.py", line 1055, in main
rv = self.invoke(ctx)
File "C:\.platformio\penv\lib\site-packages\platformio\cli.py", line 85, in invoke
return super().invoke(ctx)
File "C:\.platformio\penv\lib\site-packages\click\core.py", line 1657, in invoke
return _process_result(sub_ctx.command.invoke(sub_ctx))
File "C:\.platformio\penv\lib\site-packages\click\core.py", line 1404, in invoke
return ctx.invoke(self.callback, **ctx.params)
File "C:\.platformio\penv\lib\site-packages\click\core.py", line 760, in invoke
return __callback(*args, **kwargs)
File "C:\.platformio\penv\lib\site-packages\click\decorators.py", line 26, in new_func
return f(get_current_context(), *args, **kwargs)
File "C:\.platformio\penv\lib\site-packages\platformio\run\cli.py", line 145, in cli
process_env(
File "C:\.platformio\penv\lib\site-packages\platformio\run\cli.py", line 198, in process_env
result["succeeded"] = EnvironmentProcessor(
File "C:\.platformio\penv\lib\site-packages\platformio\run\processor.py", line 81, in process
install_project_env_dependencies(
File "C:\.platformio\penv\lib\site-packages\platformio\package\commands\install.py", line 131, in install_project_env_dependencies
_install_project_env_platform(project_env, options),
File "C:\.platformio\penv\lib\site-packages\platformio\package\commands\install.py", line 148, in _install_project_env_platform
PlatformPackageManager().install(
File "C:\.platformio\penv\lib\site-packages\platformio\package\manager\platform.py", line 62, in install
p.install_required_packages(force=force)
File "C:\.platformio\penv\lib\site-packages\platformio\platform\_packages.py", line 76, in install_required_packages
self.install_package(name, force=force)
File "C:\.platformio\penv\lib\site-packages\platformio\platform\_packages.py", line 70, in install_package
return self.pm.install(spec or self.get_package_spec(name), force=force)
File "C:\.platformio\penv\lib\site-packages\platformio\package\manager\_install.py", line 47, in install
pkg = self._install(spec, skip_dependencies=skip_dependencies, force=force)
File "C:\.platformio\penv\lib\site-packages\platformio\package\manager\_install.py", line 91, in _install
self.install_dependencies(pkg, print_header=False)
File "C:\.platformio\penv\lib\site-packages\platformio\package\manager\_install.py", line 139, in install_dependencies
self.install_dependency(dependency)
File "C:\.platformio\penv\lib\site-packages\platformio\package\manager\_install.py", line 151, in install_dependency
dependency_compatibility = PackageCompatibility.from_dependency(dependency)
File "C:\.platformio\penv\lib\site-packages\platformio\package\meta.py", line 72, in from_dependency
assert isinstance(dependency, dict)
AssertionError
============================================================
An unexpected error occurred. Further steps:
* Verify that you have the latest version of PlatformIO using
`python -m pip install -U platformio` command
* Try to find answer in FAQ Troubleshooting section
https://docs.platformio.org/page/faq/index.html
* Report this problem to the developers
https://github.com/platformio/platformio-core/issues
============================================================
I also tried using the latest official version from the main repository ( GitHub - adafruit/Adafruit_nRF52_Arduino: Adafruit code for the Nordic nRF52 BLE SoC on Arduino with and without git-hash of the last commit ) with the same message, as well as upgrading to the latest dev version of platformio, full clean, manual platform + framework deletion etc.
My first guess was that there somewhere is some kind of dependency that restricts its compatibility to a specific release. However, when copying the framework’s project to a different (unreleated to the original) git repository and using that, it magically works. With the forked repository, I also noticed I can no longer perform the PIO Task Dependencies - Update, which causes the message:
CSBaseException: VCS: Could not receive an output from `['git', 'branch']` command ({'out': '', 'err': 'fatal: not a git repository (or any of the parent directories): .git\n', 'returncode': 128})
Any hints what could cause this / how to fix it would be greatly appreciated.