« first day (2434 days earlier)      last day (2545 days later) » 

4:00 PM
@AndroidDev really? Can't ARM64 run ARM apps?
 
@TheWanderer Possibly. But we will still need to compile it for ARMv7 and ARMv8
 
@AndroidDev Yeah. That's what I did with GitDroid back in the day.
It bundled the Git binary for i386, ARM, and MIPS.
(Apparently there are MIPS phones running Android. Who knew.)
 
We'll have to compile for all of those --^
 
I wouldn't worry about x86_64.
 
@NathanOsman Well now here's an idea.... what if we ran a hidden webview in the background and then just used a Javascript API?
 
4:04 PM
@AndroidDev I don't know if you can run a webview in the background.
 
@NathanOsman what is MIPS
 
@GeorgetheDev what is mips?
 
MIPS may refer to: == Technology == Million instructions per second, a measure of a computer's central processing unit performance MIPS architecture, a RISC instruction set architecture Maximum intensity projection, a volume rendering technique Multiband Imaging Photometer for Spitzer, an instrument on the Spitzer Space Telescope Multi-directional Impact Protection System, a 'slip-plane' technology inside athletic helmets designed to reduce rotational forces that can result from certain impacts Stanford MIPS, (for Microprocessor without Interlocked Pipeline Stages) a research project at Stanford...
 
@GeorgetheDev what is MIPS architecture?
 
MIPS is a reduced instruction set computer (RISC) instruction set architecture (ISA) developed by MIPS Technologies (formerly MIPS Computer Systems). The early MIPS architectures were 32-bit, with 64-bit versions added later. There are multiple versions of MIPS: including MIPS I, II, III, IV, and V; as well as five releases of MIPS32/64 (for 32- and 64-bit implementations, respectively). As of April 2017, the current version is MIPS32/64 Release 6. MIPS32/64 primarily differs from MIPS I–V by defining the privileged kernel mode System Control Coprocessor in addition to the user mode architecture...
 
4:05 PM
There.
 
guys, does someone here knows how to program with openssl-lib?
 
In C?
 
yeah
 
A little bit.
114
A: Programmatically Create X509 Certificate using OpenSSL

Nathan OsmanI realize that this is a very late (and long) answer. But considering how well this question seems to rank in search engine results, I figured it might be worth writing a decent answer for. A lot of what you will read below is borrowed from this demo and the OpenSSL docs. The code below applies ...

 
I was just wondering how hard it is to learn it for someone who only knows the basic structure of a SSL connection
because I had a glance of it before and looked really complicated
 
4:06 PM
My only experience with it is generating a self-signed cert and doing some simple signing.
 
@NathanOsman What about this? github.com/ericwlange/AndroidJSCore
And this one says it creates a webview behind the scenes: github.com/evgenyneu/js-evaluator-for-android
 
@NathanOsman:
 
LinkedIn thought I might be a good fit for "Clang Frontend Compiler Engineer" at Apple.
 
@NathanOsman I see, guess actually making a connection would be much more complicated right? considering the many different encryption keys that can be used
 
@NathanOsman ew
Apple and Frontend?
you?
wat
 
4:08 PM
Not that kind of frontend.
Clang is a compiler that uses the LLVM backend.
 
encryption keys I meant encryption algorithms, my bad
 
the back frontend?
front backend?
 
Never saw this before ^ . A debian logo on the error.
 
Sidenote: I'm really questioning why Debian had to go and use systemd. Ubuntu basically had no choice at that point.
 
It was in systemd-udevd. wonder if that matters.
 
4:11 PM
lol
 
@chaskes The timing of your message was... timely.
 
@NathanOsman So with the HTTP API, the Java code won't be directly calling the Go code, right? Which would mean not as big of a performance hit?
P.S That was sent from the Android app :D --^
 
@chaskes sudo nano /etc/default/apport ... change enabled=1 to enabled=0 ... then you won't see it again ! :D :D :D seriously : mostly these warnings are faults within the acclication itself (be it with a debian or with an ubuntu logo) ! :)
 
@NathanOsman lol
 
@AndroidDev Well, actually, the Java code uses HTTP to communicate with the Go app which connects the the chat API. So there is some overhead but not much.
 
4:17 PM
@NathanOsman Then again, the odd that we would be complaining about systemd at any given time are pretty high. :)
I loaded up Devuan, btw. Debian with sysvinit.
 
How is it?
 
@NathanOsman Sorry for the noobness, but since I've never used Go before, how do I listen for new messages with your API? Your documentation only says "To receive events from the chat server, simply receive from the Events channel in Conn:"
 
@chaskes chat.stackexchange.com/transcript/message/37728555#37728555 application instead of acclication of course ... typo - sorry ! :)
 
Very solid version of Jessie.
 
@AndroidDev I'll show you an example of how that works.
for e := range conn.Events {
    // e contains a single event
}
 
4:23 PM
@NathanOsman So then I would have to check if e == 1?
 
No.
Since you're receiving from a channel, the loop ends when the channel is closed.
e will always be a valid event.
 
@NathanOsman So then how would I check what kind of event it is?
 
@NathanOsman Remember, I've never used go before. What do I do with that?
 
@NathanOsman so did you enjoy the red alert badge that tol you you had 2000000 notifications?
 
4:30 PM
@TheWanderer did not get
 
rly
 
@AndroidDev You can do this:
if e.EventType == sechat.EventInvitation {
    // process invitation
}
In that example, e.RoomID contains the room the user is invited to.
You could then join the room with:
conn.Join(e.RoomID)
 
Ah, okay
Hmm, nothing's happening
for e := range c.Events {
// e is of type *Event
if e.EventType == sechat.EventMessagePosted {
fmt.Sprintf("Message posted!")
}
}
 
randomly appears
 
randomly disappears
 
4:40 PM
weird
copying files causes my cpu load to skyrocket
 
Does that include iowait?
 
it gets it from uptime
 
@AndroidDev That should work. Were there any messages posted in the room you joined?
 
4:53 PM
@NathanOsman Yeah; I told it to join the AU general room
 
https://t.co/YNfKlnC4ad
okay that's really cool.
 
user136984
5:06 PM
@TheWanderer @NathanOsman: What's this new app you two are working on by the way? :)
 
@ParanoidPanda Android app for chat.
 
user136984
@AndroidDev: Cool name! :D
 
@NathanOsman So any ideas why it isn't detecting messages being posted?
 
Anything showing up in logs?
If it runs into anything abnormal, it should write stuff out to the logs.
 
5:09 PM
@NathanOsman Well, there's this org.golang.example.android E/GoLog: time="2017-05-29T17:08:16Z" level=info msg="connected to WebSocket" connected=true context=sechat
 
user136984
@NathanOsman: What language are you using?
 
Java & Go
 
@ParanoidPanda It's an Android app, so Java.
 
user136984
Oh, good choice! ;D
 
@AndroidDev Hmm... sounds like it should be receiving events.
If you stick a fmt.Println("test") before the for{} loop, does it execute?
That will tell us if the code is even reaching the loop.
OH WAIT A MINUTE.
I found the problem.
34 mins ago, by Android Dev
for e := range c.Events {
// e is of type *Event
if e.EventType == sechat.EventMessagePosted {
fmt.Sprintf("Message posted!")
}
}
You are using Sprintf() and ignoring the return value.
...which is basically a NO-OP.
Try changing Sprintf to Println.
 
5:11 PM
I told you I don't know how to use Go :D
 
Sorry for not noticing that sooner.
 
What does sprintf do anyway?
@NathanOsman Uh-oh ../../hello/test.go:46: undefined: Println
Wat.
How can println be undefined?
 
fmt.Println
@AndroidDev It is the same as Printf but instead of writing to STDOUT, it returns the result as a string.
 
facepalm
Okay, here goes
test
Mmkay, that seemed to work
 
5:16 PM
@NathanOsman Can you post another message? I want to watch the lag time
 
By the way, I have more examples of using the library here: godoc.org/github.com/nathan-osman/go-sechat
 
Okay, so it lags maybe 100ms behind the webpage
 
@AndroidDev Should be pretty minimal since it is using the WebSocket directly.
 
@NathanOsman Now how can I print out the actual message content?
 
e.Content for the raw data.
e.TextContent for the content without HTML, mentions, etc.
Both are strings.
 
5:19 PM
So what's in the raw that's not in the other?
 
All of the HTML formatting (bold, links, etc.) and an @user that precedes the message.
 
For example, in this message:
3 mins ago, by Android Dev
@NathanOsman Now how can I print out the actual message content?
e.TextContent would be "Now how can I print out the actual message content?"
 
Uhm...
level=error msg="websocket: close 1006 (abnormal closure): unexpected EOF" context=sechat
 
That is both bad and good.
Bad because it means something weird happened with your connection
Good because the package is designed to reconnect after 30 seconds :D
 
5:22 PM
Huh, it seems to be working now
Yep, just got the print in AS from that message
@NathanOsman Could it be because I'm logged in on the computer and then my tablet is also logged in?
 
It shouldn't make a difference.
One possibility: Android might be overly aggressive in putting the device to sleep to conserve battery. This might be affecting the websocket connection.
You could grab a wakelock to prevent that.
 
@NathanOsman Thanks for the help. My next question is how can I "grab an instance" of the Go code or something so that it doesn't have to re-sign in every time I use the post message call?
 
The signing in shouldn't take more than 3-4 seconds and unfortunately, it happens each time the package starts.
To work around that, I'd have to store the cookies from the cookie jar that the request code is using.
And that introduces some other issues.
 
Hmmm
 
It really shouldn't be a problem to sign in every time.
 
5:34 PM
@NathanOsman Taking 3 seconds to post each message wouldn't be annoying?
 
@AndroidDev Oh, you're signing in for each request?
 
@TheWanderer --^
@NathanOsman yeah
 
Why not sign in and just reuse conn for every message you send?
 
Well the question is how to do that from Java
GTG; I'll be back later :)
 
hi
I wanted to dupe this but the link has zero upvote and OP isn't responding. What do I do?
 
5:44 PM
So it's 28° C here...
ಠ_ಠ
 
We had 35 C yesterday. and today was 31 C. And We're given a cyclone warning for this night
 
@Anwar huh, it was 30 here yesterday and tomorrow we have thunderstorms :P
 
That's not very common I guess!
Same sort of weather occurring on different part of the world!
How common is thunderstorms there?
 
Not very common. We get them maybe once or twice a year.
 
@NathanOsman 15 here hue
 
6:01 PM
Oh! Same here. But we don't get that signal 10 very often. Maybe once per 5-6 years.
 
@NathanOsman how is NS going
 
@TheWanderer macOS is still being stupid.
 
duh
 
I originally reviewed this to leave open and then saw the other question from OP that suggested that they had been able to figure out the solution. so deleted the answer and closed as no-repro here
Now, OP commented there asking about the launcher
 
@Anwar Why would you delete the answer?
 
6:13 PM
deleting is a part of life
 
@terdon OP's other question got an answer which was essentially better on the icon part.
 
OK, but why delete yours?
It had the answer about how to install the panel, after all.
 
@terdon Ok, I was asking opinion. undeleted now :)
 
I also reopened it since it didn't seem like a dupe.
 
Hi all!
I'm learning my first poem in over 15 years.
52 verses for my grandma's 80th birthday. :-D
 
6:20 PM
Hi @DavidFoerster !
 
Google is treading on Tolkien's work: go.googlesource.com/gollvm :-D
 
Man, IPv6 is complicated.
 
Yes.
 
@NathanOsman So I tried to return the instance of sechat to pass in later, but I got:
test.go:14: use of package sechat without selector
 
Can I see the code you're using?
 
6:34 PM
Sure, just a sec
@NathanOsman It's a bit messy since I've been trying different things, but here it is paste.ubuntu.com/24705776
 
@Zanna do you drink coffee?
 
@AndroidDev c is an instance of *sechat.Conn.
So:
func TestNathansAPI(message string, username string, pass string) sechat {
Should be:
func TestNathansAPI(message string, username string, pass string) *sechat.Conn {
 
Ah
Ok, let me try it
 
Same for:
func TestNathansAPI2(chatInstance sechat) string {
Change sechat to *sechat.Conn.
 
@Seth only in special circumstances - I'm very sensitive to caffeine, so I actually mainly drink herbal tea. My mum loves to drink coffee with me, so when I'm home, I take about a thimble of coffee with a whole lot of coconut milk with her :)
just to be social
@DavidFoerster awesome!
what poem is it?
 
6:39 PM
@Zanna you should try this then teeccino.com. My mom got me to try it, and I think I will try drinking it for a bit (I don't drink coffee). It's an herbal blend designed to replace coffee.
2
 
@Seth oh awesome! there's one like that here I like called Caro - it's really nice
 
@Zanna Oh cool!
 
that stuff looks great
I'll definitely try some
thanks a lot!
 
@NathanOsman Oh great, now Android Studio says it can't resolve the method :(
Maybe I need to do a little reading on the basics of Go
 
@Zanna np. let me know what you think :)
 
6:49 PM
0
Q: Textfile functions in Linux

Jennifer BesterGive the instruction to search in the file “/use/share/dict/words” for words that start with “b” and end with “o” and contains an “i” or “g”. A command has to be typed in the terminal displaying a word that has the specifications as described above. I'm using Linux Ubuntu and unsure of how to do...

 
@NathanOsman Wat. Now those two methods aren't showing up, but a second hello world method I just added shows up fine.
<WAT>
If I remove the *sechat.Conn it shows up fine
</WAT>
 
@Zanna a custom adaptation of ingeb.org/Lieder/machauff.html
 
@Seth will do!
 
@AndroidDev weirdness.
 
@DavidFoerster alas, no German. But I get a gist of its loveliness from GT's mangling :)
 
6:57 PM
@NathanOsman Wait a sec, could it be because I need to specify a new object type in Java? Because Java doesn't know about any conn objects
 
Wait, how did Java come into this?
 
@NathanOsman Because the method is being called from Java
 
How are you doing that?
 
hmm
XDA published this article xda-developers.com/…
that says at the end:
> He and I are working on a new application that will incorporate this tweak and many, many more so unrooted users can explore all the hidden tweaks available on their devices.
I commented twice, inquiring as to how similar it will be to my app, and both comments were rejected
 
7:01 PM
XDA is... well.
I have had problems there too.
 
this is worrying
 
Dreams of being rich == poof?
 
lol
 
@NathanOsman I'm just using Go Mobile. It lets you call Go methods from Java
 
That's pretty neat.
 
7:03 PM
@DavidFoerster dreams_of_being_rich.poof(true)
@NathanOsman I'm wondering if Java doesn't like it because it can't determine the return type?
 
@AndroidDev class dreams_of_being_rich { void poof( bool state = true ); }
 
No no no no no. This is Java. We end up with DreamsOfBeingRichDestroyerFactory.create(this).destroyMoney(true).preserveLife(‌​true).build().destroy()
Yours wasn't complicated enough :P
 
static methods, eh?
 
Yus.
 
@NathanOsman Pff… Java doesn't even have default method parameter values.
 
7:05 PM
Endless overloads FTW.
 
Instead you have to create more overloads than you have fingers and toes or use helper objects like maps or enumeration type lists.
 
@NathanOsman Wat. Java finds the method just fine if the return type is string or int, but claims it doesn't exist if the return type is *sechat.Conn
 
Hrm... maybe it doesn't like non-primitive return types.
 
I should stop eating ice cream
… at least for today.
 
Do the bindings allow goroutines to run correctly on their own?
If so, there may be a better option.
 
7:09 PM
There are still a couple of very ripe avocados, some hummus, Turkish pastes and pide.
 
You could use a global variable for *sechat.Conn and then just reference it in each method.
 
Sounds like I'm going to have shawarma tonight.
 
@NathanOsman How would I determine the answer to that?
@NathanOsman That was my next thought actually
 
@AndroidDev Apprently goroutines do work correctly.
 
I think this question is too broad
 
7:15 PM
@Anwar It's pretty broad but not too broad. It's a relatively long but conclusive list of criteria to compare 3 similar things.
 
quick question that might be a stupid one
 
hey @IanC!
 
hey @Zanna, long time, how have you been doing? :)
 
kind of not good
getting kicked out of my flat due to landlord moving and putting it up for rent as a complete thing
work been kind of bad
running out of money
London cost of living getting worse
so luckily I can move back with my folks up in Lincolnshire, but I'm pretty stressed by the timing, I have stuff booked I will have to cancel
don't know how I will manage to get work
I'll figure it out though!
what about you?
 
damn, sorry to hear it, looking for a new place can be really annoying, but hopefully you'll find a nice one, maybe even better than this last
did he give you some time to look for a new place?
if things get too tight it might be a good idea to go back with your folks, take a breath before looking out for something again, much harder to look for a place with a deadline :/
 
7:22 PM
yeah but I'm not going to, just going to leave town, I am so tired of flatsharing and can't afford anything else - staying with my folks for a while
oops, kind of venting, sorry!
what were you going to ask originally?!
 
well, think it might be a good idea for a while then, sharing a place can be tiring if you don't find the right people to share with, and sometimes that's a bit hard
are your folks place much far from London? Have no idea of distances there in UK :p
@Zanna oh, don't worry, it was nothing that important, I was just following those steps to verify an iso download, and was wondering why it asks you to run gpg --verify SHA256SUM.gpg SHA256SUM when the latter seems to be just a text file with no signature
 
3 hours door to door. Not commuting distance but not too bad. Trains cost £70 on the day though O.O
@IanC I find anything with gpg confusing!
 
wow, that's some expensive ticket! Even more if I convert it to my currency haha
@Zanna I know right? I kind of get how it works, overall, but when running the commands there's always some small detail that gives me some doubt, and I get confused with the ring of trust too!
 
@IanC Train travel isn't priced competitively with air travel in Europe. The only good thing about the former is that there are far more train stations than airports.
 
oh yes I remember that in Brazil it cost about the same to get a flight as to get a bus
 
7:32 PM
…and it's often less of a hassle because you don't need to take care of airport transfers, security and check-in.
 
yeah, sometimes it's even cheaper to get a plane here than to get a bus
and we basically don't have trains that transport people
 
Many weekly commuters (at least in Germany) prefer to travel by train between large cities in the north and south even if there are suitable airports on both ends.
 
has to do with being able to enjoy the view during the trip? :p
 
It's more comfortable and takes about the same time if you take airport transit and check-in into account.
Also, especially business travellers would rather sit 4 h in a train and read or work on a laptop in the mean time than ride 1 h to the airport, walk around and wait in queues for ½ h, squeeze into a relatively small aeroplane seat for ½ h and ride back into the city for another hour.
 
probably has a lower carbon impact too
I get all my reading done while commuting :)
 
7:40 PM
O.O I printed something at a copy shop yesterday and now my USB drive has a Windows virus.
That drive hasn't been connected to a Windows machine in months.
I guess I need to write them an e-mail.
 
wow
 
@DavidFoerster not sure that will help much, considering they plug tons of strangers USBs per day on that computer :p
 
@IanC Yeah, but they should still disable autostart, update their software against vulnerabilities and now also purge their system from the virus.
 
@NathanOsman I hope I'm not annoying you, but I got this when I tried to make the Conn object global:
hello.go:31: cannot assign error to err (type *sechat.Conn) in multiple assignment
 
user136984
@DavidFoerster: Can't you even buy special devices to plug your USB through in order to not allow firmware infections to get on your system?
 
7:47 PM
@DavidFoerster they should, just don't think it's likely they will :/
no reason why you can't send them an email though
 
@AndroidDev Ah, the multiple assignement error.
That means you need to switch from := to = and declare err ahead of the line.
var err error
...ought to do the trick.
 
var rgarbl;
 
@ParanoidPanda You can buy external drives that have a switch to disable write operations. There are also USB mass storage controllers that you can plug in as a proxy to filter out any write commands (often used in forensics).
 
WHAT THE HECK MACOS. I'VE GIVEN WORLD READ PERMISSION TO THIS FILE. Y U NO LET OTHER USERS cat THE FILE?!?!
macOS really is annoying.
 
7:52 PM
That fixed the compile error :)

Now let's see if it works
 
user136984
@DavidFoerster: Yes, well, then they could use one of those as well as a good AV, maybe Linux and a VM or at least a community that is secured properly against most infections.
 
@NathanOsman I spoke too soon :(
hello.go:77: c.EventMessagePosted undefined (type *sechat.Conn has no field or method EventMessagePosted)
 
@AndroidDev you want sechat.EventMessagePosted.
It's not part of the connection.
 
@NathanOsman Maybe they have a security model similar to Microsoft where "everyone" means everyone with a valid user account and "anonymous" means everyone even without a user account.
 
7:54 PM
$ stat cert.pem
16777217 2172651 -rw-r--r--
That should grant everyone read permission.
And yet:
$ cat cert.pem
cat: cert.pem: Permission denied
Oh. Hehehe.
Grins sheepishly.
3
The directory doesn't have read permission.
 
var rgarbl;
 
Backs away from the computer slowly.
5
 
@NathanOsman And now the for loop runs through instantly :( Gah!
 
Instantly?
 
Wait a sec, do I have to create a new instance of the class? I'm just calling it directly ATM
 
7:58 PM
Anyway that makes me think I should probably get a write-protectable USB drive for stuff like this.
 

« first day (2434 days earlier)      last day (2545 days later) »