Where communities thrive


  • Join over 1.5M+ people
  • Join over 100K+ communities
  • Free without limits
  • Create your own community
People
Activity
  • Feb 03 07:40

    abandoned-prototype on circleci-test

    (compare)

  • Feb 03 07:33
    abandoned-prototype synchronize #904
  • Feb 03 07:32

    abandoned-prototype on circleci-fix

    Fix circleci deployment. Teste… (compare)

  • Feb 03 07:26
    abandoned-prototype opened #904
  • Feb 03 07:24

    abandoned-prototype on circleci-fix

    Fix circleci deployment. Teste… (compare)

  • Feb 03 06:58

    abandoned-prototype on circleci-test

    CircleCI Test2. (compare)

  • Feb 03 06:46

    abandoned-prototype on circleci-test

    CircleCI Test. (compare)

  • Feb 03 01:23
    AetherUnbound added as member
  • Feb 02 05:01
    abandoned-prototype commented #900
  • Jan 24 01:14
    abandoned-prototype edited as member
  • Jan 17 04:56
    dependabot[bot] synchronize #897
  • Jan 17 04:56

    dependabot[bot] on npm_and_yarn

    Bump qs from 6.5.2 to 6.5.3 Bu… (compare)

  • Jan 17 04:56
    dependabot[bot] edited #897
  • Jan 17 04:56
    dependabot[bot] synchronize #896
  • Jan 17 04:56

    dependabot[bot] on pip

    Bump pillow from 7.2.0 to 9.3.0… (compare)

  • Jan 17 04:56
    dependabot[bot] edited #896
  • Jan 17 04:56
    dependabot[bot] synchronize #871
  • Jan 17 04:56
    dependabot[bot] synchronize #882
  • Jan 17 04:55

    dependabot[bot] on npm_and_yarn

    Bump hosted-git-info from 2.6.1… (compare)

  • Jan 17 04:55

    dependabot[bot] on npm_and_yarn

    Bump node-sass from 4.13.1 to 7… (compare)

redshiftzero
@redshiftzero
sorry for delay - @pierwill i would add a unit test that uses the new route to define a new department preference and then asserts the correct department preference has been saved in the database
pierwill
@pierwill
thanks. need a model or functional test?
or would that test you described go in functional
redshiftzero
@redshiftzero
an additional test in test_routes.py is all that's needed - that said additional functional tests are always welcome
i was describing a unit test that would go in test_routes.py
pierwill
@pierwill
okay
how does one run just one unit test?
redshiftzero
@redshiftzero
pytest tests/test_routes.py::Class::nameOfTest
pierwill
@pierwill
:thumbsup:
pierwill
@pierwill
how far off am i?
def test_user_can_change_dept_pref(mockdata, client, session):
    with current_app.test_request_context():
        login_user(client)

        form = ChangeDefaultDepartmentForm(dept_pref = None)

        rv = client.post(
            url_for('auth.change_dept'),
            data=form.data,
            follow_redirects=False
        )

        assert 'User can change default department' in rv.data
redshiftzero
@redshiftzero
structure is perfect - two notes 1. why is dept_pref=None? i'd expect that to be a valid department in the test database and 2. i'd have the assert be whatever message is flashed when the department preference is saved
pierwill
@pierwill
  1. the routes are different depending on whether dept_pref == None is true. so i was gonna have it try both None and 1..?
  2. ah ok
None is allowed: ie, a registered user with no preference
Freddy Martinez
@b-meson
@tmc the latest branch exifstrip might be a first pass at stripping jpg ?
Travis Cline
@tmc
nice
redshiftzero
@redshiftzero
note that pngs do not have exif data @b-meson
and the only extensions we allow are jpg, jpeg, gif, png for reference
Freddy Martinez
@b-meson
hmm, another thing we can do is use PIL to see if the upload is an image, if not, throw it away. for example someone could append .jpgto a PDF. (if they read our source and still upload to our bucket)
these logos are so cute lucyparsons/OpenOversight#253
pierwill
@pierwill
i gotta quit y'all. getting late here. thanks for your help everyone!
redshiftzero
@redshiftzero
night @pierwill :-)
Holden Grissett
@HoldenGs
Hey guys, novice question. I made one small change to an html file. Should make a new branch, commit, and do a PR, or should I just commit it to an existing branch?
This is for issue #378 for reference
Travis Cline
@tmc
generally separate concerns should go into separate branches and prs
Holden Grissett
@HoldenGs
Okay
Travis Cline
@tmc
useful git alias:
r = for-each-ref --count=15 --sort=-committerdate refs/heads/ --format='%(refname:short)'
edit-branch / edit-branch-develop are how I do squashing
redshiftzero
@redshiftzero
those are lit aliases
Freddy Martinez
@b-meson
hmm my exif strip is failing, I will continue to poke at it in a VM
Travis Cline
@tmc
@redshiftzero git branch --merged |grep -v '^*' |xargs -L1 git branch -d
redshiftzero
@redshiftzero
that is super handy ^
ok im signing off to clean up the (physical) room and such. thanks everyone for helping out today! if you're interested in making future PRs, we'll keep this room around and we always love contributions :-)
Stuart Kuredjian
@dbconfession78
worked on 387 otw home. going to sleep. wlil submit pr tom
camille
@ssempervirens
thanks @dbconfession78 !
Mason D.
@r4v5
Howdy hey, another hackathon starts in ~4 hours. Physical location is Chicago at South Side Hackerspace, 1048 W 37th St, Chicago, IL but you're of course also welcome to attend remotely.
Just a warning that it's gonna get chatty again for the first time in... ten months
int10h
@brianmwaters
Hello! I am here! I am mostly going to be working w/ the OJB team on officer photos
McEileen
@McEileen
Delightful! I am also here.
int10h
@brianmwaters
it looks like the baltimore folks are doing presentations and other stuff until 4:30 EST so maybe i'll do some PR's until them
McEileen
@McEileen
cool, I'm working on this lucyparsons/OpenOversight#506
redshiftzero
@redshiftzero
so the tricky part with the officer profile upload in #506 is that once we upload the photo, we then want the user to go to a page similar to the officer identification page to select the bounding box containing the face of the officer in question, then we use that bounding box to make a cropped version of the photo (crop_data is the variable in the diff that should contain the bounding box). the goal here is to only display cutouts/cropped photos containing just the face of an officer on their profile
[resolving merge conflicts and testing it as is still a good place to start, as you test you'll see what i mean above ^]
McEileen
@McEileen
Hey @redshiftzero, is there anywhere we're storing photos to test the upload feature with? I can obviously find photos to use somewhere, but for some reason I thought you had mentioned images stored in a S3 bucket.... thanks!
redshiftzero
@redshiftzero
we are using S3 in prod, but to test with the current code one would need to make an aws account and a test S3 bucket (i do this for testing rn) following this: https://github.com/lucyparsons/OpenOversight/blob/develop/DEPLOY.md#s3-image-hosting
McEileen
@McEileen
on it, thanks
Mason D.
@r4v5
Any idea why the selenium test_functional.py:test_lastname_capitalization seems to be failing? McEileen said some things that implied it wasn't just me seeing it
redshiftzero
@redshiftzero
is it failing locally reproducibly for yall?
CI is passing
want to open up an issue? (even if its a flake) worth tracking and squashing