I've reworked Openfire pubsub code. Can anyone suggest some ways to do some quick functional tests?
Guus
I've ran the Smack Integration Tests, which seem to be fine - but those don't go into much detail. I'd like to run some additional tests, preferably not ones created by me.
alihas left
alihas joined
Neustradamushas joined
Neustradamushas left
alihas left
jonas’
aioxmpp has some PEP related tests for sure, and very bare PubSub tests
pulkomandyhas left
pulkomandyhas joined
Guus
jonas’ cool - how do I run them?
jonas’
Guus, git clone https://github.com/horazont/aioxmpp, you may be able to get some inspiration from https://github.com/horazont/aioxmpp/blob/devel/utils/travis-e2etest-ejabberd.py
jonas’
if you adapt the scripts and configs in that repository to work with openfire, that’d be amazing
Guus
My understanding of the python language is that 'hssssssss' means that you should step away.
jonas’
that py file I linked you is more of a glorified shell script really. I can’t guide you at this moment, I’m supposed to be in a meeting in four minutes
Guus
kk, tx
Martinhas left
Martinhas joined
asterixhas left
asterixhas joined
Jaehas joined
Guus
There must be a better way to figure out what modules are needed other than to try and run it, see an error, and install that?
jonas’ I'd be greatful if you can help me interpret the gazillion lines of logs generated by your tests.
Zash
screenshot of text :|
Zash
Guus: I think you need to trick docker into letting it have access to where your xmpp server is running
Guus
screenshot of text to preserve format - didn't assume anyone wanted to copy stuff from this 🙂
Guus
ah, it does not have access by default?
Zash
"connection refused" is the relevant thing I assume
Guus
my docker is as good as my python
Guus
sure
Guus
but ... why 🙂
Zash
Try `--network host` maybe?
Martin
Wher is specified how a message should look like when sending the link to a http-uploaded file OOB? Or how is it done that clients show the file instead of the link?✎
Martin
Where is specified how a message should look like when sending the link to a http-uploaded file OOB? Or how is it done that clients show the file instead of the link? ✏
Zash
Docker is so last years, now it's Kubernetes all the things!
flow
Martin, I think this is implementation dependend
Zash
Martin, source code of Conversations probably
Martin
Yeah, code == specification? ;-(
Zash
In theory you just follow XEP-0066
Zash
In practice I think you must have the URL both in that and in <body>, and nothing else
pulkomandyhas left
pulkomandyhas joined
Martin
Thanks, will figure out.
Zash
I'm kinda sad that you can't include a description, which is supported by OOB.
Zash
Did anyone get anywhere with XEP-0385 yet?
asterixhas left
asterixhas joined
larmahas joined
kikuchiyohas left
pulkomandyhas left
pulkomandyhas joined
rion
Psi supports 385
kikuchiyohas joined
rion
But currently implementation is incomplete. Works for images and audio messages only. And has some bugs.
pulkomandyhas left
kikuchiyohas left
pulkomandyhas joined
alihas joined
kikuchiyohas joined
alihas left
lovetoxhas left
asterixhas left
asterixhas joined
Martin
> In practice I think you must have the URL both in that and in <body>, and nothing else
Ok, that worked. Thanks. 😃
Martin
> I'm kinda sad that you can't include a description, which is supported by OOB.
That would be really nice.
pulkomandyhas left
pulkomandyhas joined
alexishas left
alexishas joined
jonas’
Guus, send them to me via email or something
lovetoxhas joined
Wojtekhas joined
Neustradamushas joined
Neustradamushas left
neustradamushas left
neustradamushas joined
Jaehas left
goffihas joined
alihas joined
Jaehas joined
pulkomandyhas left
asterixhas left
asterixhas joined
alihas left
asterixhas left
asterixhas joined
alihas joined
Jaehas left
Jaehas joined
alihas left
pulkomandyhas joined
adrienhas left
Martin
Is it safe to assume that the max file size is always in the value of the second field of the second x in the reply to disco#info?
Martin
For the http upload service
flow
Martin, that sounds wrong
flow
Martin, why not use the field's name?
adrienhas joined
flow
and why *second* <x/>?
Zash
wat
Martin
Worked here for dismail (ejabberd) and my own server (prosody). Dunno how to access by name without cycling through all.
flow
Martin, that is very fragile
flow
so it is *definetly* not safe and unsound
pep.
Zash, movim also has 385 support
Martin
Ok, then I'd better go through all and check the names.
Zash
Martin, what language and xml library are you using?
DISCLAIMER: I am no dev so probably I am holding it wrong anyway.
Martin
I am using go and github.com/mattn/go-xmpp
asterixhas left
asterixhas joined
flow
Martin, no worries. but you definetly should not settle for quick hacks, especially if they fragile
Martin
I did create a struct with the structure of the xml and then xml.Unmarshal the IQ reply into it.
neustradamushas left
flow
that alone sounds worrysome. due to the extensible nature of XMPP the returned XML may not match your struct✎
pep.
Martin, you can easily become a developer if you go into your Android settings and tap on "Build number" multiple times. Then it will say "You are now a developer!"
flow
that alone sounds worrisome. due to the extensible nature of XMPP the returned XML may not match your struct ✏
pep.
It's that easy
Martin
Looking at the output it seems the max-file-size is in the value of the second field on the first and second x. But if this is not standardized I will check for the "max-file-size" in var while cycling through all.
flow
Martin, it *is* standardized
pep.
You need to own a device with android, it's the only requirement for being a developer
Martin
pep.: Did that several times already on all of my phones. Thanks, no I can not hide behind "I'm no dev" anymore. :(
flow
Martin, it is the value of the max-size-field of the extended disco info form with the type urn:xmpp:http:upload:0
paulhas left
alexishas left
Martin
Ok. So it is important to check the field name. That's what I wanted to know. Thanks. :)
flow
Martin, not only the field name, you also have to check that you are looking at the right form
Martin
About the issue that the struct might not matching if/when something there get's extended I don't know what to do, as somehow I must get the date of that byte array into something I can process.
adrienhas left
adrienhas joined
Martin
flow: Meh, why everything must be complicated…
flow
I don't think it is complicated, nor that there is a much simpler alternative
neustradamushas joined
flow
you could extra the value with a pull parser
flow
or mayben even an xpath expression
Martin
Hmm, that would be two new things to read up. ^^
flow
always a good idea to learn new things :)
pulkomandyhas left
Martin
It's always exponential growth, I want to do one thing than I need look up three things for that. Number 1 requires me to look up 4 other things, number two requires me to look up 2 new things and numer 3 requires me to look up 3 new things. And every level 2 new thing requires me to look up n level 3 new things. It's never ending. I, as an engineer, don't understand how you devs ever finished your studies because everything is a hydra. ^^
flow
the secret is: we are always studying and shaving yaks
pulkomandyhas joined
paulhas joined
Martin
You never shave Ge0rg, his avatar is as hairy as always!
alihas joined
alihas left
adrienhas left
adrienhas joined
adrienhas left
adrienhas joined
paulhas left
paulhas joined
Jaehas left
Jaehas joined
asterixhas left
asterixhas joined
Martin
So, you think this is sufficient for determining the max-file-size or is it still fragile? https://salsa.debian.org/mdosch-guest/go-sendxmpp/-/commit/9702df6c84a189fbf881c29c9ba07d3e77ae84c8
Jaehas left
flow
Martin, it is far better, but AFAIKT you do not check if you look at the right form
Jaehas joined
Martin
What to check for? I don't see anything interesting for FORM:
Or do you mean to check which is the http upload component? That's done there: https://salsa.debian.org/mdosch-guest/go-sendxmpp/-/blob/http_upload/httpupload.go#L141
pep.
Martin, I think he meant checking FORM_TYPE?
Martin
Ok, what is that good for? No need feed me with a golden spoon just direct me at the right xep. But all I see is `<field type='hidden' var='FORM_TYPE'>` which seems quite uninteresting for me.
pep.
Martin, the value of that field is what indicates what type of field it is
pep.
Which fields you may find in it
Martin
Ah, so I need to check for `urn:xmpp:http:upload:0`. Ok thx.
pep.
yeah
pulkomandyhas left
pulkomandyhas joined
Martin
Ok, am checking for this as well now.
asterixhas left
Jaehas left
Martin
Thanks all for the useful feedback. 😃
If you feel bored someday you can go through the rest, tell me what I'm doing wrong there. 😂
pulkomandyhas left
pulkomandyhas joined
rionhas left
rionhas joined
Jaehas joined
DebXWoodyhas left
Jaehas left
Jaehas joined
paulhas left
paulhas joined
lovetox_has joined
lovetox
what priority do i have to set if i dont want to use priority
alihas joined
flow
lovetox, define "do not want to use priority"
lovetox
i just read i can just leave it out of the presence
lovetox
then server assumes 0
flow
that's right
lovetox
does it do anything if i include priority in a presence to a MUC?
alihas left
flow
that's a good question. I think the priority in directed presence stanzas it not used anywhere
flow
but I could be wrong. A server dev could may say more about this
flow
but then again, *why* do you want to include a priority value in a directed presence?