Join devRant
Do all the things like
++ or -- rants, post your own rants, comment on others' rants and build your customized dev avatar
Sign Up
Pipeless API
From the creators of devRant, Pipeless lets you power real-time personalized recommendations and activity feeds using a simple API
Learn More
Search - "user_name"
-
Theres only 2 kinds of people in this world:
1. var username;
2. var user_name;
Hint: one of them will burn in hell57 -
Microsoft be like :
"Oh, you're moving away from your computer for a while with all this stuff open? It would a shame if some were to.. UPDATE it!"
It asks with a pop up, and if you don't answer it, it thinks "Oh, you're not telling me if I should update now or not, but I think you probably want me to update. UPDATE!"
For me, if I keep ignoring the update, it starts to create problems for me out of nowhere. It starts to lag and then the task manager starts to lag. EVERYTHING IS NOT RESPONDING.
When I finally update it, it acts like there were no issues at all. Everything is fine..
Even with Xbox, if it wants to update, it doesn't let you go online until you do. If it loses connection mid-update for some reason, it begins the update again from the friggin START. All that time updating gone to waste. Recently, I'm having a lot of issues with it. It doesn't let me sign in a lot of times. "We couldn't sign you in" for some reason. It JUST CAN'T. If you have a slow internet connection, you can't play any game at all. I contacted Microsoft Support about that issue and they concluded that it was all because of the slow internet connection and there were no issues on their end and they told me to GIT GOOD (Not exactly those words). If it does sign you in, it kicks you out mid-game for some reason with the evil pop up saying "Bye User_Name". The game says that YOU signed out (Dumb game, doesn't understand Microsoft shenanigans) and returns you to the main menu. If your game didn't save, well, GOOD luck to you!
Everything takes forever to load, if it decides it's not gonna load, it gives me a really helpful error saying "Something went wrong".
Maybe it's just me, it just hates me particularly. It makes me think that Microsoft intentionally acts like a douche just to get attention..
(In the end I think, maybe, this all is not a big deal if you surrender and accept Microsoft as your overlord)
I tried a few ways to stop Windows from updating automatically, but nothing worked (Maybe, I should try again).
Maybe I should dual boot Linux, but that brings a whole new set of things that I'd have to deal with, doesn't it?
Sigh5 -
WHY AM I SO FUCKING AWKWARD OH MY LORD! LITERALLY ALL I HAD TO DO WAS WATCH A SCHOOL PLAY AND THEN GET A PICTURE WITH A CAST MEMBER AND IT WAS PROBABLY ONE OF THE FEELINGS I'VE HAD IN THE PAST WEEK! GOD FUCKING DAMMIT I AM SO DONE WITH THIS! I'M TIRED OF BEING SO AWKWARD AND ANXIOUS! I DON'T GET HOW PEOPLE CAN DO ANYTHING LIKE THAT WITHOUT FEELING UNCOMFORTABLE. THIS HAS LITERALLY RUINED MY FUCKING LIFE AND I'M SO TIRED OF IT. I KNOW PEOPLE LIKE ME BUT I JUST CAN'T GET MYSELF TO TALK TO ANYONE! THE SIMPLEST THINGS TAKE SO MUCH OUT OF ME AND I'M SICK OF IT! I'M JUST TIRED OF IT! I'm just, tired.8
-
Never worked before so I'll talk about one of the former staff at my school.
This guy worked as IT and did some teaching in the high school. Early last year, he suddenly disappears for no reason.
Now, I'm going to go in order of what we (the students) found out, not, chronological order.
Firstly, turns out that in class he would make comments about female students. Nothing explicit, just kinda strange. I forget the examples I heard but think like the overly friendly old guy. Those types of comments from a 40-something IT guy. (Some female students knew about this for a long while but I only heard about it after the investigation)
Next, rumor got out that they found some stuff on his computer. I don't know how, but it turned out to be accurate, and we were accurate at the follow-up assumption that it was porn.
After that, the school made an announcement that we had been arrested. Up until then, we just assumed he had been sacked. He was weird sure, but we didn't think criminal.
Some other students looked into the police records, and it turns out this guy had been arrested for possession and distribution of child pornography.
Pretty sick right? Its worth pointing out now that our school has Pre-K through 12th grade students.
I gained a new level of respect for my female classmates after that. I didn't even know that was going on, really wish I could have helped out.1 -
JS Console: user_name is undefined
Señor Dev: can't be the API response has it!
The API response: usre_name8 -
I'm a young dev with ADD. Basically I just need to stay up late, and then get myself to hyperfocus on my code. It typically gets done in time to get a decent night's sleep.1
-
Given the recent election, I'm taking measures to ensure the privacy and security of my data. Call me paranoid, but I think the NSA is going to be getting some extra funding soon. I'm already working on encrypting a ton of my data. Any other tips some of you guys could give me?8
-
I was a university student. The it company, I was interviewed at, required everyone to pass English test. I passed it with quite a good result (90 of 100, know no one with such result). So next day I had an actual interview with a head of some department.
He didn't had his own office, instead he shared it with 5 other employees. One of them was taking with someone on Skype. He told he had some work to finish, but it shouldn't take long. It took an hour.
And then he returned to me, starting asking questions about my knowledge. I am a java backend guy, but he asked me about php stuff and front-end stuff like ‘moving a button to a new position’.
Basically, this is it.4 -
I've just tried those streams of Java 8. And I can't understand, how on Earth I didn't try them before. They're magnificent.
Hovewer I have some doubts about using them in production. I think no one else will be able to understand what code with streams do.2 -
There was cool ad at the top of the screen (of devrant android app) with link to https://www.devrant.io/get. I've clicked it, but the page is constantly reloading in browser.4
-
Looking through Java tests, cause I need to pass one for job. And every one of them has a question like:
What's the result of:
boolean b = 42 >= 1024;
if (b = true) System.out.print(1);
else System.out.print(2);
And each time I answer like there is (b == true) and not (b = true).
Cause no one in real life would write = in if statement. Why do they put such question in each and every test.1 -
Trying to do an LFS build on a computer that keeps restarting. Need to mount the partitions and export variables all over again (ノ=Д=)ノ┻━┻1
-
Let's list off all the craziest stuff that happened in 2016. (Crazy meaning unexpected not good or bad)
I'll start with the cubs winning the world series.6 -
Trying to write a program a la `man` in ncurses and just, is this hell?
I just want a floating header, a scrollable main body that reads from a file, and a command line footer, why is that so difficult? I finally got it to handle resizing terminals but now I need to try to compile it for windows, which does have unofficial ports of ncurses, but I have no idea how to use them.
Should I just restrict the windows version to a non-interactive command instead of a TUI like I want?2 -
Tried (and still trying) to do an LFS build. I already worked with Ubuntu, Debian, and Arch, but somehow a successful build eludes me. Each time I follow the book as closely and possible, but each time I got different issues. I've had to format the partition I'm working on at least 20 times now. Its fun, but I have no idea how I manage to mess up in so many ways.
-
I'm a self taught web developer, I know I can develop great apps, but my code doesn't feel structured... It gets messier as I add more features, and this makes it harder to develop and keep track of everything.
How can I improve this, are there any processes to follow?5 -
6 hours of manually testing a new library will save you 5 min of reading the documentation for sure!1
-
I want to develop a Web App for fun, but can't quite get my mind set on something interesting.
Any app suggestions I could try to make?
--This just for training purposes.2 -
I am trying to extract data from the PubSub subscription and finally, once the data is extracted I want to do some transformation. Currently, it's in bytes format. I have tried multiple ways to extract the data in JSON format using custom schema it fails with an error
TypeError: __main__.MySchema() argument after ** must be a mapping, not str [while running 'Map to MySchema']
**readPubSub.py**
import apache_beam as beam
from apache_beam.options.pipeline_options import PipelineOptions
import json
import typing
class MySchema(typing.NamedTuple):
user_id:str
event_ts:str
create_ts:str
event_id:str
ifa:str
ifv:str
country:str
chip_balance:str
game:str
user_group:str
user_condition:str
device_type:str
device_model:str
user_name:str
fb_connect:bool
is_active_event:bool
event_payload:str
TOPIC_PATH = "projects/nectar-259905/topics/events"
def run(pubsub_topic):
options = PipelineOptions(
streaming=True
)
runner = 'DirectRunner'
print("I reached before pipeline")
with beam.Pipeline(runner, options=options) as pipeline:
message=(
pipeline
| "Read from Pub/Sub topic" >> beam.io.ReadFromPubSub(subscription='projects/triple-nectar-259905/subscriptions/bq_subscribe')#.with_output_types(bytes)
| 'UTF-8 bytes to string' >> beam.Map(lambda msg: msg.decode('utf-8'))
| 'Map to MySchema' >> beam.Map(lambda msg: MySchema(**msg)).with_output_types(MySchema)
| "Writing to console" >> beam.Map(print))
print("I reached after pipeline")
result = message.run()
result.wait_until_finish()
run(TOPIC_PATH)
If I use it directly below
message=(
pipeline
| "Read from Pub/Sub topic" >> beam.io.ReadFromPubSub(subscription='projects/triple-nectar-259905/subscriptions/bq_subscribe')#.with_output_types(bytes)
| 'UTF-8 bytes to string' >> beam.Map(lambda msg: msg.decode('utf-8'))
| "Writing to console" >> beam.Map(print))
I get output as
{
'user_id': '102105290400258488',
'event_ts': '2021-05-29 20:42:52.283 UTC',
'event_id': 'Game_Request_Declined',
'ifa': '6090a6c7-4422-49b5-8757-ccfdbad',
'ifv': '3fc6eb8b4d0cf096c47e2252f41',
'country': 'US',
'chip_balance': '9140',
'game': 'gru',
'user_group': '[1, 36, 529702]',
'user_condition': '[1, 36]',
'device_type': 'phone',
'device_model': 'TCL 5007Z',
'user_name': 'Minnie',
'fb_connect': True,
'event_payload': '{"competition_type":"normal","game_started_from":"result_flow_rematch","variant":"target"}',
'is_active_event': True
}
{
'user_id': '102105290400258488',
'event_ts': '2021-05-29 20:54:38.297 UTC',
'event_id': 'Decline_Game_Request',
'ifa': '6090a6c7-4422-49b5-8757-ccfdbad',
'ifv': '3fc6eb8b4d0cf096c47e2252f41',
'country': 'US',
'chip_balance': '9905',
'game': 'gru',
'user_group': '[1, 36, 529702]',
'user_condition': '[1, 36]',
'device_type': 'phone',
'device_model': 'TCL 5007Z',
'user_name': 'Minnie',
'fb_connect': True,
'event_payload': '{"competition_type":"normal","game_started_from":"result_flow_rematch","variant":"target"}',
'is_active_event': True
}
Please let me know if I m doing something wrong while parsing the data to JSON. Also, I am looking for examples to do data masking and run some SQL within Apache Beam4