Skip to content

Commit f36c87e

Browse files
committed
tweaks, release 0.0.1
1 parent 1844756 commit f36c87e

File tree

5 files changed

+8
-5
lines changed

5 files changed

+8
-5
lines changed

README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@ from framelib import render_frame
2323

2424
app = Flask(__name__)
2525

26-
@app.route('/', methods=['GET', 'POST'])
26+
@app.route('/')
2727
def home():
2828
return render_frame(
2929
image='https://opengraph.githubassets.com/0x/devinaconley/python-frames',

examples/simple/api/index.py

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,7 @@
22
main entry point for example framelib flask app
33
"""
44
import os
5+
import time
56
from flask import Flask, url_for, jsonify
67
from framelib import render_frame, message, validate_message_or_mock_vercel
78

@@ -19,7 +20,7 @@ def handle_invalid_usage(e):
1920
def home():
2021
# initial frame
2122
return render_frame(
22-
image='https://opengraph.githubassets.com/0x/devinaconley/python-frames',
23+
image=f'https://opengraph.githubassets.com/{int(time.time())}/devinaconley/python-frames',
2324
button1='hello \U0001F44B',
2425
post_url=url_for('second_page', _external=True),
2526
button2='github',
@@ -40,7 +41,7 @@ def second_page():
4041
print(f'validated frame message, fid: {msg_val.interactor.fid}, button: {msg_val.tapped_button}')
4142

4243
return render_frame(
43-
image='https://opengraph.githubassets.com/0x/devinaconley/python-frames',
44+
image=f'https://opengraph.githubassets.com/{int(time.time())}/devinaconley/python-frames',
4445
button1='back \U0001F519',
4546
post_url=url_for('home', _external=True),
4647
input_text=f'hello {msg_val.interactor.username}!',

examples/simple/requirements.txt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
11
# requirements.txt
2-
framelib~=0.0.0b5
2+
framelib~=0.0.1
33
Flask~=3.0.1
44
pydantic

framelib/neynar.py

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,8 @@
99

1010

1111
def get_frame_action(msg: str, api_key: str) -> ValidatedMessage:
12+
if not api_key:
13+
raise ValueError('neynar api key not set')
1214
url = 'https://api.neynar.com/v2/farcaster/frame/validate'
1315
body = {
1416
'cast_reaction_context': False, # TODO

setup.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@
55

66
setuptools.setup(
77
name='framelib',
8-
version='0.0.0.b5',
8+
version='0.0.1',
99
author='Devin A. Conley',
1010
author_email='devinaconley@gmail.com',
1111
description='lightweight library for building farcaster frames using python and flask',

0 commit comments

Comments
 (0)