Skip to content

test: update deltachat 2.50 compatibility in relay_minitest#21

Closed
ccclxxiii wants to merge 6 commits into
mainfrom
ccclxxiii/regression-parity
Closed

test: update deltachat 2.50 compatibility in relay_minitest#21
ccclxxiii wants to merge 6 commits into
mainfrom
ccclxxiii/regression-parity

Conversation

@ccclxxiii
Copy link
Copy Markdown
Contributor

summary

this updates the bundled relay_minitest test setup for compatibility with deltachat rpc/server 2.50.0.

changes

remove unsupported deltachat config

the bundled minitest account setup previously configured:

account.set_config("delete_server_after", "10")

deltachat rpc/server 2.50.0 now rejects this key with:

unknown key "delete_server_after": matching variant not found

which caused test-mini account setup to fail before tests could run.

the unsupported setting has been removed/commented out.

improve sender ip cleanup test handling

test_hide_senders_ip_address was updated to reduce timing sensitivity during raw imap inspection by:

  • polling imap with a timeout
  • explicitly selecting INBOX
  • fetching with criteria="ALL"
  • testing sender-side bcc copies via bcc_self

release note

chatmail/relay currently pins reusable workflows and cmlxc_version to released cmlxc tags.

to consume these fixes from relay ci, a new cmlxc release/tag should be cut and referenced from relay workflows instead of older v0.14.6 pins.

until a new release exists, relay ci must temporarily pin to a specific commit sha containing these changes.

@ccclxxiii ccclxxiii requested review from hpk42, j4n, link2xt and missytake May 28, 2026 15:34
@link2xt link2xt removed their request for review May 28, 2026 15:36
@link2xt
Copy link
Copy Markdown

link2xt commented May 28, 2026

CI is not running the tests because lint failed.

@ccclxxiii
Copy link
Copy Markdown
Contributor Author

ccclxxiii commented May 28, 2026

CI is not running the tests because lint failed.

thanks, addressed in 8fb74c5d95c21859b0a58ec2bfa7c20a2c31d909

Comment thread src/relay_minitest/test_relay.py Outdated
pw = user2.get_config("mail_pw")

addr = user1.get_config("addr")
host = addr.split("@")[1].strip("[").strip("]")
Copy link
Copy Markdown

@link2xt link2xt May 28, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Maybe you wanted .lstrip("[").rstrip("]"). .strip("[]") was working too.

Comment thread src/relay_minitest/test_relay.py Outdated
host = addr.split("@")[1].strip("[]")
pw = user2.get_config("mail_pw")

addr = user1.get_config("addr")
Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This now takes addr of user1, so mailbox of user1 is checked below. But chat = cmfactory.get_accepted_chat(user1, user2) returns the chat of user1 above, so chat.send_text("testing submission header cleanup") sends a message from user1 to user2.

I guess it will pass, but by enabling bcc_self on user1 you now read the copy user1 sent to self from the mailbox. Previously the test was testing that user2 (receiver of the message) does not see IP of user1, now the test is testing that user1 does not see own IP in the copy it sent to self.

Comment thread src/relay_minitest/test_relay.py Outdated
deadline = time.time() + 10
msgs = []

while time.time() < deadline:
Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This loop was not necessary when user2 was checking the mailbox of user2 because by this time we know user2 has received the message (user2.wait_for_incoming_msg() above).

I think the only change needed overall is enabling bcc_self on user2 so user2 does not delete the message immediately, that's all.

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@link2xt thanks, took a stab at it in 1381f2087f74adb844c1649254faeefefb45cd61

@ccclxxiii ccclxxiii closed this May 28, 2026
@ccclxxiii ccclxxiii deleted the ccclxxiii/regression-parity branch May 28, 2026 16:28
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants