I have tried adding a secret to the vault from DbPlan, but it isn't working.
class DbPlan(MarketplaceDbPlan):
# pylint: disable=useless-super-delegation
def __init__(self):
super().__init__()
self.ui_text_prefix = "roy_uux" # Will be used for all self.ui_text_elements
self.vault_info = [vault_info.VaultInfo("key_prefix", "key_basename", {"hmac_secret": secrets.token_hex()}, allow_editable=False)]
This is the error I get when I run q2 run_db_plan.
Traceback (most recent call last):
File "/home/roy/boost-stack/q2/q2-venv/bin/q2", line 8, in <module>
sys.exit(main())
File "/home/roy/boost-stack/q2/q2-venv/lib/python3.9/site-packages/q2_sdk/core/q2.py", line 36, in main
entrypoint_runner.execute()
File "/home/roy/boost-stack/q2/q2-venv/lib/python3.9/site-packages/q2_sdk/core/cli/entrypoint_runner.py", line 168, in execute
LOOP.run_until_complete(handle_coro)
File "/usr/lib/python3.9/asyncio/base_events.py", line 642, in run_until_complete
return future.result()
File "/home/roy/boost-stack/q2/q2-venv/lib/python3.9/site-packages/q2_sdk/entrypoints/run_db_plan.py", line 61, in handle
await run_db_plan(self.logger, db_plan, self.hq_credentials, form_name, form_id=form_id)
File "/home/roy/boost-stack/q2/q2-venv/lib/python3.9/site-packages/q2_sdk/entrypoints/run_db_plan.py", line 69, in run_db_plan
await db_plan.install(logger, hq_credentials, form_name, form_id=form_id)
File "/home/roy/boost-stack/q2/q2-venv/lib/python3.9/site-packages/q2_marketplace/models/db_plan.py", line 29, in install
await super().install(logger, hq_credentials, form_name)
File "/home/roy/boost-stack/q2/q2-venv/lib/python3.9/site-packages/q2_sdk/core/install_steps/db_plan.py", line 198, in install
await item.install()
File "/home/roy/boost-stack/q2/q2-venv/lib/python3.9/site-packages/q2_sdk/core/install_steps/vault_info.py", line 95, in install
self.q2_vault_obj.client.write(
File "/home/roy/boost-stack/q2/q2-venv/lib/python3.9/site-packages/hvac/v1/__init__.py", line 231, in write
return self._adapter.post('/v1/{0}'.format(path), json=kwargs, wrap_ttl=wrap_ttl)
File "/home/roy/boost-stack/q2/q2-venv/lib/python3.9/site-packages/hvac/adapters.py", line 107, in post
return self.request('post', url, **kwargs)
File "/home/roy/boost-stack/q2/q2-venv/lib/python3.9/site-packages/hvac/adapters.py", line 342, in request
response = super(JSONAdapter, self).request(*args, **kwargs)
File "/home/roy/boost-stack/q2/q2-venv/lib/python3.9/site-packages/hvac/adapters.py", line 287, in request
response = self.session.request(
File "/home/roy/boost-stack/q2/q2-venv/lib/python3.9/site-packages/requests/sessions.py", line 515, in request
prep = self.prepare_request(req)
File "/home/roy/boost-stack/q2/q2-venv/lib/python3.9/site-packages/requests/sessions.py", line 443, in prepare_request
p.prepare(
File "/home/roy/boost-stack/q2/q2-venv/lib/python3.9/site-packages/requests/models.py", line 318, in prepare
self.prepare_url(url, params)
File "/home/roy/boost-stack/q2/q2-venv/lib/python3.9/site-packages/requests/models.py", line 392, in prepare_url
raise MissingSchema(error)
requests.exceptions.MissingSchema: Invalid URL 'localhost/v1/key_prefix/key_basename': No scheme supplied. Perhaps you meant http://localhost/v1/key_prefix/key_basename?