Skip to content

CLN: Fix CRLFs in repo + add .gitattributes #3915

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 3 commits into from
Jun 17, 2013

Conversation

jtratner
Copy link
Contributor

View this pull request with ?w=t added to the end of the url to see that there are not differences [aside from the .gitattributes files] - this should prevent more commits with CRLF entering the repo.

I think it'd be good to merge this (especially because we can avoid this happening in the future.), though (I think) it'll mess up the history for 10 minutes to pandas and pandas/core/expressions.py.

After this, will never need to deal with CRLF again! Yay!

@jtratner
Copy link
Contributor Author

Looks like it's not a huge deal in re core/expressions - it's all @jreback and looks like only 3 commits total https://github.com/jtratner/pandas/blame/8bde194aef964ff4294271bbf9da587f144ab9bd/pandas/core/expressions.py . More of a loss in 10 minutes to pandas section - https://github.com/pydata/pandas/blame/d1556237eee69aaeee47a4d1014f782413ad2d7f/doc/source/10min.rst

@jreback
Copy link
Contributor

jreback commented Jun 15, 2013

yep that was before changed my git settings to not update line endings
as I edit on windows

@jtratner
Copy link
Contributor Author

@jreback Well, this would prevent this from occurring with anyone else's contributions.

@cpcloud
Copy link
Member

cpcloud commented Jun 15, 2013

👍 on this because this gets annoying sometimes when a script barfs the oh-so-cryptic file not found error and of course there's no way to realize this until git or [text-editor-here] shows u ^M everywher

@cpcloud
Copy link
Member

cpcloud commented Jun 16, 2013

did u do a doc build?

@jtratner
Copy link
Contributor Author

@cpcloud ? do you mean check if this builds docs okay?

@cpcloud
Copy link
Member

cpcloud commented Jun 16, 2013

yep sorry didn't mean to be so terse

@cpcloud
Copy link
Member

cpcloud commented Jun 16, 2013

i can do it if u want

@jtratner
Copy link
Contributor Author

it's no problem...made me install pytables and hdf5 anyways :) took me a
while to realize that pytables is pip install tables. Anyways it'll be a
while. Def should revisit the travis doc build.

On Sun, Jun 16, 2013 at 7:56 PM, Phillip Cloud [email protected]:

i can do it if u want


Reply to this email directly or view it on GitHubhttps://github.com//pull/3915#issuecomment-19521496
.

@cpcloud
Copy link
Member

cpcloud commented Jun 17, 2013

there's a json error but i'm not sure if that's from here it might be fixed after u rebase. try it and c

@cpcloud
Copy link
Member

cpcloud commented Jun 17, 2013

well not error but "invalid" sphinx

@cpcloud
Copy link
Member

cpcloud commented Jun 17, 2013

oh what is the ?w=t that is kind of cool. where did u find out about that?

@jreback
Copy link
Contributor

jreback commented Jun 17, 2013

FYI I think the doc string is screwed up somehow in read_json which is causing that sphix error
never could format them correctly

@jtratner
Copy link
Contributor Author

@cpcloud I was trying to figure out why I was getting CRLF errors all over the place, so I explored and found that somewhere.

Okay, I need to redo this off of master (going to keep it on the same branch name though). Give me a minute.

@jtratner jtratner closed this Jun 17, 2013
@jtratner jtratner reopened this Jun 17, 2013
@jtratner
Copy link
Contributor Author

Which file is that? I can probably fix it.

On Sun, Jun 16, 2013 at 8:08 PM, jreback [email protected] wrote:

FYI I think the doc string is screwed up somehow in read_json which is
causing that sphix error
never could format them correctly


Reply to this email directly or view it on GitHubhttps://github.com//pull/3915#issuecomment-19521636
.

@jreback
Copy link
Contributor

jreback commented Jun 17, 2013

iirc pandas.io.json

@ghost
Copy link

ghost commented Jun 17, 2013

word of caution, the 11.0 release raised issues with pickle files being detected as text
by git autocrlf, should probably flag .pickle as binary in .gitattributes as they are binary
files with large chunks of embedded text.

xref #3360

@cpcloud
Copy link
Member

cpcloud commented Jun 17, 2013

problem in json docstring is nested lists, not sure exactly where but if u nest u need to separate each node from its children by a newline

@jtratner
Copy link
Contributor Author

@y-p added that and rebased.

On Sun, Jun 16, 2013 at 9:06 PM, Phillip Cloud [email protected]:

problem in json is nested lists, not sure exactly where but if u nest u
need to separate each node from its children by a newline


Reply to this email directly or view it on GitHubhttps://github.com//pull/3915#issuecomment-19522456
.

@jtratner
Copy link
Contributor Author

@cpcloud not going to try to fix this for this commit, given that the issue
isn't caused by this change (right?) Plus, I'm having a difficult time
trying to build the docs and then find that error...

On Sun, Jun 16, 2013 at 9:15 PM, Jeffrey Tratner
[email protected]:

@y-p added that and rebased.

On Sun, Jun 16, 2013 at 9:06 PM, Phillip Cloud [email protected]:

problem in json is nested lists, not sure exactly where but if u nest u
need to separate each node from its children by a newline


Reply to this email directly or view it on GitHubhttps://github.com//pull/3915#issuecomment-19522456
.

@cpcloud
Copy link
Member

cpcloud commented Jun 17, 2013

i fixed it already. was just merged #3930

@cpcloud
Copy link
Member

cpcloud commented Jun 17, 2013

@jtratner can u rebase? (just did a doc build and it was fine). will merge after the rebase...

@cpcloud
Copy link
Member

cpcloud commented Jun 17, 2013

btw i just saw the blames at the top i had no idea about this feature of gh. kind of cool

@jtratner
Copy link
Contributor Author

@cpcloud that's a git feature too (github makes it look nicer though),
checkout git blame. I rebased it, let's try merging it :)

On Sun, Jun 16, 2013 at 10:43 PM, Phillip Cloud [email protected]:

btw i just saw the blames at the top i had no idea about this feature of
gh. kind of cool


Reply to this email directly or view it on GitHubhttps://github.com//pull/3915#issuecomment-19524151
.

@cpcloud
Copy link
Member

cpcloud commented Jun 17, 2013

i like git blame but it's a bit ugly. i'm sure there are ways to make it pretty but i don't use it that often...

@cpcloud
Copy link
Member

cpcloud commented Jun 17, 2013

any objections to merging this?

@cpcloud
Copy link
Member

cpcloud commented Jun 17, 2013

@jtratner sorry 2 be a pain but what about adding lines in .gitattributes for stata, h5, xls(x) (all binary)

@cpcloud
Copy link
Member

cpcloud commented Jun 17, 2013

so that would be

+*.dta binary
+*.xls binary
+*.xlsx binary # this is xml  but god help u if ur looking at the guts of xlsx
+*.h5 binary

i think

@jtratner
Copy link
Contributor Author

stata is .dta?

@jtratner
Copy link
Contributor Author

Okay, that's done. Not going to squash b/c it's time consuming.

@cpcloud
Copy link
Member

cpcloud commented Jun 17, 2013

should be ok not to rebase, just 3 commits here.

@cpcloud
Copy link
Member

cpcloud commented Jun 17, 2013

@jtratner can u rebase? this is good 2 go after that. @jreback @y-p anything add before merging after rebase?

@jtratner
Copy link
Contributor Author

I'll do it after work tonight.
On Jun 17, 2013 9:35 AM, "Phillip Cloud" [email protected] wrote:

@jtratner https://github.com/jtratner can u rebase? this is good 2 go
after that. @jreback https://github.com/jreback @y-phttps://github.com/y-panything add before merging after rebase?


Reply to this email directly or view it on GitHubhttps://github.com//pull/3915#issuecomment-19544972
.

@jtratner
Copy link
Contributor Author

@cpcloud @jreback ready to be merged.

@cpcloud
Copy link
Member

cpcloud commented Jun 17, 2013

looks good 2 me.

@jreback
Copy link
Contributor

jreback commented Jun 17, 2013

ok here too....

jreback added a commit that referenced this pull request Jun 17, 2013
CLN: Fix CRLFs in repo + add .gitattributes
@jreback jreback merged commit 7ea6bdc into pandas-dev:master Jun 17, 2013
@jreback
Copy link
Contributor

jreback commented Jun 17, 2013

thank you @jtratner

@jtratner jtratner deleted the fix-crlf-in-repo branch June 18, 2013 02:06
@jtratner
Copy link
Contributor Author

@jreback @cpcloud @y-p et al - if you have issues rebasing on to master after this because of the line endings (should really only come into play if you were changing core/expressions.py or one of the other files changed here, you can accomplish the merge/rebase automatically by using

git rebase <branch> -s recursive -X renormalize

and this will make git ignore the differences in line endings. Thanks to this SO answer for the solution!

@cpcloud
Copy link
Member

cpcloud commented Jun 18, 2013

that is a nice solution, maybe i will webscrape pandas github repo using pandas' own read_json when i finally write up the upcoming dev workflows section of the pandas website...whoohoo! so much raw power in git

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants