bazbt3 / 10cbazbt3 Goto Github PK
View Code? Open in Web Editor NEWA Python 3 application for 10Centuries.org.
License: MIT License
A Python 3 application for 10Centuries.org.
License: MIT License
Add a help function - to slim the menu down, make it phone- (SSH-) friendly and reduce visual clutter.
See issue #31 for the background.
Delete - now that repost, star & pin are implemented and JSON parsing is working well, in that order - would be the next command to add.
Replaces #4 - user input makes the auth process easier. It would be best to have the JSON response automatically parsed though!
176
The word is 'Authe**_n**_tication' - not in itself a bug.
179
Remove space from print ("")
- between command and left bracket.
Oldest posts currently appear at the top, newest scroll down the screen. There's no means of viewing past content once it's scrolled off the top of the screen - other than by grabbing a scroll handle and manually scrolling back.
Try pausing waiting for the [enter] key - it could be a good precursor to bidirectional scroll and replying to the post above the cursor.
Right now my early interpretation of the 10C site terminology b
for a social post = 'Blurb' and p
for a blog post = 'Post' - is now counterintuitive even for me!
It might seem trivial with so much still to do, but I'm thinking of renaming, thus: p
for a social post and b
for a blog post.
If you're looking in I'd appreciate feedback. What do you think? What should I choose?
I wondered why my initial attempt at a Mentions timeline didn't look 'right.'
I've 2 accounts right now, with no way of knowing which I'm logged in with.
Issue moved from original #13.
Then installing them is just a pip install -r requirements.txt away.
Probably should just use setup.py, but that's a bit beyond me, too. :)
Something like this might work:
import getpass
...
pswd = getpass.getpass('Password:')
From 10cv4 post 12654:
@jextxadore
@bazbt3 Honestly, it'd be awesome to have a retro app. How much work would it be to make it function like an IRC client? 3 columns: post ID, user, and post content; replies could use a currently-unused indicator like %
. So a reply might be entered as:
%16789 a reply
And would look like:
@you a reply<br>// @someoneelse
What worked earlier in the hometimeline routine failed after newly creating the global variables, creating the ownblurbs routine. I don't know why.
I've temporarily reverted to calling the timeline by data passed to the server rather than appended to the URL - see dbd7f26
https://api.10centuries.org/auth/status
(at https://docs.10centuries.org/auth#status page) is available, but where should I use it?
One-line Blurbs & blog posts are easy - sentences on the one line work well. The API adds emphasis just fine, but it looks a bit odd, all running on.
In a nutshell, the first press of the [Enter] key commits the post. it's efficient for this stage of code development, that's all.
Asking potential users to edit code before running the application is silly. Nonetheless I need to have a section in this early code to allow users to choose the default directory or folder - it'll be useful to allow portability between Linux and Windows.
I'd like to present the smallest possible footprint, always checking the server is inefficient.
Need to check how to append data to an existing set and save it.
This one's a biggie. For an ordinary user the pages of response are essentially gibberish. I don't have enough knowledge right now to fix this - but I'll figure it out.
Doing this should reduce the risk of copy-paste errors or missed updates. This is probably obvious to someone with more experience than I.
At this stage the auth token is saved within the entire API JSON response, and must either:
(Follows on from successful resolution of issue #2 - login & logout added.)
This is unexpected behaviour. The only file prerequisite should be 10cv5guid.txt
- see also issue #17.
Found during testing - I'd deleted all the post data and API response files to flush out a set of timeline bugs.
Right now the application will likely exit with an error if the developer GUID file 10cv4guid.txt
doesn't exist. I've not tested this. What does fail though: the application fails to start without authtoken.txt
- issue #28 (more urgent than this) at least proves more error checking is required.
It'd be nice to guide a user towards fixing this if it happens.
Stars, etc. aren't implemented in the 10Cv4 web interface.
Viewed on a phone over SSH, the application is very dependent on zoom level. Right now the menu is a mess, and the 'tabs' to columns don't work consistently on my Android.
An additional 'help' function would be preferable to loads of menu text. See also #32.
See #1 - once the authentication token stored in a external file issue is resolved this can progress.
Currently I don't know enough Python to have the authentication token stored in an external file so the code can be shared exactly as-is. I managed to get it working quickly in a Linux bash shell script, but have so-far failed with Python.
It's my inexperience, I'm certain of it.
I've currently no way of knowing login - in or out - status.
(Account indicator moved to #16.)
There may be other useful items I could add, but I need to be mindful of the limitations of both the current UI and my skill level.
Colour would be a good option to reduce the vertical space a post occupies onscreen - the current separators waste too many lines, e.g.:
-----------
Post 12421, by matigo (id: 1), at 2016-03-21T02:00:44Z
-----------
I get the impression that @bazbt3 does not want to say certain words...
Something like this (but in colour!) would be better:
12421
matigo (id:1)
2016-03-21T02:00:44Z
I get the impression that @bazbt3 does not want to say certain words...
A colour scheme similar to that of @ericdke's ayadn (README) seems appropriate given the enjoyment it gave me...
I'm currently not managing this via git at my computer - the code is copied & pasted to here, the docs edited via the GitHub web interface. The sensitivity of the authentication-related .txt files' contents in particular stopped me.
A .gitignore file seems sensible at this point.
@height8
's idea - to avoid filling the timeline with 'this is a test' posts. This will also allow me to test whether someone else could use my app (subject to editing the site ID for blog posts!)
Why another account? Though some might find it illuminating I'm not exactly posting meaningful messages whilst testing. If anyone chooses to follow the test account it'd be nice.
From the API docs:
"simple_posts: {Return a "Simple" Data Set [Y/N]}"
"If the simple_posts option is set to Y then a number of the tail-end values will not be included."
Repost no longer works - returning JSON format error
. The code used by the routine hasn't changed during the v0.2.3 update. Odd.
See issue #26 - timeline bug introduced, also in v0.2.3 - but which doesn't show up the morning after my attempts to fix it all failed.
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.