« first day (1272 days earlier)      last day (1983 days later) » 

00:22
Still open for a second pair of eye if anyone wants to lend them
There were only 3 Ruby questions in the edit review queue.
 
1 hour later…
01:34
The close-vote queue is an unhappy task. I'd rather do yardwork, and I hate yardwork.
how many points does one ned for it
01:48
Let me check.
that is like 20 of me\
to the cloning machine
!
02:05
:)
 
8 hours later…
10:06
hello
10:48
hey all
12:47
And my edit was approved by the original poster.... Clearly there something weird going on.
2 rep, so closing on 2k :P
13:06
morning
Morning @Btuman :)
Anyone want some a bit of random fun with bcrypt and rails
I made a fascinating discovery
turns out that trying to have an attr_accessor in a model, it kills a lot of the functionality in terminal
it was trippy
also good morning
13:29
Happy monday for ya'll Americans
13:46
Happy second Monday to me!
@Btuman That does sound strange.
@Marc-Andre The original poster is notified of an edit in the queue and can approve it unilaterally.
My guess is that it overrides the default bcrypt methods
@WayneConrad I know I'm just surprised that there were no other reviewer and that the poster had time to see the notification. Edit are quite slow now... Another reasons to try to get more rep!
 
2 hours later…
15:25
I guess now that I'm at work, it's officially morning. Good morning.
Its lunch time for me :D
Yeah I'm close to lunch time too
0835 here. Got to work late.
16:20
Anyone up to give me a look on something before I put it up on SO as a quesrtion
Hey
I am trying to deploy my app
error log coming up
hey
"Precompiling assets failed." I have put the line

config.assets.initialize_on_precompile = false

on my config/application.rb , it still tries to compile
Preparing app for Rails asset pipeline
remote:        Running: rake assets:precompile
remote:        I, [2017-07-05T15:46:11.381478 #1315]  INFO -- : Writing /tmp/build_c3ecd015b78e364057be61a14d4cb92a/public/assets/g8-c0dd1daad5c43481ffc007690d3f30ed029d6982f70f4f61
a715966c6b413695.jpg
remote:        I, [2017-07-05T15:46:11.385901 #1315]  INFO -- : Writing /tmp/build_c3ecd015b78e364057be61a14d4cb92a/public/assets/web-70542af15a26b543e32cbdecd55db7aa184dfb8a5f4c2bf
7f84ab76874aa5a60.jpg
remote:        rake aborted!
What code did you run to get it to do that?
@Btuman If it's big, stick it in a gist. But if it's big, the odds of us being able to look at it go down some.
If it's not big, just post it here.
16:28
I ran git push heroku master...
Alternatively, anyone know where else i can deploy my app for test?
A VM running on your box?
kk, I will paste it in . I could be brain farting, but I am not sure
Form:
<%= form_for @user, remote: true do |f|%>
<%= f.label :password %>
<%= f.password_field :password, class: 'form-control' %><br>
<%= f.submit "Save", class: "btn btn-primary" %>
controller action
def update
@user = User.find(params[:id])
@user.password= params[:password]
if @user.save!
flash[:success] = "password updated"
redirect_to root_path
else
redirect_to edit_path(@user)
end
Routes:
get "users/edit/:id" => 'users#edit', :as => :edit
Resources for Machine Learning with Ruby if anyone is curious
The form is not and has not been saving the passwords
I can do it in the console
Btuman, is it whitelisted in the params?
Well i guess you're going straight against the params... so probably doesn't matter
16:33
@WayneConrad i needed it online in order to test subdomain creation and functionality. my app depends heavily on that. I am sorry i have to leave after asking this. I'll be back in an hour guys.. Wayne, i'll need a bit more guidance from you on that.
@Jared yup
def user_params
params.require(:user).permit(:password)
end
@Ndeto my question would be why do you not want your assests compiled?
But yeah, if it is not something that sticks out, I will ask
I would change @user.password = user_params[:password]
What does "not saving passwords" mean? Does it mean that the controller reports that the password was updated but it was not? Or does it mean that the controller reports an error?
16:40
as forms are generally params of {user: {password: '...' } }
@WayneConrad I get User Load (0.3ms) SELECT "users".* FROM "users" WHERE "users"."id" = ? LIMIT ? [["id", 1], ["LIMIT", 1]]
(0.1ms) begin transaction
(0.1ms) commit transaction
but no changes
Your controller has two paths it can take: One for success, one for failure to save. Which path is it taking?
Yea, my money is on params[:password] not existing and therefore still empty password
Wayne, seems to be success but let me try something
Jared
I think that was it
I am double checking now
yup
thanks @jared
No problem. :D
user5870134
17:05
@Marc-Andre Thanks! What's the model?
@Mango I'll need to check at home. I don't have the information at work
 
1 hour later…
18:44
@Jared I have read on several stack overflow threads that it shoulld solve the problem
19:29
@Ndeto Not having assets solves a problem?
What I'm trying to state is why not fix the issue of precompiling rather than trying to skip it?
13
Q: Heroku upload-Precompiling assets failed

user2930724I need help. When trying to upload my app to heroku, I get this error, anyone know why? A few was wrong. thanks Using rake (10.1.0) ... Using tlsmail (0.0.1) Using uglifier (2.1.2) Your bundle is complete! It was installed into ./vendor/bundle -----> Writing c...

2
Q: Getting Error while pushing into Heroku (Precompiling assets failed.)

Arun Kumar KandasamyNote: I am using Rails 3.2.13 and Ruby "1.9.3", and postgres-0.15.1 I tried to push my Ruby on Rails app in to heroku by following the procedure this website http://ruby.railstutorial.org/ruby-on-rails-tutorial-book#sec-deploying , but I got error while try to push into heroku Connecting t...

@Jared Well i am trying to find the issue. I saw some other thread about renaming the files with the extensions css.scss
@ndeto based on your SyntaxError: Unexpected token name «outlineAlpha», expected punc «,» error it looks like it could be a Javascript version issue with Uglifier
execJS specifically,
Let me dig around to see what that is
 
2 hours later…
21:49
So i figured it out.. It can be hard to debug when something is new :-|
There was a syntax error in one of my JS files.. To trace it i had to put this in the rails console
JS_PATH = "app/assets/javascripts/**/*.js";
Dir[JS_PATH].each do |file_name|
  puts "\n#{file_name}"
  puts Uglifier.compile(File.read(file_name))
end
Which showed me which file had an error and where.
That's nice.
You could put that into a rake task, if you want.
89
A: "rake assets:precompile" gives punc error

Sergey ReutskiyA more universal way to find the problem in js-assets: Run rails console and: JS_PATH = "app/assets/javascripts/**/*.js"; Dir[JS_PATH].each do |file_name| puts "\n#{file_name}" puts Uglifier.compile(File.read(file_name)) end

Then you could do rake check_js or some-such.
@WayneConrad The code?
Yeah. I like to take little useful things like that and make them into rake tasks. So I won't forget how to do them.
Or more properly, so I won't have to remember how.
21:59
Ooooh, so that you just run a command when you need to find the error.. So how do you create a rake task?
Inside a rails project, you should find--somewhere--a directory called "rake". You drop a file in there, with a little bit of boiler-plate, and your code.
Or you use a generator...
@WayneConrad Oooo magic! We all love magic, right?
Rake is good magic. It works, it's understandable, and I rarely have to open it up and look inside to see what the gears are doing.
Generators, I'm not so sure. If you only have to use them, they're pretty good magic. Creating them, I'm not so sure.
22:15
Well that was easy
Awesome stuff Wayne
I'm glad you like it.
22:46
Well goodnight people. Im done for now, I should be getting a domain tommorow to do tests... I forgot my cards at my office desk, cant buy a domain name
Its 1:46AM here -_-
Thanks again!
@Ndeto G'nite, see you soon.

« first day (1272 days earlier)      last day (1983 days later) »