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

Use pipenv for docs development environment #92

Merged
merged 1 commit into from Nov 26, 2018

Conversation

@jwflory
Copy link
Member

commented Nov 24, 2018

To make it easier for people to contribute to the docs, I added a Pipfile to support using pipenv. It takes the mess out of virtualenvs in Python (especially helpful since this is a Node project, and new developers might not be familiar with Python tool chains).

I'll support this with how-to documentation, as per #77.

@jwflory jwflory added this to the v1.2.2 milestone Nov 24, 2018

@jwflory jwflory self-assigned this Nov 24, 2018

@jwflory jwflory requested a review from RITlug/teleirc-developers-commit-access Nov 24, 2018

@jwflory jwflory force-pushed the change/docs-pipenv branch 2 times, most recently from 74dfc70 to 0b2f02c Nov 24, 2018

@jwflory jwflory force-pushed the change/docs-pipenv branch from 0b2f02c to 700832f Nov 25, 2018

@robbyoconnor

This comment has been minimized.

Copy link
Contributor

commented Nov 26, 2018

Shouldn't we update docs for working this? That said, this can probably be done in a follow-up PR

@robbyoconnor robbyoconnor merged commit 667e411 into master Nov 26, 2018

3 checks passed

codeclimate All good!
Details
continuous-integration/travis-ci/pr The Travis CI build passed
Details
continuous-integration/travis-ci/push The Travis CI build passed
Details

@robbyoconnor robbyoconnor deleted the change/docs-pipenv branch Nov 26, 2018

@jwflory

This comment has been minimized.

Copy link
Member Author

commented Nov 26, 2018

@robbyoconnor Thanks for the review. Yeah, I'm definitely planning to follow up with another PR soon for this. 🙂

Sadin added a commit to Sadin/teleirc that referenced this pull request Nov 28, 2018

Update fork (#2)
* Fix Dockerfile

* Only build CI against supported versions

* Resolve merge conflict

* Implement Sphinx documentation for Teleirc

* Update version number, expand authors, set node dependency

* Add CodeClimate support

* Remove MetaBrainz, add Pure Data (closes RITlug#54)

* Improve organization of project working directory

* Added CityZen app details

Added it first because i assumed the projects are added alphabetically.

* Add Hamara Linux Project

* Fix docker images

- Since dotenv is used, remove the gitignore and version the whole config.js file
- Fixes RITlug#60 -- add python and build-base to the alpine image
- Lower the UID by one to not conflict with nogroup in the alpine image
- Nuke the slim image as it adds very little benefit.
- Update docs accordingly
- Update yarn lock file
- Update docs to have users install yarn

* Update broken documentation link

* Add note to the installation docs that Telegram channels are not supported (RITlug#70)

* Fix link rot

* Nickserv identify (RITlug#65)

* NickServ identification + tests

* Ignoring direct messages + messages sent to other channels that the configured one

* NickServ identification will not happen when NickservService is empty in configuration
Also changes length comparison from "!=" to ">".

* Review findings addressed.

* Added bot nick to IDENTIFY message
* Added attempt to rejoin after a message from NickServ if not joined already (not tested yet)

* Crash on Telegram bot errors

* IRC Handler Refactor (RITlug#72)

* Added (untested) IrcHandlers.  These are so our IRC response logic is in separate classes, not in all one function.

The idea is maybe we can eventually make our IRC responses more advanced or configurable, and that is more easily doable through classes.

* Added Requires and and exports.

Added unit test for ErrorHandler.

* Added unit tests for the action handler.

* Added Kick and Join handler unit tests.

* Added unit tests for MessageHandler and PartHandler.

* Bind *all* the things (...thanks node...).

* Rename IrcHandlers so they have "Irc" in front of their names, so there is no mistake.

* Renamed classes so they have "IRC" in front so they are not confused with Telegram.

* Remove nodeunit... added it by accident.

* Added new lines at the end of the handler files.

* capital H... this is what I get for doing this on Windows...

* Added a helper function "StringExistsIgnoreCase".

This function is used to check for black-listed usernames, but can be used for other things as well.

* === instead of ==.

* Changed wording on joining a channel.

* ReportMessage -> RelayMessage

* Added (untested) IrcHandlers.  These are so our IRC response logic is in separate classes, not in all one function.

The idea is maybe we can eventually make our IRC responses more advanced or configurable, and that is more easily doable through classes.

* Added Requires and and exports.

Added unit test for ErrorHandler.

* Added unit tests for the action handler.

* Added Kick and Join handler unit tests.

* Added unit tests for MessageHandler and PartHandler.

* Bind *all* the things (...thanks node...).

* Rename IrcHandlers so they have "Irc" in front of their names, so there is no mistake.

* Renamed classes so they have "IRC" in front so they are not confused with Telegram.

* Remove nodeunit... added it by accident.

* Added new lines at the end of the handler files.

* capital H... this is what I get for doing this on Windows...

* Added a helper function "StringExistsIgnoreCase".

This function is used to check for black-listed usernames, but can be used for other things as well.

* === instead of ==.

* Changed wording on joining a channel.

* ReportMessage -> RelayMessage

* Integrated IrcNickServHandler into TeleIrc.js

Updated various unit tests so they work with it.

* Almost there... need to figure out this mock in IrcConnectionTest... it does not mock the IRC bot properly.

* Got the unit tests passing again.  This was done by having the mock IRC bot to take in multiple actions per listener, instead of just one.

Fixed an issue with the IrcMessageHandler, where it would forward messages that did not contain a channel.

* Added undefined check to nickservIdentify().

* Added comment to the 'status' function.

* Add Fedora CommOps, Diversity, Marketing as users (closes RITlug#75)

* Fix typo in hyperlink, missed from RITlug#79

* Gitignore change (RITlug#82)

* Allow new files in lib to be added via git.

At the moment, they were ignored since .gitignore was ignoring lib
because of the python virtual environment.

* Needed to put a slash in front...

* Wording.

* Just trying it out (RITlug#84)

* Check if we can actually reach Telegram on start (RITlug#83)

* Check if we can actually reach Telegram on start

* Fix tests

* Fix comment indentation

* No need for intermediate variable

* Telegram Refactor (RITlug#80)

* Added (untested) IrcHandlers.  These are so our IRC response logic is in separate classes, not in all one function.

The idea is maybe we can eventually make our IRC responses more advanced or configurable, and that is more easily doable through classes.

* Added Requires and and exports.

Added unit test for ErrorHandler.

* Added unit tests for the action handler.

* Added Kick and Join handler unit tests.

* Added unit tests for MessageHandler and PartHandler.

* Bind *all* the things (...thanks node...).

* Rename IrcHandlers so they have "Irc" in front of their names, so there is no mistake.

* Renamed classes so they have "IRC" in front so they are not confused with Telegram.

* Remove nodeunit... added it by accident.

* Added new lines at the end of the handler files.

* capital H... this is what I get for doing this on Windows...

* Added a helper function "StringExistsIgnoreCase".

This function is used to check for black-listed usernames, but can be used for other things as well.

* === instead of ==.

* Changed wording on joining a channel.

* ReportMessage -> RelayMessage

* Added (untested) IrcHandlers.  These are so our IRC response logic is in separate classes, not in all one function.

The idea is maybe we can eventually make our IRC responses more advanced or configurable, and that is more easily doable through classes.

* Added Requires and and exports.

Added unit test for ErrorHandler.

* Added unit tests for the action handler.

* Added Kick and Join handler unit tests.

* Added unit tests for MessageHandler and PartHandler.

* Bind *all* the things (...thanks node...).

* Rename IrcHandlers so they have "Irc" in front of their names, so there is no mistake.

* Renamed classes so they have "IRC" in front so they are not confused with Telegram.

* Remove nodeunit... added it by accident.

* Added new lines at the end of the handler files.

* capital H... this is what I get for doing this on Windows...

* Added a helper function "StringExistsIgnoreCase".

This function is used to check for black-listed usernames, but can be used for other things as well.

* === instead of ==.

* Changed wording on joining a channel.

* ReportMessage -> RelayMessage

* Integrated IrcNickServHandler into TeleIrc.js

Updated various unit tests so they work with it.

* Almost there... need to figure out this mock in IrcConnectionTest... it does not mock the IRC bot properly.

* Got the unit tests passing again.  This was done by having the mock IRC bot to take in multiple actions per listener, instead of just one.

Fixed an issue with the IrcMessageHandler, where it would forward messages that did not contain a channel.

* Added undefined check to nickservIdentify().

* Added comment to the 'status' function.

* Began to add Telegram classes.

* Added (completely untested) ErrorHandler, PhotoHandler, and StickerHandler for Telegram.

* Plugged in the TgEventListener and the handlers to TeleIrc.js.

Again, completely untested.

* Got unit tests passing again.

* Added TgDocumentHandler unit tests.

* Added TG Part/Join Handler unit tests.

* Added TG Message handler tests.

* new lines at end of files.

* Added unit tests for the sticker handler.

* Added photo handler unit tests.

* Got the Telegram refactor working when running via node.

#Success!

Now just to review and put in a pull.

* Put the chatId to be a string not an int.

* Rename CleanUpUserName -> ResolveUserName

* Never added TgImgurPhotoHandler.js

* Renamed "Report" functions to "Relay" Functions, per review.

* Use falseyness for the TG Handlers, per code review.

* Update yarn dependency tree

* Reorganize gitignore / add Dockerfile as ignored file

* Fix Fedora container, validate on Fedora 29 (closes RITlug#86)

This one wasn't too complicated, but took some playing around. What
changed here:

* Fix statements using old paths for files that no longer exist there
* Don't uninstall make, since it uninstalls nodejs
* yarn emits an error code, even if it actually was successful;
  therefore, run the next command regardless if it fails (this is why we
  can't have nice things :P)

* Set NTBA_FIX_319=1 in env.example (closes RITlug#88)

This resolves a deprecation warning given by node-telegram-bot-api about
the "automatic enabling of cancellation of promises". Given context from
the issue linked in the upstream project, setting this environment
variable will ensure backwards-compatibility with future releases. If we
need this feature, then we need to enable it when we need it.

Ref:

    yagop/node-telegram-bot-api#319 (comment)

* Fix CI tests: updated env.example path

* Use pipenv for docs development environment (RITlug#92)

Check it out:

  https://pipenv.readthedocs.io/

* Remove/update calls to retired method names (closes RITlug#87, closes RITlug#78) (RITlug#90)

* Remove redundant COPY statement from Fedora Dockerfile
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
2 participants
You can’t perform that action at this time.