Commit Graph

115 Commits

Author SHA1 Message Date
Clark Boylan b502ec35b0 Omnibus fixups for storyboard testing and CI
Linting fails due to two different hacking rules: H214 and H216. We fix
H214 by using assertNotIn and assertIn over assertFalse(foo in bar) and
assertTrue(foo in bar). We ignore H216 as it says don't use the mock
library but storyboard actually does use mock and updating to use
unittest.mock appears to be a fair bit of work.

In the sqlaclhemy models we move some classes around to address this
error:
  sqlalchemy.exc.InvalidRequestError: When initializing mapper mapped
  class Story->stories, expression 'TimeLineEvent' failed to locate a
  name ('TimeLineEvent'). If this is a class name, consider adding this
  relationship() to the <class 'storyboard.db.models.Story'> class after
  both dependent classes have been defined.

In the project loader we switch to using yaml.safe_load() to avoid the
missing Loader argument to yaml.load().

We pin jinja2 to < 3.0.0 as the old sphinx we've pinned to uses
contextfunction which appears to have been replaced in jinja2 3.0.0.
We should probably attempt to update the doc toolchain for storyboard
when we have time.

We pin MarkupSafe for similar reasons to the jinja2 pin. Version 2.1.0
of MarkupSafe removed the soft_unicode name which is used by sphinx.

Finally we run the python 3.6 and 3.7 jobs on ubuntu-bionic.

Change-Id: Ifcb6660ce2c89c21ba867aa88d942461bcff125d
2022-04-18 16:00:35 -07:00
Adam Coldrick 647bb9c660 Drop Python 2.7 support
Python 2.7 is deprecated now, and some dependencies have dropped their
support for it. We should also just drop support for it rather than
pinning the dependency versions.

This commit also switches to a generic Python 3 tox environment,
adds additional test jobs for more Python 3 versions, and cleans up
some Python 2 compatibility cruft.

Change-Id: I3e7cc1713dec1bada4a85f75362c4fa4f89ceae6
2020-03-28 14:25:33 +00:00
Jeremy Stanley e386f32566 Add a dedicated "lpimport" tox testenv
To simplify the launchpadlib dependency installation for the
storyboard-migrate utility, use a separate tox testenv specifically
for this purpose and put that as its only additional runtime
requirement. Name the testenv "lpimport" with the expectation that
in time we may also rename the storyboard-migrate utility similarly
(so as to disambiguate it from the Alembic migrations we rely on
for database schema upgrades).

Change-Id: I8bd36bf69c235c8957ae4a161fd22cbe80028cf4
2019-12-17 08:36:50 -05:00
Jeremy Stanley 3e4e956ff8 Regular expression support for CORS and OAuth ACLs
Make it possible for allowed_origins and valid_oauth_clients to
include regular expressions, for cases where part or all of the
domain/URL cannot be predicted or easily enumerated.

Change-Id: I9cfc729547560438e0fa1e47cc90cd5579168c73
2019-10-25 22:22:51 +00:00
Kendall Nelson 62309ed2e8 Link development.rst to contributing.rst
A bit of a reorg combined with adding mention of the install guide
to the contributing doc.

Change-Id: I63678e0b3e2f60831ef28a8695a5c6cebcb087e2
2019-07-01 15:57:50 -07:00
Kendall Nelson 68272b85d4 Add StoryBoard Story Tags to Docs
After spending the PTG and subsequent meetings triaging
the entire backlog of active StoryBoard stories, we have
settled on a list of tags that we will use moving forward
to help sort and organize work.

Change-Id: I5eccbbaeb025ac0604774a1270663edf113c9be3
2019-06-28 10:42:32 -07:00
Adam Spiers 24f0187925 Clarify the rationale for StoryBoard's unique design
Explain a bit more about the nature of our open community, and make
connections between this and StoryBoard's unique feature set.

Move the REST API section to the bottom, since this is the least
user-facing aspect and more of an implementation detail.

Also tweak the wording from the style in the original blog post, to
reflect that this is now documentation of a project which is no longer
brand new.

Change-Id: I0a9cac50f3d6d5db13b3d820f0212632cc048454
2019-05-17 13:21:17 +01:00
Szymon Datko a25b54ad7e Fix missing tox env in dev install doc
Within the documentation about how to setup own development
instance, there is a missing tox environment name in sections
that describe how to launch worker for notifications.
This change introduces the missing parts of tox commands.

Change-Id: If32707bd2f93310723fbcdb045e2781edd65fb78
2019-05-02 23:34:43 +02:00
Zuul 6aba5d7f5c Merge "Make the first user a superuser" 2019-05-02 17:15:41 +00:00
Zuul fcb04495a0 Merge "Rewrite/clarify non-docker dev env instructions" 2019-04-11 13:03:42 +00:00
Zuul df93aa975e Merge "Add docker-compose based dev setup instructions" 2019-04-11 12:40:57 +00:00
Riju19 a2a3df3d19 Search bars handle queries as if they have a * at the end
Change-Id: Iac8a6a46e7898edd523e3f7c026cbdd134bbff21
Task: 2260
Signed-off-by: Riju19 <19.riju@gmail.com>
2019-04-01 22:04:38 +05:30
Adam Coldrick f4d10fd42f Rewrite/clarify non-docker dev env instructions
This updates the manual development installation instructions to be
more similar to the docker instructions in wording, and also
clarifies some previously-unmentioned pain points.

The RabbitMQ setup instructions are also moved into the manual setup
section, since the docker instructions already cover it for that
use-case.

Change-Id: I16ae43bed70d03bfce2fbe07dea9e58ff073d42f
2019-03-25 13:26:54 +00:00
Adam Coldrick 56b0233ffe Add docker-compose based dev setup instructions
This adds a docker-compose.yml file which runs the various services
required for a working development instance of StoryBoard (and also
Swift, which technically isn't needed yet). It also provides a config
file which is pre-configured to work out of the box with the services
in the docker-compose.yml file.

It also updates the development installation instructions to recommend
using docker-compose to run the services, rather than installing them
on a machine and configuring everything manually.

Change-Id: I405e2e46f6ab7d8ef2c1ddd43b3e2e8cb8e3a808
2019-03-25 13:06:06 +00:00
Zuul 2e47430d54 Merge "Update docs on how to run the tests locally" 2019-03-04 21:41:53 +00:00
Zuul 3fdda73b39 Merge "Add documentation for private stories" 2019-03-04 18:41:19 +00:00
Kendall Nelson 55dfa602c6 Add documentation for private stories
Include basic information about how to create a story that has security
concerns.

Change-Id: I379a076f66f9794dac2add98f44c5347f55de9fd
2019-03-02 01:25:49 +00:00
Clark Boylan 528469101e Update docs on how to run the tests locally
This adds more up to date documentation on how to run the tests locally.
It recommends the sqlite target for unittests as they are faster but
includes directions for setting up mysql and postgresql for  running the
test suite against production like backends.

Change-Id: I56f6d6b586ec5274943fbef35f635b03bf22c4bd
2019-02-28 16:59:14 -08:00
Zuul b476b0ed8f Merge "Update development installation documentation" 2019-02-27 16:04:26 +00:00
Ivoline Ngong 14e3d53e5a Fixed hyperlinks to worklist and boards documents
Change-Id: Id8fb95b780a05212b39226da866b67d2e7adc723
2019-02-15 19:09:45 +03:00
Adam Coldrick 8cb8e142f4 Update development installation documentation
There are some inaccuracies and unnecessary instructions in the
development installation docs page. This commit clarifies and
updates them where possible to make them less likely to lead to
immediate problems.

Change-Id: I8ae9bfe4709aebf24eb86d4bcb36d66445b60ffb
2019-01-26 12:25:28 +00:00
Adam Coldrick 3e935668d9 Make the first user a superuser
This commit fixes a longstanding bug whereby someone setting up
a development instance of StoryBoard would need to modify their
user in the relevant table manually, or add their openid to a
YAML file and run an extra step, in order to actually do anything
useful.

Now, the first user to log in to a StoryBoard instance is made into
a superuser if no other users exist already for whatever reason.

Change-Id: I43b2644b2232c6e342e4d03c8ba16b4fc9e74ddc
2019-01-26 12:19:30 +00:00
Zuul 410cd42e2b Merge "Add to & Reorganize StoryBoard GUI Docs" 2018-08-01 20:00:58 +00:00
François Magimel 379b606dcc Replace broken links and http links in the doc
Some typos were fixed too.

Change-Id: I05f621c2daa1142006ab8e04164c75a031edea4f
2018-06-30 00:04:59 +02:00
Kendall Nelson 234ac1b68b Add to & Reorganize StoryBoard GUI Docs
This patch does a little reorganization of the gui docs.
It adds a section solely focused on the creation and
functions of boards. It also adds a section on best
practices as we get a lot of questions about how things
should be done.

Change-Id: Id208d2edb754030a75ba2c1884fd8ef0b620a6af
2018-06-25 14:38:30 -07:00
Zuul ae1d2e1e6d Merge "Document some usage instructions for a freshly deployed dev instance" 2018-06-08 22:50:03 +00:00
Zuul c001d30625 Merge "Reorganize Docs" 2018-04-30 23:21:35 +00:00
Kendall Nelson 7bba5bb092 Reorganize Docs
There were two disjointed user guides which are unified in this
patch. In the future, they will live in the webclient repo instead
of here, but for the time being we need a more unified front for our
users.

Change-Id: Icb5b9a46b8e45518392de617ba9eee3fb9bf04fd
2018-04-10 20:21:35 -07:00
Jeremy Stanley 2c64cee9f3 Use charset=utf8mb4 in pymysql DBURIs
To make full use of the new 4-byte character set in columns for
MySQL, connections to the database need to also specify
charset=utf8mb4. The easiest way to do that is by tacking it on as a
variable in the DBURI string. Do this both in the test migration
script and in the documented sample and test configs.

Change-Id: Icf5f74543f6d062cafe2166d384f37f46394e964
2018-03-28 21:25:11 +00:00
Adam Coldrick b5b151522c Document some usage instructions for a freshly deployed dev instance
Change-Id: I3b12c574274daefb8386bb81b3b7aeeea7be8bd7
2018-03-28 18:44:57 +00:00
Luigi Toscano c67d349dc9 Migration script: optional parameters to filter by tags
The new two command line parameters filter the bugs:
- by selecting only the bug which contains at least one tag from the set;
- by excluding the bugs which contains at least one tag from the set.
The two options are mutually exclusive.

Story: 2000876
Task: 6684

Change-Id: I8e2043b4832efda4fac44e65dd56d37e1af393e3
2018-03-12 22:10:32 +01:00
Zuul 7ec57d21f5 Merge "Create a StoryBoard gui manual" 2018-02-22 07:32:08 +00:00
Kendall Nelson 923495c192 Update Development & Migration Docs
With the newer versions of tox the syntax has
changed for how to run storyboard-db-manage,
storyboard-api, etc. This patch makes the necessary
updates to reflect those changes so that the commands
work.

Change-Id: I0e52a2816ae7a4f6406cf0aa71cbf988e24ba66f
2018-02-12 19:42:06 +00:00
Zuul 90fde5756b Merge "set up tests to run with sqlite" 2018-02-11 15:36:45 +00:00
Zuul 494f6ab19c Merge "Remove vagrant setup" 2018-02-07 22:12:20 +00:00
Doug Hellmann 2fe2f57b6b set up tests to run with sqlite
For most of the tests for storyboard sqlite is around 10 times faster
than MySQL (more for non-SSD systems). An sqlite database does not
support some operations, like modifying constraints or dropping
columns, so we cannot avoid testing with MySQL. We can however use
sqlite for local development to reduce the pain involved with running
tests as part of the development process.

This patch adds a tox environment for running the tests against
sqlite3. The new tox environment is intended to be used by developers
as well as the new check and gate job defined in .zuul.yaml.

The new job ensures that changes to alembic migration scripts continue
to work with sqlite.

This patch also modifies the existing alter scripts to skip steps not
supported under sqlite. Those steps aren't strictly needed, and they
are still tested when the CI system runs the tests with MySQL.

Change-Id: Icb979cb03e10c56519a90ea3976a4da2d9bddb05
Signed-off-by: Doug Hellmann <doug@doughellmann.com>
2018-02-05 17:48:53 -05:00
Anita Kuno e609ecba2e Create a StoryBoard gui manual
Currently there is no documenation to guide users in how to use
StoryBoard's gui. This patch creates this documentation.

Also it uppercases the B in StoryBoard in two places in the index page.

Change-Id: I068f1fae3dffbf82018e3201a8dbefc9f1866440
Story: 2000627
Task: 3068
2018-01-30 19:48:03 +00:00
Doug Hellmann 833fdea9e5 suppress warnings from wsmeext.sphinxext
When the wsmeext.sphinxext extension is initialized during the
documentation build it registers some autodoc classes that use the
same objtype as built-in types. This causes the associated directives
to be overridden, which emits a warning. That warning prevents us from
turning on warning-is-error in the build. Since there is nothing we
can do about it, we want to ignore it.

Change-Id: Ie74174176d6140467c60ea864dc2df4dc2287604
Signed-off-by: Doug Hellmann <doug@doughellmann.com>
2018-01-22 14:38:03 -05:00
Doug Hellmann 5624266bf5 escape an example URL as literal text to avoid build warning
Change-Id: I1c156dfc6c221b59b9d9364a94654926642b28a8
Signed-off-by: Doug Hellmann <doug@doughellmann.com>
2018-01-22 14:38:03 -05:00
Doug Hellmann 4f26837b8e fix literal block markup for blocks within bullet lists
Change-Id: I65fb3b69dd71bd5904ae99db6ae4761f3ffa2b90
Signed-off-by: Doug Hellmann <doug@doughellmann.com>
2018-01-22 14:38:03 -05:00
Doug Hellmann 4734e6caa4 fix syntax for toctree
Fix the syntax for one toctree element and make the indentation for
all of them consistent.

Change-Id: I11abeda4a7568c741fc1303e00b008eca419ad4b
Signed-off-by: Doug Hellmann <doug@doughellmann.com>
2018-01-22 14:38:03 -05:00
Doug Hellmann 60609eaea7 fix document cross-link syntax
Let sphinx determine the link and insert the title of the page to
avoid a warning about a duplicate "read more here" link.

Change-Id: Id32ccf0f5a36739b0cbbc287e9bba3962aff4019
Signed-off-by: Doug Hellmann <doug@doughellmann.com>
2018-01-22 14:38:03 -05:00
Doug Hellmann 1d68addb05 separate worklist instructions from theory
Move the information about using worklists from the more general
theory info about storyboard.

Change-Id: Iaefc0cb0115c5855ee756a764c21214ab23675ca
Signed-off-by: Doug Hellmann <doug@doughellmann.com>
2018-01-22 14:38:03 -05:00
Doug Hellmann 56cdab1282 import blog post "Things that StoryBoard does differently"
Import the raw text and images from
https://storyboard-blog.io/things-that-storyboard-does-differently.html

Change-Id: I61943293f5cbb88cd8ad4cc3b378edf40f6f63a4
Signed-off-by: Doug Hellmann <doug@doughellmann.com>
2018-01-22 14:38:03 -05:00
Zuul 82b65ab421 Merge "Add documentation on manually upgrading a StoryBoard instance" 2018-01-19 04:02:32 +00:00
Doug Hellmann 520a3fd173 fix rst heading styles
Make the heading styles consistent and use different styles for the
page title and in-page headings so they are all displayed in the HTML
output.

Change-Id: I6685eea7c4840e60aa92316d7c42cb9c29932c2f
Signed-off-by: Doug Hellmann <doug@doughellmann.com>
2018-01-17 12:03:48 -05:00
Doug Hellmann 2a176d1d0c fix rst formatting
Fix some indentation and other markup issues in the RST for the
documentation.

Change-Id: I921445f7120335510ee7b203a2210737012bcdf2
Signed-off-by: Doug Hellmann <doug@doughellmann.com>
2018-01-12 16:38:41 -05:00
Doug Hellmann 708d09be77 update documentation build for new PTI
Move documentation dependencies to doc/requirements.txt

Change tox.ini to run sphinx-build directly, like the zuul job does.

Switch from oslosphinx to openstackdocstheme.

Change-Id: I079ff78edacaba673461824af770344cb3a896f2
Signed-off-by: Doug Hellmann <doug@doughellmann.com>
2018-01-12 16:24:59 -05:00
Zuul 72a62c7f0a Merge "Remove Update tox Step" 2018-01-10 20:30:20 +00:00
Zara 178549792c Remove vagrant setup
This commit removes the instructions and tooling
to set up a StoryBoard VM via vagrant.
It is unmaintained, and has been for about 2.5 years.
We believe it is both unused and unlikely to work,
so we should avoid indicating that we advise using it.

Change-Id: I9d6853f0b0ea822d5cac0b13b8f1aa0b0e55d0ac
2018-01-10 00:30:08 +00:00