Skip to content

Commit 62f6539

Browse files
authored
File update (dropbox#229)
* First pass with new files * Make language specific updates * Add logo to readme
1 parent da092ea commit 62f6539

11 files changed

+224
-103
lines changed

.github/ISSUE_TEMPLATE/bug_report.md

+31
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,31 @@
1+
---
2+
name: "\U0001F41B Bug report"
3+
about: Create a report to help us improve the SDK
4+
title: ''
5+
labels: bug
6+
assignees: ''
7+
8+
---
9+
10+
**Describe the bug**
11+
A clear and concise description of the bug.
12+
13+
**To Reproduce**
14+
The steps to reproduce the behavior
15+
16+
**Expected Behavior**
17+
A clear description of what you expected to happen.
18+
19+
**Actual Behavior**
20+
A clear description of what actually happened
21+
22+
**Screenshots**
23+
If applicable, add screenshots to help explain your problem.
24+
25+
**Versions**
26+
* What version of the SDK are you using?
27+
* What version of the language are you using?
28+
* What platform are you using? (if applicable)
29+
30+
**Additional context**
31+
Add any other context about the problem here.

.github/ISSUE_TEMPLATE/config.yml

+1
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
blank_issues_enabled: false
+20
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,20 @@
1+
---
2+
name: "\U0001F680 Feature Request"
3+
about: Suggest an idea for this SDK
4+
title: ''
5+
labels: enhancement
6+
assignees: ''
7+
8+
---
9+
10+
**Why is this feature valuable to you? Does it solve a problem you're having?**
11+
A clear and concise description of why this feature is valuable. Ex. I'm always frustrated when [...]
12+
13+
**Describe the solution you'd like**
14+
A clear and concise description of what you want to happen.
15+
16+
**Describe alternatives you've considered**
17+
A clear and concise description of any alternative solutions or features you've considered. (if applicable)
18+
19+
**Additional context**
20+
Add any other context or screenshots about the feature request here.
+25
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,25 @@
1+
---
2+
name: "\U0001F4AC Questions / Help"
3+
about: Get help with issues you are experiencing
4+
title: ''
5+
labels: help-wanted, question
6+
assignees: ''
7+
8+
---
9+
10+
**Before you start**
11+
Have you checked StackOverflow, previous issues, and Dropbox Developer Forums for help?
12+
13+
**What is your question?**
14+
A clear and concise description the question.
15+
16+
**Screenshots**
17+
If applicable, add screenshots to help explain your question.
18+
19+
**Versions**
20+
* What version of the SDK are you using?
21+
* What version of the language are you using?
22+
* What platform are you using? (if applicable)
23+
24+
**Additional context**
25+
Add any other context about the question here.

.github/dependabot.yml

+16
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,16 @@
1+
# To get started with Dependabot version updates, you'll need to specify which
2+
# package ecosystems to update and where the package manifests are located.
3+
# Please see the documentation for all configuration options:
4+
# https://help.github.com/github/administering-a-repository/configuration-options-for-dependency-updates
5+
6+
version: 2
7+
updates:
8+
- package-ecosystem: "pip" # See documentation for possible values
9+
directory: "/" # Location of package manifests
10+
schedule:
11+
interval: "daily"
12+
13+
- package-ecosystem: "github-actions"
14+
directory: "/"
15+
schedule:
16+
interval: "daily"

.github/pull_request_template.md

+18
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,18 @@
1+
<!--
2+
Thank you for your pull request. Please provide a description below.
3+
-->
4+
5+
## **Checklist**
6+
<!-- For completed items, change [ ] to [x]. -->
7+
8+
**General Contributing**
9+
- [ ] Have you read the Code of Conduct and signed the [CLA](https://opensource.dropbox.com/cla/)?
10+
11+
**Is This a Code Change?**
12+
- [ ] Non-code related change (markdown/git settings etc)
13+
- [ ] SDK Code Change
14+
- [ ] Example/Test Code Change
15+
16+
**Validation**
17+
- [ ] Does `tox` pass?
18+
- [ ] Do the tests pass?

CODE_OF_CONDUCT.md

+5
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
# Dropbox Code Of Conduct
2+
3+
*Dropbox believes that an inclusive development environment fosters greater technical achievement. To encourage a diverse group of contributors we've adopted this code of conduct.*
4+
5+
Please read the Official Dropbox [Code of Conduct](https://opensource.dropbox.com/coc/) before contributing.

CONTRIBUTING.md

+67
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,67 @@
1+
# Contributing to the Dropbox SDK for Python
2+
We value and rely on the feedback from our community. This comes in the form of bug reports, feature requests, and general guidance. We welcome your issues and pull requests and try our hardest to be timely in both response and resolution. Please read through this document before submitting issues or pull requests to ensure we have the necessary information to help you resolve your issue.
3+
4+
## Filing Bug Reports
5+
You can file a bug report on the [GitHub Issues][issues] page.
6+
7+
1. Search through existing issues to ensure that your issue has not been reported. If it is a common issue, there is likely already an issue.
8+
9+
2. Please ensure you are using the latest version of the SDK. While this may be a valid issue, we only will fix bugs affecting the latest version and your bug may have been fixed in a newer version.
10+
11+
3. Provide as much information as you can regarding the language version, SDK version, and any other relevant information about your environment so we can help resolve the issue as quickly as possible.
12+
13+
## Submitting Pull Requests
14+
15+
We are more than happy to recieve pull requests helping us improve the state of our SDK. You can open a new pull request on the [GitHub Pull Requests][pr] page.
16+
17+
1. Please ensure that you have read the [License][license], [Code of Conduct][coc] and have signed the [Contributing License Agreement (CLA)][cla].
18+
19+
2. Please add tests confirming the new functionality works. Pull requests will not be merged without passing continuous integration tests unless the pull requests aims to fix existing issues with these tests.
20+
21+
## Updating Generated Code
22+
23+
Generated code can be updated by running the following code:
24+
25+
```
26+
$ pip install -r requirements.txt
27+
$ git submodule init
28+
$ git submodule update --remote --recursive
29+
$ python generate_base_client.py
30+
```
31+
32+
Note: Stone updates must be made by updating `requirements.txt` as it is no longer a submodule.
33+
34+
## Testing the Code
35+
36+
We use the [`tox`](https://tox.readthedocs.org/) package to run tests. To install and run the unit tests, you can use:
37+
38+
```
39+
$ pip install tox
40+
$ tox
41+
```
42+
43+
Or if you would like to specify a specific target to run you can run this:
44+
45+
```
46+
$ tox -e {TARGET}
47+
```
48+
49+
If you want to run the integration tests, you can use the following:
50+
51+
```
52+
$ export DROPBOX_REFRESH_TOKEN={fill in refresh token}
53+
$ export DROPBOX_APP_KEY={fill in app key}
54+
$ export DROPBOX_APP_SECRET={fill in app secret}
55+
$ export DROPBOX_TEAM_TOKEN={fill in team token}
56+
$ export DROPBOX_TOKEN={fill in access token}
57+
$ tox -e test_integration
58+
```
59+
Note: If you do not have all of these tokens available, we run integration tests as a part of pull request validation and you are able to rely on those if you are unable to obtain yourself.
60+
61+
We do recommend developing in a virtual environment in order to ensure you have a clean testing environment.
62+
63+
[issues]: https://github.com/dropbox/dropbox-sdk-python/issues
64+
[pr]: https://github.com/dropbox/dropbox-sdk-python/pulls
65+
[coc]: https://github.com/dropbox/dropbox-sdk-python/blob/master/CODE_OF_CONDUCT.md
66+
[license]: https://github.com/dropbox/dropbox-sdk-python/blob/master/LICENSE
67+
[cla]: https://opensource.dropbox.com/cla/

CONTRIBUTING.rst

-57
This file was deleted.

LICENSE

+2-2
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
Copyright (c) 2015-2017 Dropbox Inc., http://www.dropbox.com/
1+
Copyright (c) 2020 Dropbox Inc., http://www.dropbox.com/
22

33
Permission is hereby granted, free of charge, to any person obtaining
44
a copy of this software and associated documentation files (the
@@ -17,4 +17,4 @@ Copyright (c) 2015-2017 Dropbox Inc., http://www.dropbox.com/
1717
NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
1818
LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
1919
OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
20-
WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
20+
WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.

README.rst

+39-44
Original file line numberDiff line numberDiff line change
@@ -1,39 +1,23 @@
1-
Dropbox Python SDK
2-
==================
3-
4-
.. image:: https://travis-ci.org/dropbox/dropbox-sdk-python.svg?branch=master
5-
:target: https://travis-ci.org/dropbox/dropbox-sdk-python
6-
7-
.. image:: https://readthedocs.org/projects/dropbox-sdk-python/badge/?version=stable
8-
:target: https://dropbox-sdk-python.readthedocs.org/en/stable/
9-
:alt: [Latest Release Documentation]
10-
11-
.. image:: https://img.shields.io/pypi/v/dropbox.svg
12-
:target: https://pypi.python.org/pypi/dropbox
13-
:alt: [Latest Release Version]
14-
15-
.. image:: https://img.shields.io/pypi/l/dropbox.svg
16-
:target: http://opensource.org/licenses/MIT
17-
:alt: [Latest Release License]
1+
.. image:: https://cfl.dropboxstatic.com/static/images/sdk/python_banner.png
2+
:target: https://github.com/dropbox/dropbox-sdk-python
183

194
.. image:: https://img.shields.io/pypi/pyversions/dropbox.svg
205
:target: https://pypi.python.org/pypi/dropbox
21-
:alt: [Latest Release Supported Python Versions]
226

23-
.. image:: https://img.shields.io/pypi/implementation/dropbox.svg
7+
.. image:: https://img.shields.io/pypi/v/dropbox.svg
248
:target: https://pypi.python.org/pypi/dropbox
25-
:alt: [Latest Release Supported Python Implementations]
269

27-
.. image:: https://img.shields.io/pypi/status/dropbox.svg
28-
:target: https://pypi.python.org/pypi/dropbox
29-
:alt: [Latest Release Development Stage]
10+
.. image:: https://codecov.io/gh/dropbox/dropbox-sdk-python/branch/master/graph/badge.svg
11+
:target: https://codecov.io/gh/dropbox/dropbox-sdk-python
12+
13+
The offical Dropbox SDK for Python.
3014

31-
A Python SDK for integrating with the Dropbox API v2. Compatible with Python 2.7 and 3.4+. Documentation is available on `Read the Docs <http://dropbox-sdk-python.readthedocs.org/>`_.
15+
Documentation can be found on `Read The Docs`_.
3216

3317
Installation
34-
------------
18+
============
3519

36-
Create an app at https://dropbox.com/developers/apps
20+
Create an app via the `Developer Console`_.
3721

3822
Install via `pip <https://pip.pypa.io/>`_:
3923

@@ -49,30 +33,41 @@ Install from source:
4933
$ cd dropbox-sdk-python
5034
$ python setup.py install
5135
52-
After installation, to get started, follow one of our examples or read the documentation on `Read the Docs <http://dropbox-sdk-python.readthedocs.org/>`_.
53-
54-
Authentication
55-
--------------
56-
57-
All requests need to be made with an OAuth 2 access token. To get started, once you've created an app, you can go to the app's console and generate an access
58-
token for your own Dropbox account for development. You can also find a variety of examples outlining different authorization flows under:
36+
After installation, follow one of our `Examples`_ or read the documentation on `Read The Docs`_.
5937

60-
`example/oauth <http://github.com/dropbox/dropbox-sdk-python/tree/master/example/oauth/>`_
38+
You can also view our `OAuth Guide`_.
6139

62-
You can also view our OAuth `guide <https://www.dropbox.com/lp/developers/reference/oauth-guide>`_
40+
Examples
41+
========
6342

64-
Example Applications
65-
--------------------
43+
We provide `Examples`_ to help get you started with a lot of the basic functionality in the SDK.
6644

67-
- `updown <http://github.com/dropbox/dropbox-sdk-python/tree/master/example/updown.py>`_ - A sample application that demonstrates simple file upload and download
45+
- **OAuth**
46+
- `Commandline OAuth Basic <https://github.com/dropbox/dropbox-sdk-python/blob/master/example/oauth/commandline-oauth.py>`_ - Shows a simple example of commandline oauth (no redirect).
47+
- `Commandline OAuth Scopes <https://github.com/dropbox/dropbox-sdk-python/blob/master/example/oauth/commandline-oauth-scopes.py>`_ - Shows a simple example of commandline oauth using scopes.
48+
- `Commandline OAuth PKCE <https://github.com/dropbox/dropbox-sdk-python/blob/master/example/oauth/commandline-oauth-pkce.py>`_ - Shows a simple example of commandline oauth using PKCE.
49+
- **Other Examples**
50+
- `Updown <https://github.com/dropbox/dropbox-sdk-python/blob/master/example/updown.py>`_ - Sample application that uploads the contents of your ``Downloads`` folder to Dropbox.
51+
- `Backup and Restore <https://github.com/dropbox/dropbox-sdk-python/tree/master/example/back-up-and-restore>`_ - Sample application that shows how you can backup a file and restore previous versions if the file was modified/corrupted in any way.
6852

69-
Contributing
70-
------------
53+
Getting Help
54+
============
7155

72-
Contributions to this SDK are always welcome and encouraged!
56+
If you find a bug, please see `CONTRIBUTING.md`_ for information on how to report it.
7357

74-
See the `CONTRIBUTING <http://github.com/dropbox/dropbox-sdk-python/blob/master/CONTRIBUTING.rst>`_ doc for more information
58+
If you need help that is not specific to this SDK, please reach out to `Dropbox Support`_.
7559

7660
License
77-
-------
78-
MIT - See the `LICENSE <http://github.com/dropbox/dropbox-sdk-python/blob/master/LICENSE>`_ for more information
61+
=======
62+
63+
This SDK is distributed under the MIT license, please see `LICENSE`_ for more information.
64+
65+
.. _logo: {logo_link}
66+
.. _repo: https://github.com/dropbox/dropbox-sdk-python
67+
.. _`Read The Docs`: http://dropbox-sdk-python.readthedocs.org
68+
.. _`Examples`: https://github.com/dropbox/dropbox-sdk-python/tree/master/example
69+
.. _LICENSE: https://github.com/dropbox/dropbox-sdk-python/blob/master/LICENSE
70+
.. _CONTRIBUTING.md: https://github.com/dropbox/dropbox-sdk-python/blob/master/CONTRIBUTING.md
71+
.. _Developer Console: https://dropbox.com/developers/apps
72+
.. _OAuth Guide: https://www.dropbox.com/lp/developers/reference/oauth-guide
73+
.. _`Dropbox Support`: https://www.dropbox.com/developers/contact

0 commit comments

Comments
 (0)