#dev-contrib

1 messages ยท Page 31 of 1

hardy gorge
#
pydis_site/settings.py:51:1: S105 Possible hardcoded password: 'yellow polkadot bikini'
#

that's probably why

green oriole
#

Env?

hardy gorge
#

Nah, I don't see any use in making this a required step in the set-up

#

(adding an environment key for that)

#

I'll just add a specific ignore

crude gyro
#

ah yes that'll be why then.

hardy gorge
mellow hare
#

๐ŸŽถ That she wore for the first time today ๐ŸŽถ

last patio
#

I think it would be preferable to keep the current behaviour as a fall back and use one in the env var if set

#

If we accidentally happen to enable debug in prod (or django-environ reads something wrongly, or salt messes up, or the if condition is wrong...) then we will still have a secure secret key, for one

#

That way people who want to preserve sessions can set it

#

or we have the debug setup write the randomly generated key somewhere on first start and then load from there, if you want full convenince

molten bough
green oriole
#

Pinky?

molten bough
#

that's the current danger colour

hardy gorge
#

looks good to me

green oriole
#

It look pretty good (appart from the pink)

molten bough
#

the danger colour is based on bulma's red with a saturation of 80

#

it was very.. in your face before

brazen charm
#

Maybe a tad more red

hardy gorge
#

I think the color looks good

molten bough
#

The colours were approved in an earlier PR

#

they affect a lot more than just buttons

green oriole
#

That doesn't look.. Dangerous

hardy gorge
#

it has an appropriate contrast the rest of the site

molten bough
#

anyway the colour is besides the point

hardy gorge
#

yeah

molten bough
hardy gorge
#

I think the lay-out looks good

molten bough
#

Good stuff

#

just need to get that disconnection working

brazen charm
#

any of the people that did the scraping stuff on the bot around?

#

bs4 is slowly making me lose my mind

green oriole
#

Scraping stuff?

mellow hare
#

The doc cog scrapes the python site's docs

green oriole
#

Oh yeah

hardy gorge
#

What's making you lose your mind, @brazen charm?

green oriole
#

_It seem a bit against rule 5 ๐Ÿ˜„ _

mellow hare
#

Scraping itself isn't bad. It's a tool just like anything else

#

It's used all over

#

It's just when it's used on sites that don't allow it that it becomes a problem

hardy gorge
#

We're using the intersphinx connections specifically meant for this

#

Anyway, what's driving you mad, @brazen charm?

#

oh wait, double ping

brazen charm
#

soup.find_next("a", attrs={"class": "headerlink"})
getting different results than in terms of the tag hierarchy (or how to call it)
soup.find(id="module-numpy").find_next("a", attrs={"class": "headerlink"})
When there is only one headerlink in the doc

molten bough
#

I fixed the disconnect message to make it consistent with allauth's connect message

#

Any thoughts? Is the GH button colour okay?

crude gyro
#

I don't like the pink buttons very much

#

and for the connections, maybe icons and bold names?

#

although you got an icon on the connect button.. hmm.

molten bough
#

Could do both

crude gyro
#

not sure I like the idea of a disconnect discord button that is permanently unclickable

molten bough
crude gyro
#

yeah that looks pretty good

#

but the delete account button, hm, I guess I think that button should probably white on traffic light red

#

pastels doesn't really communicate delete

molten bough
#

That's basically the bulma default, yeah

crude gyro
#

yeah and I know we redefined some of those.

#

or all of them.

#

which is nice for the notifications

#

but not sure it works for this.

molten bough
crude gyro
#

@wild ridge @tough imp @glass pecan you guys have a good eye for design. chime in.

hardy gorge
#

I personally think the pink colors are good enough in communicating what's going on + we have a special confirmation page with a type-over after it

#

I don't like those red colors in our design

molten bough
#

well not for unlinking, but for deleting we do

#

these reds are super in your face imo

#

perhaps too much

#

but we could change the saturation of the pastel red

#

haha, I set it to 100 but now it just looks like the buttons are disabled

crude gyro
#

that's very bubblegum

tough imp
#

I agree that the redest red communicates the intent a lot better

crude gyro
#

go a little darker instead maybe

green oriole
#

Can you try with a medium blue(ish) color too?

molten bough
#

for danger?

glass pecan
#

lol

crude gyro
#

blue is a very strange choice for this that I don't really see a point in trying.

green oriole
#

Oh yeah that's a special button

glass pecan
#

saturated red makes sense

tough imp
#

I agree with Scragly that is the best

glass pecan
#

at least that's my feedback regarding the colour

molten bough
#

The default bulma red almost hurts my eyes in this setup

mellow hare
#

@brazen charm I'm not sure if here is the best place to ask about beautifulsoup. Would probably still be better served in the main help channels

crude gyro
#

how about a slightly darker version of the default bulma red

molten bough
#

okay

crude gyro
#

just to test it out

brazen charm
#

Yeah wanted something about the style around it too but that's what's keeping me occupied now

molten bough
glass pecan
#

no that's good to me

crude gyro
#

I like that

molten bough
#

I kind of like it too

green oriole
#

Yeah it seem pretty good

glass pecan
#

can i give a little feedback on the page itself?

molten bough
#

Of course

tough imp
#

It helps a lot to see the page as a whole

molten bough
crude gyro
#

hmm. that red really disagrees with the blurple nav. not sure what to do about that.

molten bough
#

Bearing in mind, this will have changed the rest of the reds

green oriole
#

Maybe a bit more saturated red?

molten bough
#

darker, but more saturated? okay..

#

It's kind of a tomato colour

#

I don't hate it though

green oriole
#

I prefer this one

brazen charm
#

how does the tomato look outside of buttons?

green oriole
#

It match more the pydis blue

molten bough
tough imp
molten bough
#

I have a hard time seeing that on the page, honestly

#

my eyes don't like it

green oriole
#

Which one they don't like?

molten bough
#

the one kwzrd linked, the bulma default

#

let me make the tomato a bit brighter

#

I don't think that's half bad

green oriole
#

Can you create a new color only for button and keep the old one for the rest?

molten bough
#

I have to go help make dinner, but I'll be back after, will be on Discord either way

#

Not easily

glass pecan
#

i like the latest one, but i also like rediculously strong reds

#

@crude gyro what do you think of that one?

crude gyro
#

I'm thinking more like #D63852

#

and now I wish we had a function to display a hex

glass pecan
#

.colour D63852

crude gyro
#

yeah. that.

#

we don't have that, do we?

hardy gorge
#

We don't

glass pecan
#

its loading

crude gyro
#

if it's loading

  1. it's very slow
  2. why didn't they put is typing...
glass pecan
#

there

#

lol

#

scragly bot wins again

brazen charm
#

long response times, bad bot scargly

crude gyro
#

context

glass pecan
#

its doing more than seasonalbot for colour previews

crude gyro
glass pecan
#

yes i like that

#

works well

#

groovy even

#

so did you just edit this in photoshop

crude gyro
#

no. gpaint

#

so, even worse.

glass pecan
#

never heard of it

#

so must have been enjoyable

woeful thorn
#

the g stands for gpaint

glass pecan
#

could be worse

molten bough
#

Haha

glass pecan
#

could be gimp

hardy gorge
#

s/color 1/color 2

glass pecan
#

we all know how much you love it

molten bough
#

I'll do an actual test when I'm done in a couple hours

glass pecan
#

sure, but i still kinda want to give feedback on the page when you're back

#

i suspect i'll be kinda sleepy though

molten bough
#

I can take it now, if you like

#

:>

glass pecan
#

if you're busy it's fine

molten bough
#

I mean I can just screenshot it

glass pecan
#

but i'll likely dump my suggestions here

molten bough
#

I'm boiling berries

#

Haha

crude gyro
#

making some jam?

glass pecan
#

nah i want to change the structure

molten bough
#

No, FSAI recommendation so I don't get hepatitis

crude gyro
#

more like hepatightis

molten bough
#

Haha

#

It's because lots of imported frozen berries over the years have been infected

glass pecan
#

could you share the template file perhaps? i'm too used to tweaking via inspect

molten bough
#

And that's what we have, so

#

Sorry, I'm on a separate floor

glass pecan
#

all g

tawdry vapor
#

I liked the look of ๐ŸŒŸ so I copied it

glass pecan
#

noice

tawdry vapor
#

I'll just make a PR and you can tell me there if it needs to be adjusted

#

Like if the radius on the square is wrong or whatever

stable mountainBOT
#

@molten bough, it looks like you tried to attach a file type we don't allow. Feel free to ask in #community-meta if you think this is a mistake.

molten bough
#

oh well

#

no html file for you

crude gyro
#

yeah man that looks great @tawdry vapor

molten bough
#

I came up to get a stomach pill lol

crude gyro
#

the only question is

tawdry vapor
#

yellow plus white dont work well ๐Ÿ˜„

crude gyro
#

when it's this size, or even superstar_apply sized, how legible will it be?

hardy gorge
#

The green one has more contrast, so it may look better when it's small

tawdry vapor
#

it's displayed at 22x22

#

Well then I can ditch the gold and use red/green as the others do

crude gyro
#

most of them we have in red, blue and green

tawdry vapor
#

yeah it's just that the embed was gold so figured why not

#

but it's not very legible at that resolution

crude gyro
#

this one is better superstar_pardon

tawdry vapor
#

so red=apply green=pardon, as the others?

crude gyro
#

but at the smallest size, I still think a star without the extra details might have had better legibility

green oriole
#

(@molten bough change the extension)

molten bough
#

I mean, I'd be breaking the rules if I did that

#

Haha

crude gyro
#

question is - will we ever see it at the smallest size?

#

it's gonna be used in these embeds, and that's at least the slightly larger size, is it not?

#

maybe even larger than that

tawdry vapor
#

Depends on where

#

I was talking about mod log

green oriole
hardy gorge
#

The respective contrast ratios are 1.53 (yellow) and 2.16 (green)

crude gyro
#

yeah mod log

hardy gorge
#

Which means it's low

molten bough
#

Good point

tawdry vapor
#

Mod log is actually 20x20, even smaller

crude gyro
#

okay so then maybe just a โญ would be better than a ๐ŸŒŸ in terms of legibility.

#

yours looks nice large

#

but not sure it makes sense at 20x20

#

even at superstar_pardon size it's starting to get hard to see what it is

crude gyro
#

right, while those are crystal clear.

#

so I think we should probably go for that

tawdry vapor
#

Oh well I liked the sparkles but alas they must perish for the greater good

crude gyro
#

yes. I liked them too

#

but you gotta suffer for fashion

tawdry vapor
#

Anyone have ideas for warn/note icons btw? They are both a mail icon right now

#

At the least one of them should be different I think

green oriole
#

๐Ÿ—’?

#

For the note

crude gyro
#

hard to iconize in the style we got, would just look like a rectangle.

tawdry vapor
#

Maybe, would need to look good at 20x20

crude gyro
#

pencil maybe

tawdry vapor
#

we already use a pencil for edited infractions

crude gyro
#

right okay

#

fontawesome has a post-it one

brazen charm
tawdry vapor
#

It would probably just look like a square at 20x20 but I could try, easy to make a test

#

I made the PR, can you please double check the dimensions are correct since I did not use your PSD

hardy gorge
#

@brazen charm That's for module-level help, right?

tawdry vapor
#

Mainly, it's 128x128, square is 100x100 with a radius of 10

brazen charm
#

yep

hardy gorge
#

I'd say it's part of the documentation for that module

#

It may be the thing you're interested in

#

Maybe I'm just weird, but for some things, I look at the source code

brazen charm
#

I do too but not sure if people getting the docs like that would need it most of the time

hardy gorge
#

I say leave it in. It's part of the documentation and it's not like it's decreasing the useful info in there by a lot

woeful thorn
#

They're not really going to get much of value out of module-level help anyway, getting rid of the source makes it even less so

tawdry vapor
#

Would it be better to move it to the footer?

#

Having it first may be too prominent

woeful thorn
#

You can't put links in a footer

tawdry vapor
#

๐Ÿ˜’ never mind then

hardy gorge
#

I'd also like to keep the parser as general as possible, since it should work on any inventory link we add

#

If we add a lot of exceptions, it's going to be difficult to maintain

woeful thorn
#

I don't really see the problem with the information presented in the image

hardy gorge
#

Since we'd have to PR in changes anyway and we have this beautiful database-driven addition system to avoid that

#

Me neither, @woeful thorn, so let's just go with that.

tawdry vapor
#

@crude gyro Thanks, can you upload those to the emote server and get me the IDs?

crude gyro
#

am indisposed atm

#

maybe one of the other <@&267628507062992896> can?

tawdry vapor
#

Ok, np

hardy gorge
#

what would you like as logical names? I've got a headache and I can't think of anything.

#

ah

#

the filenames provide the solution

tawdry vapor
#

sure

#

or superstar and unsuperstar

#

or superstarify and unsuperstarify

#

the bot wont use the emotes by those names anyway so it's not important

hardy gorge
#

yeah, true

#

:superstarify: - 636288153044516874
:unsuperstarify: - 636288201258172446

#

@tawdry vapor this

tawdry vapor
#

thanks

brazen charm
#

Another things I wanted to ask, there are a few thousand symbols in the form reference/generated/numpy.nonzero in the inventory that point directly to pages (bot can't currently handle) but they all also have proper counterparts that point to a header link. Should they just be excluded with a check when building the inventory or keep them in?

hardy gorge
#

That depends on your implementation, I think. I haven't looked at your commits yet, but the !docs commands are currently specifically meant to accept any inventory url we want to add, without having to also PR in changes to the codebase. Adding inventory-specific exceptions to processing rules kinda defeats that purpose and adds the requirement of per-inventory code maintainance.

brazen charm
#

Those come from the intersphinx fetch function and are just added as normal, without any changes from me. But I'm not sure where they're coming from in the inventory (not that I looked at it)

molten bough
#

Right then

glass pecan
#

ya back?

molten bough
#

Yup

glass pecan
#

mind if i show a mockup of the idea i had then

molten bough
#

Sure thing, go for it

glass pecan
#

ok first warning

#

i think we're fighting against the inevitable by trying to design a nice full page with such sparse content

#

so i figured, why not just use a modal

molten bough
#

Modal looks good

#

but

#

it does require javascript

#

and I feel like requiring that for essentially a GDPR function is a bad idea

glass pecan
#

i don't really agree in that respect

#

if the argument was that implementing was a pain or something, then that would be fine

#

but requiring js in a website isn't unusual

molten bough
#

I don't overall mind JS and such, that's all fine

#

it's just that we have to make sure this can be got at somehow

crude gyro
#

yeah, it can

#

just by enabling JS

#

or not using your grandmas computer

#

not gonna limit our website by what you can do from netscape.

glass pecan
#

if they are absolutely adament they don't want to enable scripts beacuse they're crazy people on tor who do illegal stuff, then they can just email us

molten bough
#

Okay

#

secondly, where does the modal live? it's going to have to be on every page in some capacity, right?

glass pecan
#

unless you load the modal only after clicking a button

molten bough
#

(also, are those cards the same height when the Discord one doesn't have a button?)

glass pecan
#

don't think so, lets try

molten bough
#

I think that can be done with tiles

glass pecan
#

but that's not much of an issue either as we can just leave a disabled button there

molten bough
#

I'll have to poke it

glass pecan
#

yeah it does not

molten bough
#

right okay

#

also, where do we redirect to after GH has been linked?

#

or unlinked for that matter

glass pecan
#

homepage maybe?

#

unless there's a way to go to the current page again

molten bough
#

There might be

#

ah, wait, no

#

because after GH is linked, allauth redirects to socialaccount_connections

#

which I aliased to the account settings page

#

in theory that could be any particular page though, it just needs to be added to the urlconf a second time

crude gyro
#

could it live in the nav?

glass pecan
#

as a perma thing?

molten bough
#

I mean, it could be in that template

glass pecan
#

i dunno if that changes the redirect stuff

crude gyro
#

nav is ever present when you click that button

#

no matter where you are.

#

just a thought

glass pecan
#

but yeah obviously i didn't think of too much implementation details

#

the only thing i can contribute is the design idea

#

lol

molten bough
#

I don't disagree with the modal idea

#

I would still like the pages to be usable without JS

#

but I could look past that for now

#

no reason there can't just be a <noscript> with an extra item

#

or even just leave the anchor as it is and cancel the click in JS

mellow hare
#

The primary benefit of this being...

molten bough
#

of which specifically

mellow hare
#

Worrying about a noscript option

molten bough
#

I'm just concerned about the accessibility of a GDPR tool

mellow hare
#

We also have an email if people need to get it done

molten bough
#

Do we have that on the site somewhere?

mellow hare
#

We're not denying people access, we're just making it more accessible for the 99.99% of people who would worry about it

molten bough
#

Oh sure, I'm just saying, it's easy to cater for both

#

just add a GET param to the current page to display a template without the bits and bobs that's usually there

#

use it to template the modal

#

well actually I guess it's more complex than that given the stuff in the header of the modal, but eh

crude gyro
#

it's not something I'm particularly interested in

#

I do wonder, however, if it's possible to do the modal with pure css

molten bough
#

that's a good question

mellow hare
#

That feels... unwise

crude gyro
#

why's that?

mellow hare
#

It's a style sheet, not a language or even for hyper links

crude gyro
#

we're just showing or hiding a modal. that's well inside the realm of a style change

#

the real problem is hooking it up to a click event with pure css

molten bough
#

I mean, it is a style change, it's just the trigger

#

anyway, it is possible, but it's a hack

glass pecan
#

lemon, it's actually possible

molten bough
#

you do it using check states

mellow hare
#

It feels really terrible

glass pecan
#

zero js modals

molten bough
#

that's the pen I'm on

glass pecan
#

yeah google is good

mellow hare
#

Wow

molten bough
#

although I can't actually view it

mellow hare
#

Okay, nevermind then, that's like magic to me

glass pecan
#

thats some fancy css

molten bough
mellow hare
#

When did they give css such power?

glass pecan
#

probs css3

molten bough
#

it's basically just

mellow hare
#

I retract my statements then

crude gyro
#

hmm.. is this a checkbox styled to look like a button?

molten bough
#
.modal-state:checked + .modal {
  opacity: 1;
  visibility: visible;
}
crude gyro
#

that's very clever.

molten bough
#

it is, yeah

glass pecan
#

yeah very neat

molten bough
#

well it's more like

#

you have a label

glass pecan
#

so html elements can have state i guess

molten bough
#

and the checkbox is hidden

#

that said, how do you close the modal?

crude gyro
#

but yeah, I mean, if we can do this it solves your absurd noscript worry and is simple and straight forward. no js is better than some js, if that's an option.

molten bough
#

oh, more labels.

#

anyway, I don't think this will work

mellow hare
#

Debatable

molten bough
#

why? bulma

#

bulma's just not designed this way really

#

we'd have to duplicate tons of their CSS

crude gyro
#

huh? why do you say that?

molten bough
#

so the JS option is better imo

#

well, let me double check what they actually do

mellow hare
#

What's your suggested alternative for the noscript crowd then?

#

I guess I misunderstood that bit

molten bough
#

just also have an actual page

mellow hare
#

I mean I feel like it'd make more sense to have one or the other

molten bough
#

oh okay, their is-active is literally just display: flex;

#

I still think this breaks some behaviours, though

#

the entire background of the modal would have to be a label

crude gyro
#

is that how the codepen did it?

molten bough
#

well as I say, I can't actually view the codepen

crude gyro
#

okay, well

#

maybe you should turn on JS

molten bough
#

looking at.. yeah it looks like it from the code

#

we're using straight up ES6, I take it?

mellow hare
#

I'd hope so

molten bough
#

I don't think we have a linter

#

but I can just use jslint or something

mellow hare
#

And 'use strict';

molten bough
#

yep

crude gyro
#

anyway, was just an idea

#

I don't actually mind the js solution

#

but I do mind having two solutions just because someone might not have js

#

I'm violently opposed.

molten bough
#

okay

crude gyro
#

so, solve it without js or solve it with js, but don't do both

glass pecan
#

do you want the html i used

mellow hare
#

And I'd heavily prefer the JS solution over a CSS hack, especially since we're already using a CSS framework, and that just feels like opening a pandora's box that isn't really worth messing with

molten bough
#

I'm okay with the HTML, I do wanna change it a little

#

not a big fan of the cards on each connection but I feel like a divider between 'em might be nice

#

although I'm curious how you did the large icon with small text

glass pecan
#

with cards

#

lol it's actually just the media objects

molten bough
#

oh yeah, the media objects

#

you can just put an icon in the media-left? TIL

glass pecan
molten bough
#

that's amusing

glass pecan
#

it's mostly laziness because mocking

#

but it's actually not a bad solution

molten bough
#

It's not, yeah

glass pecan
#

at any rate, i personally prefer the boxes over a divider, so i'd like to hear options on others too about that

molten bough
mellow hare
#

I'd have to see the options before I can give an opinion

molten bough
#

it'd be like that, but with a line down the middle instead of the boxes

crude gyro
#

I like the boxes, I think.

glass pecan
#

i like the boxes primarily because the ui is consistent when they no longer inline such as on mobile

mellow hare
#

Kind of prefer the boxes, then. I thought you were thinking of having them in a column with horizontal dividing lines

molten bough
#

The divider does automatically go horizonal on mobile

crude gyro
#

or, cards I guess they are

mellow hare
#

Yea but if they're the same size as the boxes, why not boxes

molten bough
#

We could also use tiles

#

if we wanted a bit more colour

glass pecan
#

too much colour

molten bough
#

but that might be a bit 3D? I dunno

#

I just don't like plain boxes

glass pecan
#

they're not plain

#

they have a border radius, they have a drop shadow, they're more distinct than the tiles edges

crude gyro
#

I also think @mellow hare that you're grossly underestimating what CSS can (or is supposed to) do. you can use it for animations and transitions, it has state selectors for hooking up stuff like hover or focus events, this is all really performant and it's probably not fair to classify it as a hack. it's just modern.

molten bough
#

okay

#

lemon, you still opposed to having a disabled button under the Discord entry?

crude gyro
#

I think a button that will never be clickable is a little bit weird to have on a page but I don't have a very strong opinion about it

glass pecan
#

i guess you wouldn't disconnect the discord account.

#

so that makes sense

molten bough
#

we don't allow that, yeah

crude gyro
#

if you guys like it for symmetry, it's fine I guess

molten bough
#

well, that and keeping the cards the same height

mellow hare
#

Fair enough. I do need to refresh myself on that

molten bough
#

although some smartass with a big name is gonna come along and break it, but that's their own fault

crude gyro
#

yeah it's really quite cool. I've built some pretty cool shit with only CSSs. I never use JS for dropdowns anymore, I think modals are a good candidate to join dropdowns there

#

same with elements doing minor "slides" or other nice polish

#

looks and works great in pure css

molten bough
#

yeah, I did that with the messages

crude gyro
#

anything more complex than that, time to break out the big guns and make a javascript file

#

don't get me wrong, I love JS and I use it for a lot of stuff, but I'd rather avoid it if it's something so simple that even CSS can solve it.

#

having a JS file that's just like.. making an element visible? seems pointless

glass pecan
crude gyro
#

it's a style change. we should do it with our stylesheet.

glass pecan
#

I kinda don't mind it

#

it shows the linked status i guess

crude gyro
#

I'm fine with it

#

can we blurple the discord bubble?

glass pecan
#

yeah

molten bough
#

we can

glass pecan
#

its text

crude gyro
#

nice

glass pecan
#

or rather, it's an icon

crude gyro
#

I wasn't asking if it was possible

#

I was asking if you would mind doing it :D

molten bough
#

love me some animations

crude gyro
#

yeah that's a great example

#

a lot of people would have thought you needed JS for that

molten bough
#

that wasn't very 60fps of my 60fps setting

crude gyro
#

and it's not even ugly

#

it looks quite nice in the CSS file

#

nice and logical

molten bough
glass pecan
molten bough
#

That looks kinda weird with the blurple button

crude gyro
#

looks nice, although now a straight cross symmetry has arisen between the discord icon and the blurple connect

glass pecan
#

yep

#

that's why i kept both black originally

molten bough
#

maybe is-light for the button?

crude gyro
#

could make that button green, too

#

that's pretty connecty

molten bough
#

yeah, could use success

#

the rare, lesser-spotted green on the site

glass pecan
#

i kinda don't like that the text is black

crude gyro
#

yeah

#

I don't really like these pastel colors

molten bough
#

it's kind of pastelly, yeah

crude gyro
#

now that I'm seeing them in the wild

#

we switched them because we wanted less intensity for an older version of the notifications

#

but now I kinda wanna just set them back

#

because the bulma defaults are better

glass pecan
molten bough
#

I dunno, I find them harder to read on a white background

#

the green is OK though

#

however there was another reason we didn't use that green

#

scragly picked a better one a while back

glass pecan
#

thats not default, i just picked via colourpicker

molten bough
#

Ah okay

glass pecan
#

this is mainly as an idea of not-pastel i guess lol

#

or rather, not black text

crude gyro
#

well it's better than blurple

molten bough
#

If we're gonna start coming up with new colours we should probably be consistent about it

#

like that red that lemon made

crude gyro
#

wish we had someone who knew about colors who could do this stuff

#

I kinda like that red, though

glass pecan
#

D63852

molten bough
#

That's a nice red

#

yeah, that red is d63852

glass pecan
#

copying back down here for my reference

#

sorry

crude gyro
#

so you're saying, if we're gonna go green, we should maybe do a green that's sorta like pulling towards blue and a little darker?

#

so that we get a matching sort of color profile

molten bough
#

well, maybe we should just apply the same transformative difference

crude gyro
#

fancy

molten bough
crude gyro
#

okay

glass pecan
#

yeah that red is nice

#

a lot better than current

molten bough
#

actually that page is wrong

#

it's not uhh

#

granular enough

crude gyro
#

so let's work out what the transformative difference equivalent for green is. that's a fun problem.

#

thing in rgb and just copy the integer difference

#

but switching primaries

#

so that whatever we did to red, we do to green

molten bough
#

I like to do it with an actual colour picker

crude gyro
#

how's that?

molten bough
#

but yeah, basically

crude gyro
#

gimme the hex for bulma green

#

I'll solve for x

molten bough
#

48c774

#

should be 2db95e I think

crude gyro
#

I get #32AC66

mellow hare
#

That's so bizarre. I'm behind the times I guess

molten bough
#

I dunno, maybe I did it wrong

glass pecan
#

i gotta crash, so i'll see you guys tomorrow

molten bough
#

Later scrags o/

crude gyro
#

or

#

#3AAC5E

molten bough
crude gyro
#

they're both of exactly equal transformative difference

#

but pull to different sides

#

out of those, I think I like #32AC66

molten bough
#

I'll check it out

crude gyro
#

yeah, those seem like they're in the same palette.

#

nice.

molten bough
#

I think so, yeah

#

Should we do the other ones?

#

I think that's alright

crude gyro
#

yeah that looks alright

molten bough
#

You wanna do the other colours?

#

actually there's really only two more, since the turquoise is replaced with blurple

#

the blue (#3298dc) and yellow (#ffdd57)

crude gyro
#

okay, sec.

#

#2482c1 for the blue, I think

#

alternatively #1c8ac1

#

#e9cf3c for the yellow

molten bough
crude gyro
#

also possibly #f1c241

#

but that's a bit more gold

molten bough
#

It is kinda gold, but I don't hate it

crude gyro
#

these are all just coming out of some code I wrote now

#

the first blue looks like a winner, and frankly, the first yellow too

#

imo

molten bough
#

I think so too

crude gyro
#

fun to use python for picking colors.

#

the code is very ugly

molten bough
#

there are two other colours that are defined in bulma's sass

#

but they aren't used anywhere whatsoever

#

orange and purple

#

and they aren't documented either

crude gyro
#
# Transform
rgb[primary] -= 27
rgb[secondary] -= 22
rgb[tertiary] -= 14
molten bough
#

we can probably ignore them

#

Oh, nice

crude gyro
#

then you manually set primary to match whatever color you feel is the primary color you're altering

#

so, blue for a blueish color and so on

molten bough
#

oh, hng, I found a couple of uses of those too, as well as another blue

#

do we really need two blues..

#

probably not

#

I've not seen orange/purple anywhere on our pages but we can do them if you want

crude gyro
#

that yellow isn't very nice, but the blue looks great

molten bough
#

yeah, I agree

#

but then, the bulma one would have that too

crude gyro
#

that's the default one?

molten bough
#

No, that's the other yellow you gave

crude gyro
#

it's a tiny bit better.

molten bough
crude gyro
#

that one is fine too

#

so let's just use that

molten bough
#

Alright

crude gyro
#

works well with the other colors

#

better than the one I transformed I think

molten bough
#

I think it looks fine, yeah

crude gyro
#

yeah. cool. nice.

#

good. great. I like it.

molten bough
#

we could do orange/purple but honestly it's probably a waste of time

#

I haven't found a single use of it anywhere

crude gyro
#

it's easy, I got a script for it now

molten bough
#

they likely put them in as alternative primary colours

crude gyro
#

can we see what they're set to currently first?

molten bough
#

Sure

#

orange is #ff470f

#

purple is #b86bff

crude gyro
#

I like turquoise

#

that's a million dollar color, man.

molten bough
#

the problem with turquoise is that it's the default primary colour

crude gyro
#

I can see why

molten bough
#

so if we don't set it to blurple a bunch of things will be turquoise

crude gyro
#

good way to make a million dollars

molten bough
#

even if we do set the primary to blurple

#

haha

crude gyro
#

but yeah that's fine

molten bough
#

that darker blue is #3273dc also but I just set it and cyan to the blue you came up with

crude gyro
#

purp: #aa55e4
orange: #e43101

molten bough
#

those are the ones you gave

crude gyro
#

the orange sucks.

molten bough
#

yeah

#

the purple isn't bad

crude gyro
#

could be worse, how was it before?

molten bough
crude gyro
#

okay, so, keep the new purp, let's never talk about the new orange again

molten bough
#

haha

#

keep the default orange then?

crude gyro
#

yeah, it's fine

molten bough
#

Alright

#

now that that's done..

#

modal

#

well actually it's 11:30 so it might not be done today, but I'll give it a go

#

modal JS can probably be put in simple-bulma

#

I'll just do it here first for the sake of time though

crude gyro
#

yeah I think it'd be nice to have that in simple-bulma too

molten bough
#

okay, come here MDN

crude gyro
#

the second one is hilarious

molten bough
#

I couldn't believe it, haha

molten bough
#

hm

#

is it possible to actually like

#

insert a bunch of stuff into every template

#

because the page I wrote does need me to provide some variables to the template

#

I guess I could just keep the endpoint and load the template with JS

#

gah, that won't work either

#

unless the JS lib is loaded as part of that template

#

which I guess it could be

molten bough
#

not all of my JS is wiring stuff up correctly, but I'm getting there

molten bough
#

I can't get the navbar to be behind the background

#

I have no idea why

#

even if the modal is the first element in the body

#

but otherwise, it's done

molten bough
#

PR is no longer marked draft. I'm going to bed, haha.

green oriole
#

That look awesome!

#

We got a PR from dependabot on seasonalbot about security issues with the version of pillow we are using (I got the same on a personal project) do you think it is worth investigating if there is really a security issue or we just ignore it?

crude gyro
#

very nice, @molten bough

#

and @glass pecan for the design, too. this looks like an excellent implementation.

#

@green oriole I think we can assume that there definitely is one and we should probably just upgrade pillow after testing that things still work with that version.

molten bough
#

\o/

molten bough
#

Oh I just realised there's one other thing I was gonna do

#

Add an API to get connections

tranquil topaz
green oriole
#

Okay thanks!

green oriole
crude gyro
#

you should probably ping @hardy gorge when you mention him, since he'd be the best person to answer that.

#

since #dev-test no longer exists, this is definitely a bug.

#

and should be sorted out.

#

we should remove any references to that channel while we're at it.

#

if you'd like to do it, you can.

green oriole
#

Okay I'm doing a PR on message filtering, I can delete that too

crude gyro
#

hmm.

#

yeah okay, I think that would be fine. make sure you mention that you'd made this change in the PR description, though

#

it should be a fairly minor change

green oriole
#

Okay

crude gyro
#

then again.. hmm.

#

no, make a second PR for that, please.

#

it should be tested seperately

molten bough
#

Should I add that API for getting social connections for users in this PR?

#

it's already pretty big, but I don't mind if the reviewers don't

green oriole
crude gyro
#

@molten bough you mean like allowing an api call to check what someones github is? no, don't add that to the same PR.

molten bough
#

Okay

#

I think I'm happy with this PR then

crude gyro
#

it is something we want, though. but I'm a little confused as to why we need a new API endpoint for it. we have APIs for the user table already, would that not contain this information?

molten bough
#

It doesn't, no

hardy gorge
#

@green oriole that condition has always been there, since it was needed in the past. The git blame comes from me first messing the condition up and then restoring it again. As lemon says, it's no longer needed since yesterday.

crude gyro
#

wait, so how is this linked to the user then

molten bough
#

connections are in the SocialAccounts table

crude gyro
#

which has a relationship to the user?

molten bough
#

Yep

crude gyro
#

and when we make API requests to the user table, how are those relationships represented?

#

we don't get a copy of the relevant object data?

molten bough
#

Well the user table hasn't been modified

#

so I don't think so

crude gyro
#

hmm..

molten bough
#

it's also not quite that simple

crude gyro
#

I don't really understand the direction of that relationship then

molten bough
#

it's a many to one relationship

#

Well, Allauth is split across a few tables

crude gyro
#

the SocialAccounts have a user, but the user does not have a SocialAccount

molten bough
#

you have social applications, which are the oauth providers

#

social logins, which are individual logins to those social applications

#

social accounts, which are like, Discord account, GitHub account

#

and of course there are tokens in there for making further OAuth requests

#

SocialAccount is part of Allauth and has a foreign key relationship to Django's User table

#

there is no direct relationship to the Discord User table

crude gyro
#

okay okay but answer me this.

#

is this solved the same way as roles?

molten bough
#

No

crude gyro
#

so, why not? that's many-to-one too?

molten bough
#

Yeah, but not all SocialAccounts are Discord accounts

#

You can't FK the UID because it won't work for GH accounts

crude gyro
#

language

molten bough
#

they are indexed on the UID though, so it's trivial to get what you want

#

the key is (uid, provider) I think

crude gyro
#

well I'm just asking

#

does the User table have a column that contains the roles?

#

if so, I think it would be consistent if it had a column that contained the accounts

molten bough
#

You can do user.roles, yeah

#

although

#

which User table do you mean?

#

there's two

crude gyro
#

why are there two

#

I mean the ones that are synced from here

molten bough
#

Django's one and the Discord API one

crude gyro
#

right

molten bough
#

ah okay, the Discord one

crude gyro
#

they have different names?

molten bough
#

yeah, that does have .roles

#

they're both User

crude gyro
#

sorry, I'm not very familiar with the new database, I've barely touched it.

#

how the fuck can they both be User

molten bough
#

because they're in different apps

crude gyro
#

rrrr. Not a fan of that at all.

molten bough
#

me neither, but it's a bit too late to change it

crude gyro
#

why?

molten bough
#

I've been using import x as WhateverUser

#

Well, you'd have to migrate the old data somehow

crude gyro
#

why? it's just a name change. the data would stay where it was.

molten bough
#

I mean, I don't think you can just rename a table?

#

can you?

crude gyro
#

I have no idea why you shouldn't be able to do that

molten bough
#

I dunno, I've never seen that

#

I'll google it

#

yup ALTER TABLE table_name RENAME TO new_table_name

#

okay, so I guess you could do that

crude gyro
#

yeah, there seems to be a migrations.RenameModel

molten bough
#

I will say, though

#

I'm not 100000% happy with this modal because I was unable to dynamically generate the cards

#

even using the code in the allauth templates, I couldn't get Django to iterate over the list of providers

#

because they.. appear to be falsey?

#

I dunno

crude gyro
#

I'm not worried about that, we'll probably never add more providers.

molten bough
#

Yeah, I figured, I just wanted to build in the possibility to expand

crude gyro
#

yeah. and that's a good programmer instinct

#

but not a dealbreaker in this case.

molten bough
#

yeah

#

It's in there basically everywhere else anyway

#

the connections API I'd try to make do something similar

#

but the data available for each type of account is different

#

it actually totally just stores a json blob in the database because it's so different, along with a small number of standard values

crude gyro
#

sounds acceptable.

molten bough
#

if you want to get the github account name

#

it's like

#

github_account.extra_data["name"]

#

but that could probably be standardised as needed in the api endpoint anyway

crude gyro
#

gotta run now but excellent work so far anyway

molten bough
#

Thanks \o/

exotic ember
#

@green oriole hello, re: Ignore Draft PRs in .hackstats
can you show me the query_url you got that you say it work.? I am having trouble getting it to return the correct items

molten bough
#

Does hacktoberfest ignore draft PRs? I didn't know that

#

indeed, my current PR was a draft until last night but it's been counted since I first submitted it

green oriole
#

Something like this? https://api.github.com/search/issues?q=is:pr+-is:draft

#

Plus all the others args

exotic ember
#
https://api.github.com/search/issues?q=-is:draft-label:invalid+type:pr+is:public+author:kosayoda+created:2019-10-01T00:00:00%2B14:00..2019-10-31T23:59:59-11:00&per_page=300

this does not exclude draft PRs

green oriole
#

-is:draft+-label:invalid

#

You need a + between draft and label

exotic ember
#

cool, that was weird

green oriole
#

I suppose github is still parsing the request by splitting on + and then it check if there is a - at the beginning of the arg

molten bough
#

you often see spaces in search queries replaced with a +

woeful thorn
#

@molten bough where is the Discord oauth redirect uri stored/generated on site?

molten bough
#

@woeful thorn It's documented in the allauth docs, I can't remember what it is exactly

#

Each provider has their own one

#

You can't configure it

#

But you'll also see it in the oauth URL it takes you to when you try to login

exotic ember
#

I pulled new site changes and now I get stuck at Pulling postgres (postgres:12-alpine)... again after running docker-compose up :C

#

restarting the docker service 13 times did the trick

woeful thorn
#

Lucky 13

exotic ember
#

ModuleNotFoundError: No module named 'allauth'

#

hmm

#

maybe I'll rethingamagick web

hardy gorge
#

sync your pipenv

exotic ember
#

ah

hardy gorge
#

pipenv sync --dev

exotic ember
#

yeppers

#

that did not do the job for some reason

hardy gorge
#

now rebuild your container

#

I don't know why

#

Ohhh

#

Yes

#

Your container needs to be rebuild, obviously, that's the pipenv we're interested in

tawdry vapor
#

I need opinions on the note infraction icon

#

For the paperclip I have various thicknesses but I think that one is best

brazen charm
#

can't really distinguish them from my normal viewing distance. The middle one is probably the most recognizable, the paper clip taking a bit more effort and the first is hard to pick up because it's almost all white

woeful thorn
#

I like the first one

mellow hare
#

I'm also partial to the first one

#

First or second for sure, the third one makes me think "attachment"

tawdry vapor
#

A few more

#

the third is probably the most legible cause it's simple

#

but the question is if it makes sense

#

Maybe make an open envelope for warnings and a closed one for notes

mellow hare
#

Ehh, I still think the warning sign triangle thing makes the most sense for a warn

#

And my vote is still for one of the first two you shared

tawdry vapor
#

I was considering that, but we use an exclamation for other stuff

#

so it may clash with the meaning of "error"

woeful thorn
#

I think we'll be ok

tawdry vapor
stable mountainBOT
#

@tawdry vapor, it looks like you tried to attach a file type we don't allow. Feel free to ask in #community-meta if you think this is a mistake.

tawdry vapor
woeful thorn
#

lol

tawdry vapor
#

accidentally sent the svg ๐Ÿ˜„

woeful thorn
#

Hacker

green oriole
#

Oh IOS client try to resize it, so it just end up being a pixels soup

exotic ember
#

thoughts on trash as the message/embed deletion emoji?

tawdry vapor
#

I think general consensus is that a trash icon is good, but the twemoji style doesn't look too good

#

So we wanted to explore a custom icon

exotic ember
#

that is a custom icon, tweemoji style though

#

.issue 514 bot

dusky shoreBOT
exotic ember
#

I followed @brazen charm and @crude gyro's suggestion of that tweemoji one with simpler lines

#

probably misread something tbh

#

if anyone of you can give a mockup on the style I can make more attempts

tawdry vapor
#

Oh right

#

Honestly I am not the biggest fan, but it certainly does look like twemoji and it's decent enough

#

But the main concern is that it's not that clear to me at a small size

exotic ember
#

what do you have in mind? a basket like ๐Ÿ—‘ ?

tawdry vapor
#

I think a metal trash can is fine

exotic ember
#

that looks like a basketball hoop to me

tawdry vapor
#

Maybe we can do like even simpler

#

Let me look at fontawesome

#

need to get a smaller pic

#

I think the specific issue with yours is that there isn't enough contrast

exotic ember
#

I could change the colors and see

tawdry vapor
#

at the small size the two greys just blend together and the whole thing looks like a rectangle

#

doesn't help that I am using dark mode ๐Ÿ˜„

exotic ember
#

for clarification, by contrast you mean the contrast between the trashcan and the lines on the trashcan, or the trashcan and discord's dark mode?

tawdry vapor
#

Originally I meant the lines

#

but now I realise it's both

exotic ember
#

I just realized while making any of my other emojis I neglected to check them out in light mode

wild ridge
#

@exotic ember how's it look if you swap the colours?

crude gyro
#

@exotic ember I, for one, quite like the one you made.

brazen charm
#

Looks pretty good imo maybe a simpler handle and a bigger angle on the lid or bit taller can, but looks fine to me

exotic ember
#

@wild ridge trashinverted

wild ridge
#

I like the look of that one

#

Could you perhaps make it a tad lighter?

exotic ember
wild ridge
#

me likey

#

@crude gyro thoughts?

crude gyro
#

yeah I like that

#

I like it 2000.

molten bough
#

That's quite nice

#

Glad you guys are going with my idea like two years later :>

brazen charm
#

You came up with it again :P

crude gyro
#

yes, thank you @voodude, you are the trash can guy

#

that g is actually short for trash can guy

#

thank you

molten bough
#

Haha

#

To be fair your argument was a good one

green oriole
#

Oh guys

#

To find a message by id

#

you also need the id of the channel where is was sent

#

I need to go trough my model and add a new field

#

Great.

#

No other way around?

woeful thorn
#

Why do you need a new field when you're storing the URL?

green oriole
#

I don't store the url

#

I'm working on another thing

#

That's not about the reminder cog

woeful thorn
#

Then context would be helpful

green oriole
#

Yep

#

So for now I created a new model that store the message id and the deletion date

#

But if I want to delete it, I will need the channel ID too

woeful thorn
#

Why not store the URL

green oriole
#

You can delete a message with his URL?

woeful thorn
#

No, but you can get a Message object from its URL

green oriole
#

Or I could also loop through channels and try to find the message..

#

Well, I suppose let's go for the URL

#

How can I find a message by it URL?

#

I can't find any docs on it

green oriole
#

How do you use that thing? It's a command?

tawdry vapor
#

If discord.Message is used as the type annotation for a parameter, then that converter will be used

woeful thorn
green oriole
#

Storing the URL wouldn't take more place in the database than storing the message ID and the channel ID?

woeful thorn
#

I don't think we're doing this on a scale where it really matters either way

green oriole
#

What should I pass as context? Because this is a background task, there is no context

#

Apparently it use ctx.bot and ctx.channel if it can't find the channel

#

So I should be able to construct an arbitrary context object right?

green oriole
#

@tawdry vapor I don't understand.. If discord.Message is used as the type annotation for a parameter, then that converter will be used.. So I can just add an argument url: discord.Message and the url will be automatically converted to a message object?

tawdry vapor
#

I think I misunderstood the context so perhaps ignore me

#

what I said applies when you're taking an argument for a command

green oriole
#

Oh an argument for a command okay

#

BTW it turn out to be a bad idea to store the url because the converter want a context that I can't provide

#

I think I'm just going to store the two ids

jade tiger
#

You can create a dummy ctx as long as it has the bot attribute if using a url

#

ctx = commands.Context(bot=self.bot)

#

Since MessageConverter will use

  1. Bots message cache
  2. Get channel id from url and use `ctx.bot.get_channel(id).
  3. Get message with channel.fetch_message
#

The only caveat is if the channel doesn't exist (and bot.get_channel returns None) as it will fall back on ctx.channel which gets channel from ctx.message.channel which will raise an Attribute error since the message is None. A dirty fix for that would be to just set ctx.channel to be None manually too

#

Storing the 2 IDs may be easier and more efficient, especially if you're using .history() rather than fetch_message

split meadow
#

.issue 299

dusky shoreBOT
split meadow
molten bough
#

The specific thing that's being thought about atm - my PR adds GH account linking to the site, and there was a discussion about adding that connection to the API to be exposed on the Discord API User objects

#

although I note that seasonalbot doesn't actually have API creds

#

so maybe we should talk about that at some point

split meadow
#

Unless we integrate it into Python Bot?

molten bough
#

hmm, I guess

crude gyro
#

yeah we don't really wanna add the site dependency to seasonalbot.

#

but something like a !github command for bot might be fine.

molten bough
#

That seems fair

split meadow
#

I think that's a shout.

#

Maybe put the full functionality in the PR into the bot itself?

#

In that case what should I do with issue 299? Stall it or close?

exotic ember
#

I've transferred it to bot based on new discussion, but we'd still have to wait for gdude's stuff before further implementation discussion

molten bough
#

Once the current PR is reviewed and merged, I can start on making the connections available to the API

green oriole
#

@jade tiger I tried creating a dummy context, but the code seem to get stuck when it reach it. Do you have a link to the doc for .history()? Ctrl + F doesn't work :)

gusty sonnet
#

Are you trying to go through channel.history for a discord bot?

#

Take note that this is classified as API abusing - it is requesting data from discord api

green oriole
#

For now I just use fetch_channel and get_message

#

I think it will be faster

#

Because it doesn't loop over the history right?

gusty sonnet
#

get_channel is faster

#

the first is almost O(1) while the 2nd is asking discord api

#

It does not loop over history, yes

#

It'll try to get the object from the bot's current cache

green oriole
#

Or it was fetch_message I can't remember

gusty sonnet
#

fetch_message is targetting a specific message, it is an API too but yes it can be faster than asking for full history

hollow lichen
#

What does return fetch_message when the message is deleted?

gusty sonnet
#

Probably a None / it'll raise an Exception

hollow lichen
#

I thought it could return the message object, because discord does store deleted messages I think

gusty sonnet
#
Raises
--------
:exc:`~discord.NotFound`
    The specified message was not found.
:exc:`~discord.Forbidden`
    You do not have the permissions required to get a message.
:exc:`~discord.HTTPException`
    Retrieving the message failed.```
#

Yep it'll raise exception

hollow lichen
#

ok ty

green oriole
#

Yep it raise a NotFound

#

How do I calculate the coverage for the site repo?

#

(to make sure it's still 100%)

hardy gorge
#

you can run the tests locally, but the best way to do that depends on your set-up

#

You're running it without docker right?

green oriole
#

Yep

hardy gorge
#

pipenv run coverage run manage.py test to run the tests
pipenv run coverage report -m to get the report after running the tests

molten bough
#

holy issue spam batman

brazen charm
#

seeing that there are going to be a couple issues for tests, how hard is it to make them? ๐Ÿ˜„ Could try something after I figure out the docs command properly

green oriole
#

99% arg! ๐Ÿ˜„