« first day (2680 days earlier)      last day (2494 days later) » 

03:02
How normal is it for a 4-month project to take 2 months to get to the actual programming stage? This is my first job so I don't have much to refer to, but I'm thinking my project has absolutely no structure compared to others.
03:15
2 months of planning?
was there a problem getting data to start on?
Little was known when this project started; we've been and still are in "analysis" pinging people from different teams to provide one-off documents describing isolated steps to perform our work that we're patching together like a frankenstein quilt
@person27 It's not going to be a 4-month project
That much is clear. I say at current rate probably 6 months
Give it 8
And yeah, that's pretty normal if you don't have really experienced management.
Oh, okay. Didn't think it'd be that much. Thanks for telling me how it is. :)
Here's another question then. How normal is it to have to work 8:30 - 10:30pm after normal work hours of 9am - 5pm? This is the team meeting
03:40
Hello
is anyone here familiar with OpenID Connect?
04:27
OpenId
8 1/2 why not make it a year
04:55
have you ever implemented openID Connect on MVC before?
I have done a Facebook once
mr5
mr5
05:24
o/
how do I prevent a point from going out of circle?
...or get the distance between the point and the circle boundary?
you know when you go to the endpoint, you send a "Return_Uri"
when you are on the actual test view, are you able to retrieve the Claims?
05:39
@mr5 going to need some code to see what you're trying to do
mr5
mr5
I am trying to prevent a point from going out the circle using this code until I realize it is limited to a rectangular boundary only
float padding = (containerRadius - joystickRadius);
if (x + joystickRadius >= containerRadius * 2 - offsetTouch.x) {
    x = (containerRadius - offsetTouch.x) + padding;
}

if (y + joystickRadius >= containerRadius * 2 - offsetTouch.y) {
    y = (containerRadius - offsetTouch.y) + padding;
}
where `containerRadius` is the center of the circle boundary
`joystickRadius` is the radius of the object I want to prevent from going outside
don't mind the offsetTouch
@juanvan
06:03
would you want them y + joystickRadius <= containerRadius * 2
@mr5
mr5
mr5
I might need the angle here but I don't know where to put that in the equation.
The y + joystickRadius only check if the point is on the right side only. I want it to check the whole rotation
Basically, I want to make a joystick controller where the inner circle would not go outside of its circle bounds
(x - center_x)^2 + (y - center_y)^2 < radius^2
that will test if the point is inbounds of the circle
mr5
mr5
yes. but I wouldn't be able to clip the (x, y) from that
I want a function that returns a clipping point from a circular boundary.
but you will be able to test the point after your If's to see if it is in the circle before drawing it
mr5
mr5
my code for clipping their position is lacking something. maybe I need the angle too
it's restricted to rectangular bounds only
06:16
y=sin(angle), x=cos(angle) returns the position on the unit circle. angle =atan(y/x). Multiply by radius of circle to get new coordinates. Use distance formula sqrt(x^2 + y^2) to determine if point is outside or on circle bounds. Not sure what you mean by being restricted to rectangular bounds. Are you saying you have a rectangle "radius" and a point, and you want to clip the point to be on the boundary of the rectangle if it would exceed those bounds?
@mr5
mr5
mr5
@person27 disregard that part. I was referring to my code
I see what you mean. Did I answer your question?
mr5
mr5
@person27 what if the x,y goes beyod the boundaries, will I still be able to move the joystick from that?
Oohhhh, you have a small circle inside another and you want to prevent the perimeter of the small circle from intersecting the large circle. You can add the radius of the small circle when computing distance.
mr5
mr5
yeah. just like what a virtual joystick does. okay. Imma try that one out
06:37
@mr5 Use this to clamp it. You just need to find the distance between the centers of each circle. If that distance exceeds the outer circle's radius minus the inner circle's radius, you can compute the angle relative to the horizontal axis using atan(y/x) assuming x is nonzero, then you know the max radius is outer circle radius minus inner circle radius, so clamp to it:
dist = sqrt((p2.x - p1.x)^2 + (p2.y - p1.y)^2); where p2 and p1 are the circle center points.
if (dist > r2.radius - r1.radius)
r2 is the larger circle here.
mr5
mr5
@person27 whoa. thank you for this. I'm still having an issue dealing with my coordinate system. Most of the formula assumes that the center is 0,0
Sure thing. Where I wrote x =, y = and atan(y/x), consider it as the inner circle's point. So p2.x =, p2.y =, and atan(p2.y / p2.x).
07:10
@mr5 Cleaned up with less inconsistencies. I'm not testing it, but I think it should work right. https://pastebin.com/vc50ZS3J
Modify it so you're using the newX, newY variables since the function just returns void in the example.
Good morning sharperinos!
07:32
Is there any relationship between bit and binary
Pretty sure there is.
07:53
o/
ohayou.
08:21
@Proxy ohayou
@SaitamaSama ohayou
WHAT IS IT?
it iz ohayou
no is gosaimasu
good morning
08:45
bit = unit of information.
binary = "has two states"
Not directly related, but we use both of them together
so bit is subset of binary?
Nope
our bits are binary though
Somebody check if a bit can be more than binary while I get some coffee
In acting, units of action, otherwise known as bits (or beats), are sections that a play's action can be divided into for the purposes of dramatic exploration in rehearsal. The concept was propounded by the Russian actor, director and educator Konstantin Stanislavsky, who initially liked to use the term kusok (Russian: кусок, IPA: [kʊˈsok] ( listen)), an ordinary Russian word that can be translated as "bit" – as in a bit, or slice, of bread or meat. This was the term Stanislavsky preferred in the original drafts of his books. Stanislavsky also referred to these bits of action as episodes (longer...
here bit is not 0 or 1
noone said a bit has to be 0 or 1
The bits we use are 0 or 1
Depending on how deep you dive, they may also be <0.12mV or >=0.12mV*
I didn't object
08:57
*numbers are purely fictional and for presentatin purposes
just show an example
oh ok
My query was actually target something like "can a bit have 3 states and still be called a bit?"
And what about qubits
> In quantum computing, a quantum bit or qubit is a quantum system that can exist in superposition of two classical (i.e., non-quantum) bit values.
So...a qubit hold 2 classical bits?
why not 3 though? As space is 3d, it could spin in 3 dimensions
looks like we are out of league
Hello
Working with OData batch request, and I have one issue
I have response with multiple contents, content is HttpContent
HTTP/1.1 200 OK
Content-Type: application/json; odata.metadata=minimal; odata.streaming=true
OData-Version: 4.0

{"@odata.context":"https://localhost:23170/Sample/Sample/OData/$metadata#SAStudent","value":[{"Guid":"7465e4dc-966f-434c-bd2e-1246975655ff"
the content has some HTTP info in it
so I'm not able to deserialize
I can substring or remove will maybe new line, but I believe there is better solution
any ideas?
regex it
Wait you mean remove the first 4 lines?
Could read as lines and start at index 4
> the content has some HTTP info in it
so I'm not able to deserialize
well, you done fucked up now
@Jamaxack Can't You just handle it as JObject?
I'm not sure if this line will be always 4
maybe more header
09:46
Can an http header have a { in it?
not sure
@Metallkiller encoded, sure
Use an OData library that understands the OData body format?
@ntohl you mean deserialize to JObject
?
@Jamaxack Yes.
I'm searching for example code
09:49
public class OData<T>
{
[JsonProperty("odata.metadata")]
public string Metadata { get; set; }
public List<T> Value { get; set; }
}
you mean this one?
no
var getStudent = new HttpRequestMessage(HttpMethod.Get, $"{odataAddress}SAStudent");
getStudent.Headers.Authorization = new AuthenticationHeaderValue("Basic", "QWRtaW5pc3RyYXRvcjpwdw==");
// First message content with GET request
HttpMessageContent getRequestContent_1 = new HttpMessageContent(getStudent);
getRequestContent_1.Headers.Remove("Content-Type");
getRequestContent_1.Headers.Add("Content-Type", "application/http");
getRequestContent_1.Headers.Add("Content-Transfer-Encoding", "binary");
see please line 6
there is "application/http"
I think this HTtp and some another data because of this
I cannot set it to "application/json"
@Wietlol Encoded means not in plaintext? Because yo could just start reading at the first {
I have actual Json data coming from server, but it has some extra header in it because of content type is http
but i'm not sure
in just single request, not batch I'm sending request with "application/json"
and getting response in json format
morning lads and ladies
09:52
good morning
@Metallkiller well... it means that different characters will be used to represent '{' and '}', but plaintext, afaik, is a term that is only used with encryption and security and stuff
so first You content.ReadAsString...
which is not a thing here
than JObject result = JObject.Parse(someString);
i have never used/heard the term "plaintext" apart from security context
09:55
@ntohl I'm using
JsonConvert.DeserializeObject<OData<SAStudent>>(jsonData)
@Metallkiller on the other hand... '{' and '}' might not be included in the encoding, I have no idea how it is passed
and does it work?
This is off topic, but I cant find any chat rooms related to GIS - does anyone know how the Geoserver key auth module is handled?
Having trouble setting it up becase there is hardly any documentation
nope, because the string response is not json format
@Jamaxack what is it then?
why is it not json?
09:57
actually it is json format, but it contains other http information in the begenning
that is why I suggest parse it into JObject, and handle it as dynamic as possible
> why is it not json?
what are you talking about, what 'other http information'?
> actually it is json
-_-
application/http is an unusual content type to use
09:58
HTTP/1.1 200 OK
Content-Type: application/json; odata.metadata=minimal; odata.streaming=true
OData-Version: 4.0

{"@odata.context":"https://localhost:23170/Sample/Sample/OData/$metadata#SAStudent","value":[{"Guid":"318ad17d-caab-4c4f-9772-022ffce9f714","Row....
> what is going on
please take a look, it is json starting from {"@odata.context":"htt...
but the begenning is some thing different
That's a normal http request, it always has headers
but I'm getting an exception
Newtonsoft.Json.JsonReaderException: 'Unexpected character encountered while parsing value: H. Path '', line 0, position 0.'
10:00
Well don't parse the whole request then, that doesn't make sense
parse the body
@Jamaxack you mean that 4.0 is prepended?
yes, that exectly what I want
I need only body
not header
ow, it is just the body
extract the body from the response
use that to get your data
if that json is inside the OData-Version header, you just got yourself a horrible lib or a horrible endpoint
@Wietlol, sorry, not following
What http framework are you using?
10:02
what tom asked
@TomW System.Net.Http V4.2.0.0
You devs get so frustrated with each other, just help the poor guy out
@KallenNewick we would if he'd actually tell us what the problem is
OK let me make question clear
Using OData v4, Owin, self-hosted
Writing unit test to Batch request functionality
var odataAddress = "https://localhost:23170/Sample/Sample/OData/";
var batchUrl = $"{odataAddress}$batch";
HttpClient http = new HttpClient();
// Global batch request
HttpRequestMessage batchRequest = new HttpRequestMessage(HttpMethod.Post, batchUrl);
batchRequest.Headers.Authorization = new AuthenticationHeaderValue("Basic", "QWRtaW5pc3RyYXRvcjpwdw==");
MultipartContent batchContent = new MultipartContent("mixed", "batch_" + Guid.NewGuid().ToString());

var getStudent = new HttpRequestMessage(HttpMethod.Get, $"{odataAddress}SAStudent");
Great, what's the question
10:07
batchRequest.Content = batchContent;
HttpResponseMessage response = http.SendAsync(batchRequest).Result;

var multipartContent = response.Content.ReadAsMultipartAsync().Result;
foreach (HttpContent currentContent in multipartContent.Contents)
{

var settings = new JsonSerializerSettings
{
ConstructorHandling = ConstructorHandling.AllowNonPublicDefaultConstructor,
ContractResolver = new EagleODataContractResolver()
};
var jsonData = currentContent.ReadAsStringAsync().Result;
in jsonData var I have
HTTP/1.1 200 OK
Content-Type: application/json; odata.metadata=minimal; odata.streaming=true
OData-Version: 4.0

{"@odata.context":"https://localhost:23170/Sample/Sample/OData/$metadata#SAStudent","value":[{"Guid":"318ad17d-caab-4c4f-9772-022ffce9f714","Row...
I'm not able to deserialize to object
because jsonData should not have header information
if it was only body, only json, I could
but it has some header data
is it little bit clear now?
nice use of async
I'm implementing it, and I have no idea
so for now without async if it will work I will be very happy))
does this work? var coll = System.Web.HttpUtility.ParseQueryString(jsonData);
Why are you trying to get/deserialize the batch request??
is it wrong to ask a lot of questions?
is it a sign of stupidity?
10:16
@ntohl trying now...
@RoelvanUden in test I want to check if I'm able to get the data with batch request and deserialize it to object
@Breathing No, but not listening to the answers to your question is a clear sign of it.
@Jamaxack Not on a batch request you don't. Let the framework handle that. If you must, for some odd reason, access an individual request body -> do that in the handler!
Apparently nobody else has this problem. I wonder whether it's to do with the content type; maybe the http stack is keeping the headers in the request stream because it doesn't know what type it is
An OData batch is basically just a multipart form of HTTP headers+bodies
@TomW I thought also it is releated with that HTTp content type
But yeah what @RoelvanUden said, just use the framework normally, it does this for you
10:18
So even if you parse the multipart yourself (which you shouldn't) you still need to parse each individual request as http (which you shouldn't)
it does appear that you're meant to use ReadAsAsync to deserialize if you really, really want to do it manually
at my office a senior has started to get annoyed because I ask too many questions
sound like a dick tbh
I like knowing every possibility
Are they questions you should already know the answer to, or be able to find out by yourself?
10:20
unless youre asking really doofus questions
@TomW I think he thinks the latter one
but it is my first time for many things
@ntohl it returned {HTTP%2f1.1+200+OK%0d%0aContent-Type%3a+application%2fjson%3b+odata.metadata=min‌​imal%3b+odata.streaming%3dtrue%0d%0aOData-Version%3a+4.0%0d%0a%0d%0a%7b%22%40odat‌​a.context%22%3a%22https%3a%2f%2flocalhost%3a23170%2fSample%2fSample%2fOData%2f%24‌​metadata%23SAStudent%22%2c%22value%22%3a%5b%7b%22Guid%22%3a%22a0189f2a-e40b-4ef9-‌​9f60-
And he has already once said don't make a mistake. If confused; ask
dont make a mistake meens don't do any thing))
wish i got paid to do nothing
10:23
@Harry You're not a developer then?
@RoelvanUden software engineering apprentice
Don't apprentices get paid?
@RoelvanUden we do but £3.50 an hour
Wow, what awful country do you live in?
@RoelvanUden Britain
specifically england
hence the £
10:25
Don't you uncultured swines have minimum wage @TomW? ^
An apprenticeship isn't a 'job' as such
we do but apprentices aren't on it until they complete a year
Oh, you're in school? That kind of apprenticeship?>
when I'm 19 I'll be on £5.90/hour
@RoelvanUden,@TomW can you please help me on this issue please?
10:26
@Jamaxack didn't it return an object?
ameizing
maybe short skype call
@Jamaxack I've given you two suggestions
Oh, you're a kid. Thus it makes sense.
Well, three
10:26
Well, three and a lizard.
uhh, not really. I work but I spend %20 of my time doing coursework for a level 4 course
Damnit man, you're only level 4? I have a level 80 Rogue Wizard Warrior.
banter
@RoelvanUden i'll have you know I'm a legal adult in this wonderful country
10:32
@Harry But can you buy Vodka
yeah
the drinking age is 18 here
so yes
Binge-drinking capital of Europe, innit.
Oh, we changed it too, apparently. It used to be 21 for strong alcoholic drinks
Power to the EU eh.
@TomW nah thats scotland bruv
And I mean the UNION, not the continent.
10:33
ow we're leaving the EU as well
So, goodbye UK.
which strange nordic country are you from
Dumb rule anyway. Most of the pissheads aren't especially young people
@TomW it's yer da at a fooball match thinking he's hard af
10:37
What will be the better way to load millions of records from 2 duifferent RDBMS?
pagination or load whole records considering there will be 24 millions of records
God damnit here we go again
@Harry Just overseas, I'm a dutchie!
how i didn't figure that from the name i don't know
max verstappen and arjen robben eh!
Pretty much yeah.
Actually i am struggling to find any good way for this
You could read everything we told you yesterday. And by we I mean me. And by yesterday, I mean the weeks before today.
10:43
my friend just confused spotify for dream weaver
Yeah i remember you told me to use data reader to read 1 by 1 record
i dont even use dream weaver
why do you even know what dreamweaver is
I last saw that in the wild 15 years ago
sixth form made me use it
adobe is only good for photoshop these days
dreamweaver is good if you are learning and want to do anything
10:46
thats probably why we used it. I use coffecup now
I just make sites from scratch now
tbf html is a piece of piss
@Learning you have to make a decision. When you process 24 milllion records, there is gonna be some load SOMEWHERE. So you gotta choose where.
1. What you wanted: Put big load on servers for a short time, download everything, then torture local pc by comparing two huge files
2. Put some load on the servers for a longer time by comparing one by one.
3. Install your own DB instances locally, copy the datatables there (big load on servers for short time), compare locally one by one
Bottom line: 24 million records = load
I dont understand your first point
Down load everything means?
What you tried to do when you came here
Put everything into two csv files locally
10:53
oh yes thorugh sqlcnd.exe dump data in csv file and then compare
so you mean sqlcmd.exe will put big load on server for short time?
Yes. Since you download 24 million records all at once.
(Or 12 million if those are different machines)
But i have read that sqlcmd.exe also take long time for dumping records
so i dont think its a short time for the first option
*shorter than the one-by-one solution
hi
Have you ever use sqlcmd.exe?
10:56
o/
@Learning-Overthinker-Confused Nope
o/
Yes
if a string gets URL decoded twice can the result be different?
So how can you say that sqlcmd.exe will put load on server for short time?
As you've been told before
No matter what you do, load is going to be put on the server.
If the server is running like shit, fix the server.
If YOU Can't fix the server, get the vendor to fix it
10:58
or in code.. :)

var str1 = HttpUtility.UrlDecode(input);
var str2 = HttpUtility.UrlDecode(str1);

^ have str1 and str2 always the same value?
@Learning-Overthinker-Confused Because it doesn't matter which program you use. If you download 24 million records, it will put load on the server.
And short in this context means shorter than the one-by-one solution
Ok.What if the server is powerfull then what option will be good?
@qd0r not necessarily. Double-encoding is possible
data reader or sqlcmd.exe?
I have a web service in C#, which I thought was in ASP.net, but "HttpContext.Current" is null in my requests
10:59
datareader
@Learning-Overthinker-Confused they both just execute queries
they're doing the same thing
does anyone have any idea how I could find the source of this issue?
in general, it's a stupid idea to downlload 2x2Gb to locally process

« first day (2680 days earlier)      last day (2494 days later) »