Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Get form name from node rather than sode when merging #2952

Merged
merged 3 commits into from Dec 20, 2022
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
2 changes: 1 addition & 1 deletion synapse/lib/storm.py
Expand Up @@ -3126,7 +3126,7 @@ async def sync():
if self.opts.apply:
await self._checkNodePerms(node, sode, runt)

form = sode.get('form')
form = node.form.name
if form == 'syn:tag':
if notags:
continue
Expand Down
7 changes: 7 additions & 0 deletions synapse/tests/test_lib_storm.py
Expand Up @@ -1237,6 +1237,13 @@ async def test_storm_diff_merge(self):
await core.nodes('ou:name | merge --apply', opts=altview)
self.len(1, await core.nodes('ou:name=foo -(bar)> *'))

with self.getAsyncLoggerStream('synapse.lib.snap') as stream:
await core.stormlist('ou:name | merge --apply', opts=altview)

stream.seek(0)
buf = stream.read()
self.notin("No form named None", buf)

async def test_storm_merge_opts(self):

async with self.getTestCore() as core:
Expand Down