Skip to content
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

[Feature]if viewing a board and then creating a pin, automatically select that board in the new pins board list. #256

Open
MWP opened this issue Mar 8, 2021 · 13 comments
Labels
enhancement A feature request or general improvement

Comments

@MWP
Copy link

MWP commented Mar 8, 2021

Hi all,

So just added a pin to a private board, but im finding that the pin is still visible when not logged in (its not private).
If pins on a board don't adapt the privacy option of the board, what is the point of having the board privacy option?

Thanks.

@winkidney
Copy link
Member

winkidney commented Mar 8, 2021

Hi,
In Pinry, you could pin a image to your board from other's Pin board, your Pin is just a "symbol-link" of OriginalPin so you will never have access to change its status (privacy option for example).

If you want to hide both the Pin and the board, you should set the board as private and Pins in the board as private (But you could never affect the Pin which you don't owned).

Even in this case, privacy option for board also has its sense: you could hide your own collection as you wish.

This is the point currently, If you have any better idea, please send a PR or we could have more discussion.

@MWP
Copy link
Author

MWP commented Mar 8, 2021

I see.
Maybe a small change could be made: If you're adding a new pin and select a board that is private, the pin's private checkbox also becomes ticked.

@winkidney
Copy link
Member

I see.
Maybe a small change could be made: If you're adding a new pin and select a board that is private, the pin's private checkbox also becomes ticked.

It make sense and thanks for your advice.
I will finish this change once I have time, PR is very welcome : )

@MWP
Copy link
Author

MWP commented Mar 10, 2021

That would be great, thankyou.

And a couple more suggestions if you don't mind:
1 - allow source URLs over 256 chars long
2 - if viewing a board and then creating a pin, automatically select that board in the new pins board list.

Thanks again.

@winkidney
Copy link
Member

That would be great, thankyou.

And a couple more suggestions if you don't mind:
1 - allow source URLs over 256 chars long
2 - if viewing a board and then creating a pin, automatically select that board in the new pins board list.

Thanks again.

The second one is nice to have while I'm not sure about the first one.

Some strange URL has too many unexpected arguments (for exampel useless query string but we don't know whether it is useless), We have no silver bullets for this and I don't want the URL grows day by day.

Do you have any better idea?

@MWP
Copy link
Author

MWP commented Mar 11, 2021

Well, I was trying to pin some facebook image URLs a few days ago which didn't work due to the URLs being over 256 bytes.
I tried trimming the URLs down, but it seems Facebook uses the URL to enforce image timelimits, and other things. Changing/removing any of the args invalidated the image.
Hence my request.
The industry standard for max URL length appears to be 2048 chars.

@winkidney
Copy link
Member

Length change has been done, you could update your source code right now or docker image later after the automatic building done.

Another one will be done once I have time.

@MWP
Copy link
Author

MWP commented Mar 11, 2021

Amazing, thank you!

@winkidney winkidney changed the title Boards & privacy [Feature]if viewing a board and then creating a pin, automatically select that board in the new pins board list. Mar 12, 2021
@winkidney winkidney added the enhancement A feature request or general improvement label Mar 12, 2021
@MWP
Copy link
Author

MWP commented Mar 21, 2021

Length change has been done, you could update your source code right now or docker image later after the automatic building done.

I just updated my docker image, and it appears the 256 character limit is still in place?

@winkidney
Copy link
Member

Sorry, migrations should be done by hand.
Please have a try and tell me what happened, thanks.

docker exec -it <your-docker-container-id> bash
# then
python manage.py migrate --noinput --settings=pinry.settings.docker

@MWP
Copy link
Author

MWP commented Mar 23, 2021

root@wheeee:~# docker exec -it pinry bash
root@c3742dc8910f:/pinry# python manage.py migrate --noinput --settings=pinry.settings.docker
Operations to perform:
Apply all migrations: admin, auth, contenttypes, core, django_images, sessions, taggit, users
Running migrations:
Applying core.0010_auto_20210311_1521... OK
root@c3742dc8910f:/pinry# exit

I then stopped and restarted the container.
The 256 char limit is still in place.

To make sure the migration did work, I tried your instructions again and it reported "No migrations to apply.".

@winkidney
Copy link
Member

winkidney commented Mar 24, 2021

Thanks for your feedback, the url length limit also exists in frontend.
I've changed it now.
ref: 659ad35

Please wait for latest docker-build or build it by yourself then restart your container, it will work.

Please contact me if you have any problem.

@MWP
Copy link
Author

MWP commented Mar 24, 2021

Perfect! Confirmed it works at longer lengths.
Thankyou.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement A feature request or general improvement
Development

No branches or pull requests

2 participants